Ludii Forum
(is Repeat InGame) false positives? - Printable Version

+- Ludii Forum (https://ludii.games/forums)
+-- Forum: Problems (https://ludii.games/forums/forumdisplay.php?fid=5)
+--- Forum: Game Problems (https://ludii.games/forums/forumdisplay.php?fid=17)
+--- Thread: (is Repeat InGame) false positives? (/showthread.php?tid=280)



(is Repeat InGame) false positives? - dale walton - 11-24-2020

In the attached experimental game under development, I wanted to treat a repeat position like a pass for the end game position.

I used:
(define "Finished"
  (or
    (all Passed)
    (and
      (was Pass)
      (is Repeat InGame)
    )
  )
)


To define my end condition.

I did not specify anything else about repeats in the game -- no meta rule for example.

In a trial also supplied, the game ends after a single pass, with what appears to be a forced pass, as no moves are shown as permitted.  However If I comment out the define and use (all Passed) instead, the trial shows several moves are still available.  The position is not a repeated position.  Thus I surmise that this is a bug or that I am misusing the  (is Repeat) ludeme.

I've been running the game with all Passed instead and on a long run of around 200 moves, I am seeing missed placement locations. -- so it could have to do with the definition of the add move / LineOfSight as well or instead.


RE: (is Repeat InGame) false positives? - Eric Piette - 11-24-2020

Hi,

I am not sure to understand the problem here.
I loaded your trial and go back one move, and I see many legal moves there, so the pass is not a forced pass, that's just a pass from the list of the legal moves here.

If you think a problem is there with the (is Repeat ...) ludeme, can you make a simple example to show it with a simple game and a short number of rules?

Thanks.

Regards,
Eric


RE: (is Repeat InGame) false positives? - dale walton - 11-24-2020

The point is no moves are shown by Ludii after the single pass, when in fact there are moves available.
Loading the same trial at the same point after commenting out the define shows the available moves.

Those moves are not repeat positions.

I don't know if I can make a simple "proof of bug"  Some bugs may only appear in complex situations, and I am a user/game writer, not a developer familiar with the innards of Ludii.
I am hoping you value evidence of rare bugs as well as those easy to simulate. They can help correct issues that make the program unreliable in unexpected ways.

If this is a game script error, I hope it can help you in improving the documentation, by showing where points need to be explained / explained more clearly.