# HG changeset patch # User sheepluva # Date 1439072735 -7200 # Node ID 3ab93d702fb1bb04e8f0018b2260fc8bb0466bfe # Parent cd4b0851b060d6b3b8f14a02129167cb12f2bd37 tweak prev commit diff -r cd4b0851b060 -r 3ab93d702fb1 hedgewars/uGearsHandlersMess.pas --- a/hedgewars/uGearsHandlersMess.pas Sun Aug 09 00:19:33 2015 +0200 +++ b/hedgewars/uGearsHandlersMess.pas Sun Aug 09 00:25:35 2015 +0200 @@ -5228,15 +5228,15 @@ //tmp^.State:= tmp^.State or gstFlatened; if (tmp^.Kind <> gtHedgehog) or (tmp^.Hedgehog^.Effects[heInvulnerable] = 0) then begin - // do 1/2 current hp worth of damage if extra damage is enabled (1/3 damage if not) - if cDamageModifier > _1 then - d:= 2 - else - d:= 3; // base damage on remaining health dmg:= (tmp^.Health - tmp^.Damage); if dmg > 0 then begin + // do 1/2 current hp worth of damage if extra damage is enabled (1/3 damage if not) + if cDamageModifier > _1 then + d:= 2 + else + d:= 3; // always round up if dmg mod d > 0 then dmg:= dmg div d + 1