equal
deleted
inserted
replaced
33 |
33 |
34 procedure doStepHedgehog(Gear: PGear); forward; |
34 procedure doStepHedgehog(Gear: PGear); forward; |
35 //////////////////////////////////////////////////////////////////////////////// |
35 //////////////////////////////////////////////////////////////////////////////// |
36 procedure doStepHedgehogDriven(Gear: PGear); |
36 procedure doStepHedgehogDriven(Gear: PGear); |
37 const StepTicks: LongWord = 0; |
37 const StepTicks: LongWord = 0; |
|
38 var t: PGear; |
38 begin |
39 begin |
39 if isinMultiShoot and (Gear.Damage = 0) then exit; |
40 if isinMultiShoot and (Gear.Damage = 0) then exit; |
40 AllInactive:= false; |
41 AllInactive:= false; |
41 if (TurnTimeLeft = 0) or (Gear.Damage > 0) then |
42 if (TurnTimeLeft = 0) or (Gear.Damage > 0) then |
42 begin |
43 begin |
44 and (CurAmmoGear = nil) then Gear.dX:= 0.0000001 * Sign(Gear.dX); |
45 and (CurAmmoGear = nil) then Gear.dX:= 0.0000001 * Sign(Gear.dX); |
45 Gear.State:= Gear.State and not gstHHDriven; |
46 Gear.State:= Gear.State and not gstHHDriven; |
46 if Gear.Damage > 0 then |
47 if Gear.Damage > 0 then |
47 Gear.State:= Gear.State and not gstHHJumping; |
48 Gear.State:= Gear.State and not gstHHJumping; |
48 exit |
49 exit |
|
50 end; |
|
51 |
|
52 // check for case with ammo |
|
53 t:= CheckGearNear(Gear, gtCase, 25, 25); |
|
54 if t <> nil then |
|
55 begin |
|
56 t.Message:= gm_Destroy; |
|
57 ; // take ammo from it |
49 end; |
58 end; |
50 |
59 |
51 if CurAmmoGear <> nil then |
60 if CurAmmoGear <> nil then |
52 begin |
61 begin |
53 CurAmmoGear.Message:= Gear.Message; |
62 CurAmmoGear.Message:= Gear.Message; |