public void ShowMainMenu() { Render(); do { ConsoleKeyInfo pressedChar = Console.ReadKey(true); switch (pressedChar.Key) { case ConsoleKey.P: { PlayerSelectionMenu playerSelectionMenu = new PlayerSelectionMenu(); playerSelectionMenu.ShowPlayerSelectionMenu(); break; } case ConsoleKey.C: { CreditWindow creditWindow = new CreditWindow(); creditWindow.Render(); Console.ReadKey(); ShowMainMenu(); break; } case ConsoleKey.Q: { Environment.Exit(0); break; } } } while (checkingKeys); }
public GuiController() { _menuWindow = new MenuWindow(); _creditWindow = new CreditWindow(); _exitWindow = new ExitWindow(); _gameOverWindow = new GameOverWindow(); _highScoreWindow = new HighScoreWindow(); }
public Buttons_GUI_Controller(CreditWindow creditWindow, GameWindow gameWindow) { CreditWindow _CreditWindow = creditWindow; GameWindow _GameWindow = gameWindow; ButtonsInGameWindows = CreateButtonsList(_GameWindow.startButton, _GameWindow.creditsButton, _GameWindow.quitButton); // suarasai kokius nori mygtukus itraukti ButtonsInCreditWindows = CreateButtonsList(_CreditWindow.backButton); }
public GuiController() { gameWindow = new GameWindow(); creditWindow = new CreditWindow(); gameController = new GameController(); //Frame testWindow = new Frame(0, 20, 0, 40, '.'); //testWindow.Render(); }
private void ShowCredit() { if (creditWindow == null) { creditWindow = new CreditWindow(); gameWindows.Add(creditWindow); } creditWindow.Render(); }
static void Main() { Console.CursorVisible = false; GameWindow gameWindow = new GameWindow(); CreditWindow creditWindow = new CreditWindow(); Console.ReadKey(); StartGame(); Console.ReadKey(); }
public void ShowCreditMenu() { creditWindow = new CreditWindow(10, 10, 14, 14); creditWindow.Render(); ConsoleKeyInfo pressedChar; do { pressedChar = Console.ReadKey(true); } while (pressedChar.Key != ConsoleKey.Enter); menuWindow.Render(); }
// KONSTRUKTORIUS public Main_GUI_Controller() { CreditWindow = new CreditWindow(); GameWindow = new GameWindow(); _myGame = new GameController(); _Render_Controller = new Render_GUI_Controller(CreditWindow, GameWindow); _Gui_Buttons_Controller = new Buttons_GUI_Controller(CreditWindow, GameWindow); _ButtonsInGameWindow = _Gui_Buttons_Controller.ButtonsInGameWindows; _Gui_User_Controller = new User_GUI_Controller(_ButtonsInGameWindow, _myGame, _Render_Controller, GameWindow, _Gui_Buttons_Controller); }
static void Main(string[] args) { Console.CursorVisible = false; GameWindow gameWindow = new GameWindow(); CreditWindow creditWindow = new CreditWindow(); GuiController guiController = new GuiController(gameWindow, creditWindow); guiController.ShowMenu(); guiController.UserActivity(); Console.WriteLine("PROGRAMA BAIGTA"); }
static void Main() { Console.CursorVisible = false; GameWindow gameWindow = new GameWindow(); gameWindow.Render(); CreditWindow creditWindow = new CreditWindow(); creditWindow.Render(); Console.ReadKey(); //GameController myGame = new GameController(); //myGame.StartGame(); }
public GameOverControler(int lvl) { gameWindow = new GameOverWindow(gameOverMenuButons.Replay.ToString(), gameOverMenuButons.MainMenu.GetDescription(), gameOverMenuButons.Quit.ToString(), lvl); creditWindow = new CreditWindow(); }
//MyGameGui.GameWindow gameWindow = new MyGameGui.GameWindow(); public void ShowMenu() { GameWindow _gameWindow = new GameWindow(); CreditWindow creditWindow = new CreditWindow(); GameControler NewGame = new GameControler(); _gameWindow.AllButtons[0].SetActive(); _gameWindow.Render(); int i = 0; int k = 0; int q = _gameWindow.ButtonNr(); bool needToRender = true; do { //Console.Clear(); while (Console.KeyAvailable) { ConsoleKeyInfo pressedChar = Console.ReadKey(true); switch (pressedChar.Key) { case ConsoleKey.Escape: needToRender = false; break; case ConsoleKey.RightArrow: k = i; if (i == q) { i -= q; } else { i += 1; } _gameWindow.AllButtons[i].SetActive(); _gameWindow.AllButtons[i].Render(); _gameWindow.AllButtons[k].SetInActive(); _gameWindow.AllButtons[k].Render(); break; case ConsoleKey.LeftArrow: k = i; if (i == 0) { i += q; } else { i -= 1; } _gameWindow.AllButtons[i].SetActive(); _gameWindow.AllButtons[i].Render(); _gameWindow.AllButtons[k].SetInActive(); _gameWindow.AllButtons[k].Render(); break; case ConsoleKey.Enter: if (i == 0) { NewGame.StartGame(); _gameWindow.Render(); } else if (i == 1) { creditWindow.ShowCredits(); _gameWindow.Render(); } else { needToRender = false; } break; } } } while (needToRender); }
public Render_GUI_Controller(CreditWindow creditWindow, GameWindow gameWindow) { _creditWindow = creditWindow; _gameWindow = gameWindow; }
public GuiController() { gameWindow = new GameWindow(); creditWindow = new CreditWindow(); myGame = new GameController(); }
public GuiController() // guicontroller konstruktorius sukuria game ir credit window objektus { GameWindow _gameWindow = new GameWindow(); CreditWindow _creditWindow = new CreditWindow(); }
public GuiControler() { gameWindow = new GameWindow(); creditWindow = new CreditWindow(); gameController = new GameController(this); }
/// <summary> /// Контекстное меню. добавление кредита /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void BtnAddLizing_Click(object sender, RoutedEventArgs e) { CreditWindow CW = new CreditWindow(this.lvClients.SelectedItem as IBankClient); CW.Show(); }
public MainMenuControler() { gameWindow = new MainMenuWindow(mainMenuButons.Start.ToString(), mainMenuButons.Credits.ToString(), mainMenuButons.Quit.ToString()); creditWindow = new CreditWindow(); }
public void ShowCreditWindow() { CreditWindow creditWindow = new CreditWindow(); creditWindow.Render(); }
public void ShowCreditWindow() { creditWindow = new CreditWindow(28, 10, 60, 18, '%'); creditWindow.Render(); ActivateCreditMenu(); }
public PauseMenuControler() { gameWindow = new PauseWindow(gameOverMenuButons.Continue.ToString(), gameOverMenuButons.MainMenu.GetDescription(), gameOverMenuButons.Quit.ToString()); creditWindow = new CreditWindow(); }