Correctly able to select and deselect pieces