Final touchups to the lifecycle management
This commit is contained in:
@@ -43,8 +43,6 @@ namespace Core.SaveLoad
|
||||
public event Action<string> OnLoadCompleted;
|
||||
public event Action OnParticipantStatesRestored;
|
||||
|
||||
// ManagedBehaviour configuration
|
||||
public override int ManagedAwakePriority => 20; // After GameManager and SceneManagerService
|
||||
|
||||
internal override void OnManagedAwake()
|
||||
{
|
||||
@@ -95,10 +93,8 @@ namespace Core.SaveLoad
|
||||
|
||||
// ...existing code...
|
||||
|
||||
protected override void OnDestroy()
|
||||
internal override void OnManagedDestroy()
|
||||
{
|
||||
base.OnDestroy(); // Important: call base to unregister from LifecycleManager
|
||||
|
||||
if (_instance == this)
|
||||
{
|
||||
_instance = null;
|
||||
|
||||
Reference in New Issue
Block a user