mirror of
https://github.com/misternebula/quantum-space-buddies.git
synced 2025-01-25 15:35:22 +00:00
15 lines
362 B
C#
15 lines
362 B
C#
|
using UnityEngine;
|
|||
|
|
|||
|
namespace QSB.Utility
|
|||
|
{
|
|||
|
public delegate void EnableDisableEvent();
|
|||
|
|
|||
|
public class OnEnableDisableTracker : MonoBehaviour
|
|||
|
{
|
|||
|
public event EnableDisableEvent OnEnableEvent;
|
|||
|
public event EnableDisableEvent OnDisableEvent;
|
|||
|
|
|||
|
private void OnEnable() => OnEnableEvent?.Invoke();
|
|||
|
private void OnDisable() => OnDisableEvent?.Invoke();
|
|||
|
}
|
|||
|
}
|