Wrote some code that checks for player turn