hedgewars/uAI.pas
changeset 8959 ad680848a5c9
parent 8946 3e07b8ff2ae1
child 8965 b4f10ff6ea90
equal deleted inserted replaced
8958:3818b38d72c0 8959:ad680848a5c9
   124             and ((not rareChecks) or ((AmmoTests[a].flags and amtest_Rare) = 0))
   124             and ((not rareChecks) or ((AmmoTests[a].flags and amtest_Rare) = 0))
   125             and ((i = 0) or ((AmmoTests[a].flags and amtest_NoTarget) = 0))
   125             and ((i = 0) or ((AmmoTests[a].flags and amtest_NoTarget) = 0))
   126             then
   126             then
   127             begin
   127             begin
   128 {$HINTS OFF}
   128 {$HINTS OFF}
   129             Score:= AmmoTests[a].proc(Me, Targets.ar[i].Point, BotLevel, ap);
   129             Score:= AmmoTests[a].proc(Me, Targets.ar[i], BotLevel, ap);
   130 {$HINTS ON}
   130 {$HINTS ON}
   131             if Actions.Score + Score > BestActions.Score then
   131             if Actions.Score + Score > BestActions.Score then
   132                 if (BestActions.Score < 0) or (Actions.Score + Score > BestActions.Score + Byte(BotLevel) * 2048) then
   132                 if (BestActions.Score < 0) or (Actions.Score + Score > BestActions.Score + Byte(BotLevel) * 2048) then
   133                     begin
   133                     begin
   134                     BestActions:= Actions;
   134                     BestActions:= Actions;