--- a/ChangeLog.txt Tue Nov 03 21:43:56 2015 +0300
+++ b/ChangeLog.txt Tue Nov 03 21:18:25 2015 +0100
@@ -1,6 +1,9 @@
+ features
* bugfixes
+0.9.22 -> 0.9.23
+ * Hammer damage is now rounded down. This means it will cause NO DAMAGE to a hedgehog with less than 3 hp.
+
0.9.21 -> 0.9.22
+ New Weapon / Map object: AirMine (floating mine that will follow nearby hedgehogs)
+ Extensive changes to TechRacer: Variable terrain types, enhanced parameters, hwmap interpreter, fuel limiter, etc.
--- a/hedgewars/uGearsHandlersMess.pas Tue Nov 03 21:43:56 2015 +0300
+++ b/hedgewars/uGearsHandlersMess.pas Tue Nov 03 21:18:25 2015 +0100
@@ -5255,13 +5255,12 @@
d:= 2
else
d:= 3;
- // always round up
- if dmg mod d > 0 then
- dmg:= dmg div d + 1
- else
- dmg:= dmg div d;
-
- ApplyDamage(tmp, CurrentHedgehog, dmg, dsUnknown);
+
+ // always rounding down
+ dmg:= dmg div d;
+
+ if dmg > 0 then
+ ApplyDamage(tmp, CurrentHedgehog, dmg, dsUnknown);
end;
end;