Adjust flame parameters to produce more damage
authorunc0rr
Tue, 06 Jan 2009 14:18:09 +0000
changeset 1586 2c6f1d1f43c1
parent 1585 9f9138531070
child 1587 b8a3d449bed7
Adjust flame parameters to produce more damage
hedgewars/GSHandlers.inc
hedgewars/uConsts.pas
hedgewars/uFloat.pas
hedgewars/uGears.pas
--- a/hedgewars/GSHandlers.inc	Tue Jan 06 11:30:50 2009 +0000
+++ b/hedgewars/GSHandlers.inc	Tue Jan 06 14:18:09 2009 +0000
@@ -1130,21 +1130,18 @@
 
 ////////////////////////////////////////////////////////////////////////////////
 procedure doStepFlame(Gear: PGear);
-var cWindFactor: hwFloat;
 begin
 AllInactive:= false;
 
 if not TestCollisionYwithGear(Gear, 1) then
 	begin
-	cWindFactor:= cWindSpeed * 270;
-	
-	if hwAbs(Gear^.dX - cWindFactor) > _0_01 then
-		Gear^.dX:= (Gear^.dX - cWindFactor) * _0_995 + cWindFactor;
+	if hwAbs(Gear^.dX) > _0_01 then
+		Gear^.dX:= Gear^.dX * _0_995;
 
 	Gear^.dY:= Gear^.dY + cGravity;
-	if hwAbs(Gear^.dY) > _0_1 then Gear^.dY:= Gear^.dY * _0_995;
+	if hwAbs(Gear^.dY) > _0_08 then Gear^.dY:= Gear^.dY * _0_995;
 	
-	Gear^.X:= Gear^.X + Gear^.dX;
+	Gear^.X:= Gear^.X + Gear^.dX + cWindSpeed * 270;
 	Gear^.Y:= Gear^.Y + Gear^.dY;
 	
 	if not (hwRound(Gear^.Y) < cWaterLine) then
@@ -1155,12 +1152,12 @@
 	end else begin
 	if Gear^.Timer > 0 then dec(Gear^.Timer)
 		else begin
-		Gear^.Radius:= 7;
-		AmmoShove(Gear, 3, 100);
+		Gear^.Radius:= 9;
+		AmmoShove(Gear, 4, 100);
 		Gear^.Radius:= 1;
 		doMakeExplosion(hwRound(Gear^.X), hwRound(Gear^.Y), 4, EXPLNoDamage);
 		dec(Gear^.Health);
-		Gear^.Timer:= 1250 - Gear^.Tag * 12
+		Gear^.Timer:= 450 - Gear^.Tag * 8
 		end
 	end;
 
@@ -1295,8 +1292,8 @@
 	case Gear^.State of
 			0: FollowGear:= AddGear(hwRound(Gear^.X), hwRound(Gear^.Y), gtAirBomb, 0, cBombsSpeed * Gear^.Tag, _0, 0);
 			1: FollowGear:= AddGear(hwRound(Gear^.X), hwRound(Gear^.Y), gtMine,    0, cBombsSpeed * Gear^.Tag, _0, 0);
-			2: for i:= -17 to 17 do
-				FollowGear:= AddGear(hwRound(Gear^.X), hwRound(Gear^.Y), gtFlame, 0, _0_01 * i, _0, 0);
+			2: for i:= -19 to 19 do
+				FollowGear:= AddGear(hwRound(Gear^.X) + i div 3, hwRound(Gear^.Y), gtFlame, 0, _0_001 * i, _0, 0);
 			end;
 	Gear^.dX:= Gear^.dX + int2hwFloat(30 * Gear^.Tag)
 	end;
--- a/hedgewars/uConsts.pas	Tue Jan 06 11:30:50 2009 +0000
+++ b/hedgewars/uConsts.pas	Tue Jan 06 14:18:09 2009 +0000
@@ -1086,7 +1086,7 @@
 			PosSprite: sprAmAirplane),
 			(NameId: sidDrill;
 			NameTex: nil;
-			Probability: 0;
+			Probability: 300;
 			NumberInCase: 1;
 			Ammo: (Propz: ammoprop_Power or
 							ammoprop_AltUse;
--- a/hedgewars/uFloat.pas	Tue Jan 06 11:30:50 2009 +0000
+++ b/hedgewars/uFloat.pas	Tue Jan 06 14:18:09 2009 +0000
@@ -71,6 +71,7 @@
             hwPi: hwFloat = (isNegative: false; QWordValue: 13493037704);
        _0_000004: hwFloat = (isNegative: false; QWordValue:       17179);
          _0_0002: hwFloat = (isNegative: false; QWordValue:      858993);
+         _0_0005: hwFloat = (isNegative: false; QWordValue:     2147484);
           _0_001: hwFloat = (isNegative: false; QWordValue:     4294967);
           _0_003: hwFloat = (isNegative: false; QWordValue:    12884902);
           _0_004: hwFloat = (isNegative: false; QWordValue:    17179869);
--- a/hedgewars/uGears.pas	Tue Jan 06 11:30:50 2009 +0000
+++ b/hedgewars/uGears.pas	Tue Jan 06 14:18:09 2009 +0000
@@ -295,9 +295,9 @@
      gtCluster: Result^.Radius:= 2;
       gtShover: Result^.Radius:= 20;
        gtFlame: begin
-                Result^.Tag:= Counter mod 64;
+                Result^.Tag:= Counter mod 32;
                 Result^.Radius:= 1;
-                Result^.Health:= 2;
+                Result^.Health:= 5;
                 if (Result^.dY.QWordValue = 0) and (Result^.dX.QWordValue = 0) then
                 	begin
                 	Result^.dY:= (getrandom - _0_8) * _0_03;