Files
Nicola 8170b700b2 Added final features for this release. Now only polishing (if needed) remains.
Features: Sacrifice-Node, Maintain-Node, Options for screen type, lightcolor and soundvolume, tied in sound effects, game pause when menu is open, visibly open up gate when opening it.
2026-05-10 14:09:14 +02:00

39 lines
648 B
C#

using Godot;
public partial class MainMenu : Control
{
[Export] private PanelContainer options;
public override void _Ready()
{
UIStyle.Apply(this);
}
public void OnPlayPressed()
{
GameData.loadSaveOnStart = false;
GetTree().ChangeSceneToFile("res://Scenes/WorldSetup.tscn");
}
public void OnLoadPressed()
{
if (!SaveGameManager.SaveExists()) return;
GameData.loadSaveOnStart = true;
GameData.showTutorial = false;
GetTree().ChangeSceneToFile("res://Scenes/Game.tscn");
}
public void OnQuitPressed()
{
GetTree().Quit();
}
public void OnOptionsPressed()
{
if (options == null) return;
options.Show();
}
}