| Author |
Message |
Steven Gustavson (Steven)
| | Posted on Wednesday, November 21, 2001 - 5:48 pm: | |
I was wondering, can either "on-board" or "pieces-remaining" tell if, for instance, the other player has a certain piece like a pawn still on the board? I'd hope there's a simple way to do it rather than a long elaborate set of commands. |
Dan Troyka (Dtroyka)
| | Posted on Friday, November 23, 2001 - 9:53 pm: | |
Unfortunately there is no simple test for this unless it's a win-condition, which automatically ends the game. So if you want to figure out whether the other player has any pawns remaining, because some move depends on this, you have to establish a way of keeping track of pawns, or else scan the entire board. Scans are pretty simple but not very good for the AI. Keeping track of how many pieces are left is more complicated, at least where the game starts with several pieces. Annuvin, which was just released last week, provides an example: the range of its pieces depends on how many friendly pieces are left. |
|