It's just a basic minmax. The main mistake it makes is that if it can find an assured path to getting you it doesn't care how many moves in the future it is (even if it could win this turn).
That said, the audience is 6 year olds so I don't really want it to play perfectly!
Yup, I'm going to build out the reverse play when I find time in the next few weeks hopefully! I'll try to remember to comment here :)
Quite probably you did just run up against a bug in it! I'd have to see the position though.
Great question on the maximal theoretical length. Being pedantic I'd imagine infinite if I just move a knight back and forth and you move a king back and forth. (Though I disallow repeat moves for interests sake)
gus_massa|1 month ago
I guess when I played your game IIRC in a case the computer could have trapped me but it didn't. Perhaps I had an escape route that I didn't see.
(How is the maximal theoretical length of a game?)
My 9 y.o. daughter likes it, but she wants to play as the Kings too.
patrickdavey|1 month ago
Quite probably you did just run up against a bug in it! I'd have to see the position though.
Great question on the maximal theoretical length. Being pedantic I'd imagine infinite if I just move a knight back and forth and you move a king back and forth. (Though I disallow repeat moves for interests sake)