kingdom
kingdom copied to clipboard
is_stalemate_by_rule function can't detect stalemate
@nmrugg
Found a bug in your code. You always depends on is_stalemate_by_rule variable for stalemate. However, when stalemate_by_rule == null, !stalemate_by_rule == true. Then either side must win. It will never go into the "else" clause.
https://github.com/nmrugg/kingdom/blob/a5e42d697881def5264a744e50c473b1196c6740/js/kingdom.js#L421