hedgewars/HHHandlers.inc
changeset 835 6f567934cc44
parent 829 1209eb768acf
child 836 150c7c87e66c
equal deleted inserted replaced
834:5687fa57a6c1 835:6f567934cc44
   405    if Gear^.Damage > 0 then
   405    if Gear^.Damage > 0 then
   406       Gear^.State:= Gear^.State and not (gstHHJumping or gstHHHJump);
   406       Gear^.State:= Gear^.State and not (gstHHJumping or gstHHHJump);
   407    exit
   407    exit
   408    end;
   408    end;
   409 
   409 
   410 if ((Gear^.State and gstMoving) <> 0)
   410 if ((Gear^.State and gstMoving) <> 0) then
   411    or (StepTicks = cHHStepTicks)
   411 	begin
   412    or (CurAmmoGear <> nil) then // we're moving
   412 	if (StepTicks = cHHStepTicks)
   413    begin
   413 	or (CurAmmoGear <> nil) then // we're moving
   414    // check for case with ammo
   414 		begin
   415    t:= CheckGearNear(Gear, gtCase, 36, 36);
   415 		// check for case with ammo
   416    if t <> nil then
   416 		t:= CheckGearNear(Gear, gtCase, 36, 36);
   417       PickUp(Gear, t)
   417 		if t <> nil then
   418    end;
   418 			PickUp(Gear, t)
       
   419 		end else
       
   420 		with PHedgehog(Gear^.Hedgehog)^ do
       
   421 			if (CurAmmoGear = nil)
       
   422 			and (Gear^.dY > _0_39)
       
   423 			and (Ammo^[CurSlot, CurAmmo].AmmoType = amParachute) then Gear^.Message:= Gear^.Message or gm_Attack
       
   424 	end;
   419 
   425 
   420 if CurAmmoGear <> nil then
   426 if CurAmmoGear <> nil then
   421    begin
   427    begin
   422    CurAmmoGear^.Message:= Gear^.Message;
   428    CurAmmoGear^.Message:= Gear^.Message;
   423    exit
   429    exit