private void Awake() { foreach (StoryEventContainer PstoryEvent in _storyEvents) { if (PstoryEvent._storyEventTriggerType == TriggerType.Awake) { if (PstoryEvent.CanExecuteStoryEvent()) { StoryEventManager.QueStoryEvents(PstoryEvent._storyEventsToPlay, PstoryEvent._eventName); } } } }
private void OnTriggerExit(Collider other) { foreach (StoryEventContainer PstoryEvent in _storyEvents) { if (PstoryEvent._storyEventTriggerType == TriggerType.TriggerExit) { if (PstoryEvent.CanExecuteStoryEvent(other.gameObject)) { StoryEventManager.QueStoryEvents(PstoryEvent._storyEventsToPlay, PstoryEvent._eventName); return; } } } }
public void OnItemInteract(PlayerController owningPlayer) { Debug.Log("interact"); foreach (StoryEventContainer PstoryEvent in _storyEvents) { if (PstoryEvent._storyEventTriggerType == TriggerType.Interact) { if (PstoryEvent.CanExecuteStoryEvent()) { StoryEventManager.QueStoryEvents(PstoryEvent._storyEventsToPlay, PstoryEvent._eventName); return; } } } }