Ticket #68 (defect)

Opened 9 months ago

Last modified 9 months ago

Can't castle after undoing castle move

Status: closed (fixed)

Reported by: hfelsh@gmail.com Assigned to: ioffe
Priority: major Milestone: Alpha release
Component: Caissa Version:
Severity: major Keywords:
Cc:

If the user castles, then performs an undo, then attempts to castle again, it will not allow the castle (Caissa says "illegal move detected".)

Change History

01/08/08 17:02:14: Modified by ioffe

  • status changed from new to assigned.

01/08/08 18:54:00: Modified by ioffe

  • milestone set to Alpha release.

01/08/08 19:05:31: Modified by ioffe

  • summary changed from Cann't catsle after undoing castle move to Can't castle after undoing castle move.

01/09/08 10:26:44: Modified by ioffe

  • status changed from assigned to closed.
  • resolution set to fixed.

It will work in most of the times. it won't allow you to castle in opposite direction, if the opposite rook was moved, but after undo got into original place. Caissa still remembers it was moved, since the check happens only once during castling undo. This algorithm just reached its limitation. In order to implement things properly, I will need to rewrite this logic from scratch. I will not do this right now. We might migrate to PGN notation later.

Proper way to do it

Create parallel history with allowable Castlings, and keep (non delta) states for each change. Detect move #, and update allowableCastlings with history record.

I am closing this issue for now.