Files
DougDiggem/Assets/Scripts/GameManager.cs
T
2025-06-20 22:58:44 -05:00

25 lines
564 B
C#

using UnityEngine;
public class GameManager : MonoBehaviour
{
public static GameManager Instance { get; private set; }
public DialogueManager DialogueManager { get; private set; }
private void Awake()
{
// If there is an instance, and it's not me, delete myself.
if (Instance != null && Instance != this)
{
Destroy(this);
}
else
{
Instance = this;
DontDestroyOnLoad(gameObject);
DialogueManager = GetComponent<DialogueManager>();
}
}
}