# HG changeset patch # User unc0rr # Date 1210774398 0 # Node ID ab4d98858a40456d380d5f4356fedad6c1ddce15 # Parent 3f61bd3b08fd20febad76e42113a015ee8d8dd0c Fix some bugs with dropping from parachute diff -r 3f61bd3b08fd -r ab4d98858a40 hedgewars/GSHandlers.inc --- a/hedgewars/GSHandlers.inc Tue May 13 20:00:48 2008 +0000 +++ b/hedgewars/GSHandlers.inc Wed May 14 14:13:18 2008 +0000 @@ -1135,7 +1135,6 @@ procedure doStepParachute(Gear: PGear); var HHGear: PGear; - Timer: Longword; begin HHGear:= PHedgehog(Gear^.Hedgehog)^.Gear; @@ -1144,7 +1143,7 @@ OnUsedAmmo(PHedgehog(HHGear^.Hedgehog)^); ApplyAmmoChanges(PHedgehog(HHGear^.Hedgehog)^); -HHGear^.State:= HHGear^.State and not (gstAttacking or gstAttacked); +HHGear^.State:= HHGear^.State and not (gstAttacking or gstAttacked or gstMoving); HHGear^.Message:= HHGear^.Message and not gm_Attack; Gear^.doStep:= @doStepParachuteWork; diff -r 3f61bd3b08fd -r ab4d98858a40 hedgewars/HHHandlers.inc --- a/hedgewars/HHHandlers.inc Tue May 13 20:00:48 2008 +0000 +++ b/hedgewars/HHHandlers.inc Wed May 14 14:13:18 2008 +0000 @@ -476,9 +476,13 @@ Attack(Gear) // should be before others to avoid desync with '/put' msg and changing weapon msgs else else with PHedgehog(Gear^.Hedgehog)^ do - if ((CurAmmoGear^.Ammo^.Propz and ammoprop_AltAttack) <> 0) + if ((CurAmmoGear^.Ammo^.Propz and ammoprop_AltAttack) <> 0) and ((Gear^.Message and gm_LJump) <> 0) - and (((Ammo^[CurSlot, CurAmmo].Propz) and ammoprop_AltUse) <> 0) then Attack(Gear); + and (((Ammo^[CurSlot, CurAmmo].Propz) and ammoprop_AltUse) <> 0) then + begin + Gear^.Message:= Gear^.Message and not gm_LJump; + Attack(Gear) + end; if (CurAmmoGear = nil) or ((CurAmmoGear^.Ammo^.Propz and ammoprop_AltAttack) <> 0) then diff -r 3f61bd3b08fd -r ab4d98858a40 hedgewars/hwengine.dpr --- a/hedgewars/hwengine.dpr Tue May 13 20:00:48 2008 +0000 +++ b/hedgewars/hwengine.dpr Wed May 14 14:13:18 2008 +0000 @@ -66,7 +66,7 @@ //////////////////////////////// procedure DoTimer(Lag: LongInt); const MusicTimerTicks: Longword = 0; -var s: string; +//var s: string; begin inc(RealTicks, Lag); diff -r 3f61bd3b08fd -r ab4d98858a40 hedgewars/uConsts.pas --- a/hedgewars/uConsts.pas Tue May 13 20:00:48 2008 +0000 +++ b/hedgewars/uConsts.pas Wed May 14 14:13:18 2008 +0000 @@ -592,6 +592,7 @@ Probability: 100; NumberInCase: 1; Ammo: (Propz: ammoprop_NoCrosshair or + ammoprop_AttackInMove or ammoprop_DontHold or ammoprop_AltUse; Count: 2;