Duplicate Parachute more closely :D
authornemo
Sun, 21 Jun 2009 15:36:50 +0000
changeset 2179 839472821b4d
parent 2178 d8b3417b2704
child 2180 6c5a339f8e28
Duplicate Parachute more closely :D
hedgewars/GSHandlers.inc
hedgewars/uConsts.pas
--- a/hedgewars/GSHandlers.inc	Sun Jun 21 15:36:13 2009 +0000
+++ b/hedgewars/GSHandlers.inc	Sun Jun 21 15:36:50 2009 +0000
@@ -2223,15 +2223,18 @@
 Gear^.Y:= HHGear^.Y;
 doStepHedgehogMoving(HHGear);
 
-if //(Gear^.Timer = 0) or
-   (Gear^.Health = 0) or 
-   ((HHGear^.Message and gm_Attack) <> 0) or
-   (HHGear^.Damage <> 0) then
+if  (Gear^.Health = 0)
+	or CheckGearDrowning(HHGear)
+	or ((Gear^.Message and gm_Attack) <> 0) then
 	begin
-	HHGear^.Message:= 0;
+	with HHGear^ do
+		begin
+		Message:= 0;
+        Active:= true;
+		State:= State or gstMoving
+		end;
 	DeleteGear(Gear);
-	AfterAttack;
-    HHGear^.Active:= true;
+	isCursorVisible:= false;
 	end
 end;
 
@@ -2242,6 +2245,8 @@
 
 HHGear:= PHedgehog(Gear^.Hedgehog)^.Gear;
 FollowGear:= HHGear;
+OnUsedAmmo(PHedgehog(HHGear^.Hedgehog)^);
+ApplyAmmoChanges(PHedgehog(HHGear^.Hedgehog)^);
 with HHGear^ do
 	begin
 	State:= State and not gstAttacking;
--- a/hedgewars/uConsts.pas	Sun Jun 21 15:36:13 2009 +0000
+++ b/hedgewars/uConsts.pas	Sun Jun 21 15:36:50 2009 +0000
@@ -1428,7 +1428,7 @@
 			TimeAfterTurn: 3000;
 			minAngle: 0;
 			maxAngle: 0;
-			isDamaging: true;
+			isDamaging: false;
 			SkipTurns: 0;
 			PosCount: 1;
 			PosSprite: sprWater)