More adjustments to gold shell drop chance.

This commit is contained in:
Mari the Deer 2020-11-16 14:31:06 +01:00
commit fbb0e02eb0
2 changed files with 3 additions and 2 deletions

View file

@ -1,2 +1,2 @@
[default]
SWWM_MODVER="\chSWWM \czGZ\c- \cw0.9.11b-pre r620 \cu(Mon 16 Nov 13:53:21 CET 2020)";
SWWM_MODVER="\chSWWM \czGZ\c- \cw0.9.11b-pre r621 \cu(Mon 16 Nov 14:31:06 CET 2020)";

View file

@ -1138,7 +1138,8 @@ Class SWWMHandler : EventHandler
int dropweight = 0;
let ti = ThinkerIterator.Create(e.Thing.GetClass());
while ( ti.Next() ) dropweight++;
dropweight = max(2,dropweight/4);
int minchance = max(1,6-(e.Thing.GetSpawnHealth()/1000));
dropweight = max(minchance,dropweight/4);
if ( !Random[GoldDrop](0,dropweight) )
{
let g = Actor.Spawn("GoldShell",e.Thing.Vec3Offset(0,0,e.Thing.Height/2));