fix clear legal moves bug