# HG changeset patch # User nemo # Date 1315791042 14400 # Node ID 09daa06191d7335624a12e6796a838149d6a8976 # Parent b9b9fb00c9dd389c668ab0a2f8b4549c3fbb6f13 Since we are tweaking molotov. make the flame flickery and add a drowning frame diff -r b9b9fb00c9dd -r 09daa06191d7 hedgewars/GSHandlers.inc --- a/hedgewars/GSHandlers.inc Mon Sep 12 00:47:49 2011 +0200 +++ b/hedgewars/GSHandlers.inc Sun Sep 11 21:30:42 2011 -0400 @@ -512,6 +512,7 @@ i, gX, gY: LongInt; dX, dY: hwFloat; Fire: PGear; + smoke: PVisualGear; begin AllInactive := false; @@ -519,9 +520,12 @@ CalcRotationDirAngle(Gear); // let's add some smoke depending on speed - i:= max(32,152 - hwRound(Distance(Gear^.dX,Gear^.dY)*120)); + i:= max(32,152 - hwRound(Distance(Gear^.dX,Gear^.dY)*120))+random(10); if (GameTicks mod i) = 0 then - AddVisualGear(hwRound(Gear^.X)-round(cos((Gear^.DirAngle+50) * pi / 180)*20), hwRound(Gear^.Y)-round(sin((Gear^.DirAngle+50) * pi / 180)*20), vgtSmoke); + begin + smoke:= AddVisualGear(hwRound(Gear^.X)-round(cos((Gear^.DirAngle+50) * pi / 180)*20), hwRound(Gear^.Y)-round(sin((Gear^.DirAngle+50) * pi / 180)*20), vgtSmoke); + if smoke <> nil then smoke^.Scale:= 0.75; + end; if (Gear^.State and gstCollision) <> 0 then begin diff -r b9b9fb00c9dd -r 09daa06191d7 hedgewars/uGears.pas --- a/hedgewars/uGears.pas Mon Sep 12 00:47:49 2011 +0200 +++ b/hedgewars/uGears.pas Sun Sep 11 21:30:42 2011 -0400 @@ -1018,7 +1018,7 @@ if (GameFlags and gfLowGravity) = 0 then begin - cGravity:= cMaxWindSpeed * 2; + cGravity:= cMaxWindSpeed / 100; cGravityf:= 0.00025 * 2 end; diff -r b9b9fb00c9dd -r 09daa06191d7 hedgewars/uGearsRender.pas --- a/hedgewars/uGearsRender.pas Mon Sep 12 00:47:49 2011 +0200 +++ b/hedgewars/uGearsRender.pas Sun Sep 11 21:30:42 2011 -0400 @@ -886,7 +886,10 @@ gtGrenade: DrawRotated(sprBomb, x, y, 0, Gear^.DirAngle); gtSnowball: DrawRotated(sprSnowball, x, y, 0, Gear^.DirAngle); gtGasBomb: DrawRotated(sprCheese, x, y, 0, Gear^.DirAngle); - gtMolotov: DrawRotated(sprMolotov, x, y, 0, Gear^.DirAngle); + + gtMolotov: if (Gear^.State and gstDrowning) = 0 then + DrawRotatedF(sprMolotov, x, y, (RealTicks div 125) mod 8, hwSign(Gear^.dX), Gear^.DirAngle) + else DrawSprite(sprMolotov, x, y, 8); gtRCPlane: begin if (Gear^.Tag = -1) then diff -r b9b9fb00c9dd -r 09daa06191d7 hedgewars/uVariables.pas --- a/hedgewars/uVariables.pas Mon Sep 12 00:47:49 2011 +0200 +++ b/hedgewars/uVariables.pas Sun Sep 11 21:30:42 2011 -0400 @@ -490,7 +490,7 @@ (FileName: 'amMolotov'; Path: ptHedgehog; AltPath: ptNone; Texture: nil; Surface: nil; Width: 32; Height: 32; imageWidth: 0; imageHeight: 0; saveSurf: false; priority: tpMedium; getDimensions: false; getImageDimensions: true),//sprHandMolotov (FileName: 'Molotov'; Path: ptGraphics; AltPath: ptNone; Texture: nil; Surface: nil; - Width: 16; Height: 16; imageWidth: 0; imageHeight: 0; saveSurf: false; priority: tpMedium; getDimensions: false; getImageDimensions: true),// sprMolotov + Width: 32; Height: 32; imageWidth: 0; imageHeight: 0; saveSurf: false; priority: tpMedium; getDimensions: false; getImageDimensions: true),// sprMolotov (FileName: 'Smoke'; Path: ptGraphics; AltPath: ptNone; Texture: nil; Surface: nil; Width: 22; Height: 22; imageWidth: 0; imageHeight: 0; saveSurf: false; priority: tpHighest; getDimensions: false; getImageDimensions: true),// sprSmoke (FileName: 'SmokeWhite'; Path: ptGraphics; AltPath: ptNone; Texture: nil; Surface: nil; diff -r b9b9fb00c9dd -r 09daa06191d7 share/hedgewars/Data/Graphics/Molotov.png Binary file share/hedgewars/Data/Graphics/Molotov.png has changed