# HG changeset patch # User unc0rr # Date 1367955423 -14400 # Node ID b4f10ff6ea9057cd5f423f50fd7fa1585c9262a2 # Parent 962ede906da1672c93b5b8154a638b594980b226 IFDEF that score expectation logging diff -r 962ede906da1 -r b4f10ff6ea90 hedgewars/uAI.pas --- a/hedgewars/uAI.pas Tue May 07 15:34:36 2013 -0400 +++ b/hedgewars/uAI.pas Tue May 07 23:37:03 2013 +0400 @@ -486,7 +486,9 @@ SDL_UnlockMutex(ThreadLock); end; -//var scoreShown: boolean = false; +{$IFDEF DEBUGAI} +var scoreShown: boolean = false; +{$ENDIF} procedure ProcessBot; const cStopThinkTime = 40; @@ -508,17 +510,21 @@ if Gear^.Message <> 0 then exit; - //scoreShown:= false; +{$IFDEF DEBUGAI} + scoreShown:= false; +{$ENDIF} StartThink(Gear); StartTicks:= GameTicks end else begin - {if not scoreShown then +{$IFDEF DEBUGAI} + if not scoreShown then begin if BestActions.Score > 0 then ParseCommand('/say Expected score = ' + inttostr(BestActions.Score div 1024), true); scoreShown:= true - end;} + end; +{$ENDIF} ProcessAction(BestActions, Gear) end else if ((GameTicks - StartTicks) > cMaxAIThinkTime)