03-28-2021, 04:36 AM
I find the analysis still hanging, and have thus made some revisions,
1) Shorten the piece names (cosmetic)
2) Use (set NextPlayer (player (mover) (then (move Pass)) instead of (move Set NextPlayer (player (mover)) as it is more natural (cosmetic)
3) distribute the consequences into the individual moves for clarity.
4) attempt to bring the game as close as possible to the spec posted in BGG. (Ludii is still imposing some of its own anti cycling restrictions on some move choices, - I can live with that, even if they are not in the actual logic. but I can't seem to get the script to implement the complete logic of my definition, and thus cycles are achievable in practice - which may be what is hanging the Analysis and AI.
The attached trial shows an example with cycling, and I don't understand how it is being allowed:
In the attached trial and new version. The final position is a duplicate after removal, but the removal move is behaving as if it did not detect the positional repeat.-- If it had, it would not have cleared the stalemate state, and would have advanced to the next player to make a removal.
Please check it out. There might also be an issue in the script of not detecting a situational repeat or of not finishing the set state consequences of a move when there is a forced pass - or this might have just been the same bug as above.
Or, else please respond as to what is wrong about what I am doing.
For Reference, here is a brief description of the game I posted on BGG:
-- Three types of pieces, with values 0, 1 and 2 respectively.
-- Goal: win when a group of exactly 4 of your stones, that contains minimum one of each type of piece, is present on the board at the end of your turn.
-- Score by tallying the value of each piece in the winning family.
-- If the winner simultaneously creates another family of his pieces on the board, score it also, --
-- But, do not score a simultaneously created family of the opponent's pieces for either player.
-- Locations surrounded by all 3 types (of either player) are unplaceable, and pieces on them are simultaneously removed at the end of each turn.
Rules:
If repeat position, remove one opponent's piece, then if this is a new position, take a normal turn:
Place if possible.
If not, move one step if possible,
If not, move again (i.e. treat the position as a repeat)
(Variant: treat a repeat position as a loss: opponent gets 1 point)
1) Shorten the piece names (cosmetic)
2) Use (set NextPlayer (player (mover) (then (move Pass)) instead of (move Set NextPlayer (player (mover)) as it is more natural (cosmetic)
3) distribute the consequences into the individual moves for clarity.
4) attempt to bring the game as close as possible to the spec posted in BGG. (Ludii is still imposing some of its own anti cycling restrictions on some move choices, - I can live with that, even if they are not in the actual logic. but I can't seem to get the script to implement the complete logic of my definition, and thus cycles are achievable in practice - which may be what is hanging the Analysis and AI.
The attached trial shows an example with cycling, and I don't understand how it is being allowed:
In the attached trial and new version. The final position is a duplicate after removal, but the removal move is behaving as if it did not detect the positional repeat.-- If it had, it would not have cleared the stalemate state, and would have advanced to the next player to make a removal.
Please check it out. There might also be an issue in the script of not detecting a situational repeat or of not finishing the set state consequences of a move when there is a forced pass - or this might have just been the same bug as above.
Or, else please respond as to what is wrong about what I am doing.
For Reference, here is a brief description of the game I posted on BGG:
-- Three types of pieces, with values 0, 1 and 2 respectively.
-- Goal: win when a group of exactly 4 of your stones, that contains minimum one of each type of piece, is present on the board at the end of your turn.
-- Score by tallying the value of each piece in the winning family.
-- If the winner simultaneously creates another family of his pieces on the board, score it also, --
-- But, do not score a simultaneously created family of the opponent's pieces for either player.
-- Locations surrounded by all 3 types (of either player) are unplaceable, and pieces on them are simultaneously removed at the end of each turn.
Rules:
If repeat position, remove one opponent's piece, then if this is a new position, take a normal turn:
Place if possible.
If not, move one step if possible,
If not, move again (i.e. treat the position as a repeat)
(Variant: treat a repeat position as a loss: opponent gets 1 point)