public void SendKey(Menu sender, Keys key) { MenuActionEventArgs args = new MenuActionEventArgs(); args.PressedKey = key; OnButtonPressed(args, sender); }
private void MenuAction_ToScoreBoard(object sender, MenuActionEventArgs e) { menuManager.SetActiveMenu("scores"); gameState = GAMESTATE.GAMESTATE_SCORE_BOARD; }
private void MenuAction_ToOptions(object sender, MenuActionEventArgs e) { menuManager.SetActiveMenu("options"); gameState = GAMESTATE.GAMESTATE_OPTIONS_MENU; }
private void MenuAction_ToMain(object sender, MenuActionEventArgs e) { menuManager.SetActiveMenu("mainMenu"); gameState = GAMESTATE.GAMESTATE_MAIN_MENU; }
private void MenuAction_Exit(object sender, MenuActionEventArgs e) { Exit(); }
private void MenuAction_StartGame(object sender, MenuActionEventArgs e) { gameField.Restart(); gameState = GAMESTATE.GAMESTATE_GAME_RUNNING; }