#4 create core game state machine