refactor: switched from universe objects to behaviours on all managers like update, draw & physics etc.
This commit is contained in:
@@ -3,7 +3,7 @@ using System.Collections.Generic;
|
||||
|
||||
namespace Syntriax.Engine.Core;
|
||||
|
||||
public class CoroutineManager : UniverseObject
|
||||
public class CoroutineManager : Behaviour
|
||||
{
|
||||
private readonly List<IEnumerator> enumerators = [];
|
||||
|
||||
@@ -18,12 +18,12 @@ public class CoroutineManager : UniverseObject
|
||||
enumerators.Remove(enumerator);
|
||||
}
|
||||
|
||||
protected override void OnEnteringUniverse(IUniverse universe)
|
||||
protected override void OnEnteredUniverse(IUniverse universe)
|
||||
{
|
||||
universe.OnUpdate.AddListener(OnUpdate);
|
||||
}
|
||||
|
||||
protected override void OnExitingUniverse(IUniverse universe)
|
||||
protected override void OnExitedUniverse(IUniverse universe)
|
||||
{
|
||||
universe.OnUpdate.RemoveListener(OnUpdate);
|
||||
}
|
||||
|
Reference in New Issue
Block a user