equal
deleted
inserted
replaced
208 for i:= 0 to Pred(Count) do |
208 for i:= 0 to Pred(Count) do |
209 with cinfos[i] do |
209 with cinfos[i] do |
210 if (Gear <> cGear) and |
210 if (Gear <> cGear) and |
211 (sqr(mx - x) + sqr(my - y) <= sqr(Radius + Gear^.Radius + 2)) and |
211 (sqr(mx - x) + sqr(my - y) <= sqr(Radius + Gear^.Radius + 2)) and |
212 ((mx > x) xor (Dir > 0)) then |
212 ((mx > x) xor (Dir > 0)) then |
213 if (cGear^.Kind in [gtHedgehog, gtMine, gtExplosives]) and ((Gear^.State and gstNotKickable) = 0) then |
213 if ((cGear^.Kind in [gtHedgehog, gtMine]) and ((Gear^.State and gstNotKickable) = 0)) or |
|
214 // only apply X kick if the barrel is knocked over |
|
215 ((cGear^.Kind = gtExplosives) and ((cGear^.State and gsttmpflag) <> 0)) then |
214 begin |
216 begin |
215 with cGear^ do |
217 with cGear^ do |
216 begin |
218 begin |
217 if (Kind <> gtExplosives) or ((State and gsttmpflag) <> 0) then dX:= Gear^.dX; |
219 dX:= Gear^.dX; |
218 dY:= Gear^.dY * _0_5; |
220 dY:= Gear^.dY * _0_5; |
219 State:= State or gstMoving; |
221 State:= State or gstMoving; |
220 Active:= true |
222 Active:= true |
221 end; |
223 end; |
222 DeleteCI(cGear); |
224 DeleteCI(cGear); |