19 lines
485 B
19 lines
485 B
using UnityEngine; |
|
|
|
public class Main : MonoBehaviour |
|
{ |
|
public static LocationSimulator LocationSimulator { get; private set; } |
|
public static EventManager Event { get; set; } |
|
|
|
private void Awake() |
|
{ |
|
DontDestroyOnLoad(this); |
|
LocationSimulator = GetComponentInChildren<LocationSimulator>(); |
|
Event = GetComponentInChildren<EventManager>(); |
|
} |
|
private void OnDestroy() |
|
{ |
|
Event = null; |
|
LocationSimulator = null; |
|
} |
|
}
|
|
|