You are browsing as a guest. Sign up (or log in) to start making projects!

1h 40m 42s logged

Got it! Now blocks, checks, pins, and captures work. Everything works. The only missing thing is chastling wich might be a bit tricky to implement. The way the code works now, is the following:

  • Every possable move from a piece gets calculated
  • Every possition after the move gets looked at
  • If the king is attacked in any possition delet the move from the possable moves.

This may not ultimatle be the fasters way, but it’s fast enough for now. I might implement a even faster algorithem in the futur, but I like this one because it is just so clean and readable.

0
1

Comments 0

No comments yet. Be the first!