static void Main(string[] args) { Tools.SetProjectDirectory(); Application.Init(); MainScreen screen = new MainScreen(); screen.window.ShowAll(); Application.Run(); }
private void btnFinished_Click(object sender, EventArgs e) { if (playerName == "") { lblConfirmation.Text = "You did not enter a name!"; return; } if (!classHasBeenSelected) { lblSelectedClass.Text = "You did not pick a class!"; return; } GameSession gameSession = new GameSession(playerName, playerClass); Hide(); MainScreen mainScreen = new MainScreen(gameSession); mainScreen.StartPosition = FormStartPosition.CenterParent; mainScreen.ShowDialog(this); Close(); }