Added check on possible actions. Added Game over dialogue.