mirror of
https://gitea.wildfiregames.com/0ad/0ad.git
synced 2026-06-20 21:43:50 +00:00
Move this.turn to PetraBot
The `BaseAI` shouldn't make assumptions whether the AI runs every turn.
This commit is contained in:
@@ -6,9 +6,6 @@ export function BaseAI(settings)
|
||||
return;
|
||||
|
||||
this.player = settings.player;
|
||||
|
||||
// played turn, in case you don't want the AI to play every turn.
|
||||
this.turn = 0;
|
||||
}
|
||||
|
||||
/** Return a simple object (using no classes etc) that will be serialized into saved games */
|
||||
|
||||
@@ -9,6 +9,8 @@ export function PetraBot(settings)
|
||||
{
|
||||
BaseAI.call(this, settings);
|
||||
|
||||
// played turn, because Petra doesn't play every turn.
|
||||
this.turn = 0;
|
||||
this.playedTurn = 0;
|
||||
this.elapsedTime = 0;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user