35 lines
1.0 KiB
C#
35 lines
1.0 KiB
C#
using System;
|
|||
|
|
using System.Collections.Generic;
|
||
|
|
using System.Linq;
|
||
|
|
using System.Text;
|
||
|
|
using System.Threading.Tasks;
|
||
|
|
using EvilSatellites.Menu;
|
||
|
|
using EvilSatellites.Screens;
|
||
|
|
|
||
|
|
namespace EvilSatellites.Screens
|
||
|
|
{
|
||
|
|
public class MainMenuScreen : MenuScreen
|
||
|
|
{
|
||
|
|
public override void Activate()
|
||
|
|
{
|
||
|
|
|
||
|
|
MenuOptions = new MenuContainer("Main Menu", "Navigate with up and down arrows,, and enter to select.");
|
||
|
|
MenuOptions.Add(new MenuEntry("Start", "Start the game"))
|
||
|
|
.Add(new MenuEntry("Exit", "Exit the game"))
|
||
|
|
.Add(new MenuEntry("Something Else", "Do something else"));
|
||
|
|
base.Activate();
|
||
|
|
}
|
||
|
|
|
||
|
|
public override void SelectItem()
|
||
|
|
{
|
||
|
|
Manager.Sound.PlayOneshot(@"sfx/ui/menuChoose.wav");
|
||
|
|
if (CursorPosition == 0)
|
||
|
|
{
|
||
|
|
Manager.AddScreen(new GameScreen());
|
||
|
|
Manager.RemoveScreen(this);
|
||
|
|
Manager.Game.ResetElapsedTime();
|
||
|
|
}
|
||
|
|
}
|
||
|
|
}
|
||
|
|
}
|