diff -r 78a68cc4d846 -r f7628ebfccde hedgewars/uAI.pas --- a/hedgewars/uAI.pas Thu Sep 20 20:00:10 2007 +0000 +++ b/hedgewars/uAI.pas Fri Sep 21 18:55:44 2007 +0000 @@ -45,7 +45,7 @@ until hasThread = 0 end; -with CurrentTeam^.Hedgehogs[CurrentTeam^.CurrHedgehog] do +with CurrentHedgehog^ do if Gear <> nil then if BotLevel <> 0 then begin @@ -68,7 +68,7 @@ for i:= 0 to Pred(Targets.Count) do if (Targets.ar[i].Score >= 0) and (not StopThinking) then begin - with CurrentTeam^.Hedgehogs[CurrentTeam^.CurrHedgehog] do + with CurrentHedgehog^ do a:= Ammo^[CurSlot, CurAmmo].AmmoType; aa:= a; repeat @@ -115,7 +115,7 @@ if a = High(TAmmoType) then a:= Low(TAmmoType) else inc(a) until (a = aa) or - (CurrentTeam^.Hedgehogs[CurrentTeam^.CurrHedgehog].AttacksNum > 0) or + (CurrentHedgehog^.AttacksNum > 0) or StopThinking end end; @@ -317,7 +317,7 @@ const StartTicks: Longword = 0; cStopThinkTime = 40; begin -with CurrentTeam^.Hedgehogs[CurrentTeam^.CurrHedgehog] do +with CurrentHedgehog^ do if (Gear <> nil) and ((Gear^.State and gstHHDriven) <> 0) and (TurnTimeLeft < cHedgehogTurnTime - 50) then