public static void TitleScreen() { int width = 28; PrintUtils.GetHash(width); PrintUtils.CenterPadHash("Welcome to Bordertale!", width); PrintUtils.CenterPadHash("- Play -", width); PrintUtils.CenterPadHash("- Resume -", width); PrintUtils.CenterPadHash("- Help -", width); PrintUtils.CenterPadHash("- Acknoledgements -", width); PrintUtils.CenterPadHash("- Quit -", width); PrintUtils.CenterPadHash("Copyright 2021 tejmen09", width); PrintUtils.GetHash(width); bool inLoop = true; while (inLoop) { string option = PrintUtils.Input().ToLower(); switch (option) { case "play": inLoop = false; MainGame.StartGame(); break; case "help": inLoop = false; HelpScreen(false); break; case "quit": inLoop = false; PrintUtils.GetHash(15); PrintUtils.CenterPadHash("GOODBYE!!", 15); PrintUtils.GetHash(15); Thread.Sleep(500); Environment.Exit(0); break; case "acknowledgements": inLoop = false; AcknowledgementsScreen(); break; case "resume": inLoop = false; MainGame.MainGameLoop(); break; default: Console.WriteLine("Please enter a valid command."); break; } } }
public static void HelpScreen(bool inGame) { if (!inGame) { Console.Clear(); } int width = 31; PrintUtils.GetHash(width, ConsoleColor.DarkBlue); PrintUtils.CenterPadHash("Help", width, ConsoleColor.DarkBlue); PrintUtils.LeftPadHash("• Type 'move' command to", width, ConsoleColor.DarkBlue); PrintUtils.LeftPadHash(" move", width, ConsoleColor.DarkBlue); PrintUtils.LeftPadHash("• Type your commands to do", width, ConsoleColor.DarkBlue); PrintUtils.LeftPadHash(" them", width, ConsoleColor.DarkBlue); PrintUtils.LeftPadHash("• Type 'look' to inspect", width, ConsoleColor.DarkBlue); PrintUtils.LeftPadHash(" something", width, ConsoleColor.DarkBlue); PrintUtils.LeftPadHash("• Type 'act' to do what you", width, ConsoleColor.DarkBlue); PrintUtils.LeftPadHash(" can on your place", width, ConsoleColor.DarkBlue); PrintUtils.LeftPadHash("• If you find a Dungeon,", width, ConsoleColor.DarkBlue); PrintUtils.LeftPadHash(" please help to excavate it", width, ConsoleColor.DarkBlue); PrintUtils.LeftPadHash("• Find more weapons hidden", width, ConsoleColor.DarkBlue); PrintUtils.LeftPadHash(" in chests to kill monsters", width, ConsoleColor.DarkBlue); PrintUtils.LeftPadHash("• Go to the store to buy", width, ConsoleColor.DarkBlue); PrintUtils.LeftPadHash(" armour", width, ConsoleColor.DarkBlue); PrintUtils.LeftPadHash("• Equip your armour for", width, ConsoleColor.DarkBlue); PrintUtils.LeftPadHash(" extra protection.", width, ConsoleColor.DarkBlue); PrintUtils.CenterPadHash("Copyright 2019 tejmen09", width, ConsoleColor.DarkBlue); PrintUtils.GetHash(width, ConsoleColor.DarkBlue); switch (inGame) { case true: MainGame.MainGameLoop(); break; default: TitleScreen(); break; } }