public void UpdateEvent() { if (currentEvent == null) { if (eventQueue.Count > 0) { currentEvent = eventQueue.Dequeue(); currentEvent.ResetEvent(); } else { Goodbye(); } } if (currentEvent != null) { if (!currentEvent.IsEventComplete()) { currentEvent.UpdateEvent(); } else { currentEvent = null; } } }
private void questionSelected(TopicQuestion question) { if (question.trigger == null) { chatMessage.Discard(); } else { chatMessage = null; if (question.trigger.Equals(string.Empty)) { Topic topic = NeverdawnDatabase.GetTopic(question.topicId); selectedEvent = topic.defaultEvent; } else { selectedEvent = EventController.FindEvent(question.trigger); } selectedEvent.ResetEvent(); } }