public Timer(Action callback, float seconds, bool pausable = false) { Callback = callback; ExecuteTime = seconds; Pausable = pausable; TimePassed = 0; Completed = false; EventDispatcher = new EventDispatcher(AbstractGameManager.Instance.EventDispatcher); EventDispatcher.AddHandler<GameUpdateEvent>(StateEventType.GameUpdate, OnGameUpdate); }
public EventDispatcher(EventDispatcher parent = null) : base(parent) { Parent = parent; LastEventIndex = 0; }
protected AbstractGameComponent() { EventDispatcher = new EventDispatcher(Manager.EventDispatcher); Enabled = true; }