public UnityMessageHandler() { if (_instance != null) { throw new Exception("Only one instance of UnityMessageHandler is allowed. Dispose the existing instance before creating a new one."); } _instance = this; }
public void Dispose() => _instance = null;