Files
Gnome-s-Bounty/Assets/Scripts/Utilities/MainMenu.cs
T
vova 39e4e51866 Add player controller, state management, and input handling
- Implemented PlayerController.cs to manage player movement and actions.
- Created PlayerState.cs to track player lives, coins, and key status.
- Added CameraFollow.cs for smooth camera movement following the player.
- Developed Character.cs as an abstract class for character behavior.
- Introduced Enums.cs for defining TreasureType and MapElementType.
- Added IDoor interface for door interactions.
- Created InputActions.cs for handling player input actions.
- Implemented MainMenu.cs for basic menu functionality including play and exit options.
2026-06-17 22:43:59 +03:00

18 lines
332 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;
public class MainMenu : MonoBehaviour
{
public void Play()
{
SceneManager.LoadScene(SceneManager.GetActiveScene().buildIndex+1);
}
public void Exit()
{
Application.Quit();
}
}