| Author |
Message |
Jeff Zeitlin (Jzeitlin)
| | Posted on Monday, September 22, 2003 - 10:55 am: | |
I've decided to try to implement Krieg (see http://www.chessvariants.com/small.dir/krieg.html) as a ZOG. The only thing I can't see how to implement is the restriction that a player may not move the same piece on two consecutive moves of that player. Hints, pointers, clue-by-fours for missing the obvious? |
Cameron Browne (Camb)
| | Posted on Tuesday, September 23, 2003 - 8:19 am: | |
Hi Jeff, You might try giving each piece an attribute, perhaps called "did-move". When a piece is moved then its "did-move" is set to true, and false for all other pieces belonging to the player. No piece with "did-move" set to true can be moved. Cameron PS. I can't vouch for this approach - just got back from holidays and my brain is still fuzzy |
John Kewley (Jkew)
| | Posted on Monday, September 29, 2003 - 12:51 am: | |
The tricky bit is going through all your pieces that you didn't move setting them to false (not that hard, but not trivial and it'd cost on time) Of course last_from? and last_to? are no use as they would match other player in a 2 player game. It'd be nice if they could be parameterised by the player or the move type. Also maybe a check whether the "move" was a drop, move or capture. (My Chu Shogi rules would have been a lot easier with this enhancement). JK |
|