Ejemplo n.º 1
0
        public void Intro()
        {
            GameRules();
            Console.ReadLine();
            Weather weather = new Weather();

            weather.ActualWeather();
            StartGame();
        }
Ejemplo n.º 2
0
        //MAIN MENU//
        public void MainMenu(Player player, Game game, Day currentDay, Weather CurrentWeather, UserInterface UI, Random random)
        {
            Console.WriteLine("Welcome to the main menu. Would you like to visit the store, check the weather forcast, or start your day? (make sure you have the supplies you need to make lemonade for the day).");
            Console.WriteLine("1 = visit store\n2 = check forcast\n3 = start the day\n4 = check inventory\n5 = quit game");
            string userInput = Console.ReadLine();

            if (dayNumber == 8)
            {
                Console.WriteLine($"You have reached the end of the week! You have a total of ${player.playerMoney}");
                Console.WriteLine("Thank you for playing!");
                Console.ReadLine();
                return;
            }
            switch (userInput)
            {
            case "1":
                PlayerStoreOptions(player, game, currentDay, CurrentWeather, UI, random);
                break;

            case "2":
                Console.WriteLine("the forcast for today is " + CurrentWeather.weather + " and " + CurrentWeather.temp + " degrees.");
                Console.ReadLine();
                MainMenu(player, game, currentDay, CurrentWeather, UI, random);
                break;

            case "3":
                Console.WriteLine("You are now begining day number " + dayNumber);
                Console.ReadLine();
                dayNumber += 1;
                CurrentWeather.ActualWeather(random);
                game.StartPlayerSetup(player, game, currentDay, CurrentWeather, UI, random);
                game.StartDay(game);
                break;

            case "4":
                Console.WriteLine($"You have {player.inventory.NumberOfLemon} lemons, {player.inventory.NumberOfSugar} sugar cubes, and {player.inventory.NumberOfIce} ice cubes");
                Console.WriteLine($"You have ${player.playerMoney}");
                Console.ReadLine();
                MainMenu(player, game, currentDay, CurrentWeather, UI, random);
                break;

            case "5":
                Console.WriteLine("Thanks for playing!");
                Console.ReadLine();
                Environment.Exit(0);
                break;

            default:
                Console.WriteLine("Sorry we didn't understand please try again.");
                MainMenu(player, game, currentDay, CurrentWeather, UI, random);
                break;
            }
        }
Ejemplo n.º 3
0
 public void DaysActualWeather()
 {
     weather.ActualWeather(weather.condition, weather.temperature);
 }
Ejemplo n.º 4
0
 public void StartDay(Game game)
 {
     currentDay = new Day(player, UI, CurrentWeather);
     CurrentWeather.ActualWeather(random);
     currentDay.CallAllMethodsDay(player, game, currentDay, CurrentWeather, random);
 }