Created
January 2, 2018 08:25
-
-
Save raveneer/1f7cb52ebc0c51e321bad5087749373b to your computer and use it in GitHub Desktop.
simple gist test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Entitas; | |
using UnityEngine; | |
using Zenject; | |
public class DummyGameController : MonoBehaviour | |
{ | |
Systems _systems; | |
[Inject] private Contexts _contexts; | |
[Inject] private DummySystem _dummySystem; | |
void Start() | |
{ | |
// get a reference to the contexts | |
Debug.Assert(_contexts != null); | |
// create the systems by creating individual features | |
_systems = new Feature("DummySystems").Add(_dummySystem); | |
// call Initialize() on all of the IInitializeSystems | |
_systems.Initialize(); | |
} | |
void Update() | |
{ | |
// call Execute() on all the IExecuteSystems and | |
// ReactiveSystems that were triggered last frame | |
//_systems.Execute(); | |
// call cleanup() on all the ICleanupSystems | |
//_systems.Cleanup(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment