Add legal move detection