Closed niklasf closed 3 years ago
@wspeirs Thanks, this looks good so far. There are a few issues with chess variants. I believe it does not handle explosions in Atomic
(a bug), and does not consider remaining checks in ThreeCheck
(avoidable collisions).
Maybe you can make the variants implement a supporting trait ZobristHashable
? That would allow skipping those variants and third-party variants.
@niklasf I did not take into account any of the variants. Looking at the code around play_unchecked
for Atomic
, it wouldn't be hard to encode the logic (removing the piece hashes when "exploding"); however, I'm unsure how to work this in via the feature gate mechanism in Rust. I think I need specialization, unless there's some "magic" we can perform with the feature-gate code. Any ideas on how to implement would be great!
Assuming we figure out the specialization/feature-gate stuff for Atomic
, then it would be a bit more work to get ThreeCheck
working. I'd need to add 6 more values to build.rs
that represent how many checks are left for each side. Not terribly difficult, but slightly more work than Atomic
.
Continued in #46.
for #40