private void updateLogic() {
		// not started state
		if (gameInfo.getState() == GameInfo.GameState.NOT_STARTED) {
			stateController.changeState(bufferedKeyboard, gameInfo);
		}

		// dead state
		if (gameInfo.getState() == GameInfo.GameState.DEAD) {
			stateController.changeState(bufferedKeyboard, gameInfo);

		}

		// restarting state
		if (gameInfo.getState() == GameInfo.GameState.RESTARTING) {
			reinitializeState();
			stateController.setState(GameInfo.GameState.NOT_STARTED, gameInfo);
		}

		// playing state
		if (gameInfo.getState().equals(GameInfo.GameState.PLAYING)) {
			gameInfoController.incrementFrame(gameInfo);

			if (gameInfo.getFrame() % gameInfo.getFramesPerMove() == 0) {

				snakeController.updateMovingDirection(bufferedKeyboard, snake);
				bufferedKeyboard.clear();

				if (collisionController.isMoveValid(board, snake)) {
					snakeController.move(snake);

					if (collisionController.isCollidingWithFruit(snake, fruit)) {
						fruitController.moveFruit(snake.getSegments(), board, fruit);
						fruitController.recolourFruit(fruit);
						snake.addSegment();
						gameInfoController.addScore(10, gameInfo);
					}
				}

				else {
					gameInfo.setState(GameInfo.GameState.DEAD);
				}
			}
		}
	}