Improved checking of whether players can move or not