/// <summary> /// starts the event system /// </summary> protected virtual void SetupEvents() { for (int i = 0; i < Events.Count; i++) { Events[i].Receiver = InteractableEvent.CreateReceiver(Events[i]); Events[i].Receiver.Host = this; } }
/// <summary> /// set up only one event /// </summary> protected virtual void SetupEvents() { if (Events.Count > 0) { Events[0].Receiver = InteractableEvent.CreateReceiver(Events[0]); Events[0].Receiver.Host = this; } }