public void SkipCurMessageHandlers(string endMsg, string storyId, string _namespace) { if (!string.IsNullOrEmpty(_namespace)) { storyId = string.Format("{0}:{1}", _namespace, storyId); } int count = m_StoryLogicInfos.Count; for (int index = count - 1; index >= 0; --index) { StoryInstance info = m_StoryLogicInfos[index]; if (IsMatch(info.StoryId, storyId)) { info.ClearMessage(); var enumer = info.GetMessageHandlerEnumerator(); while (enumer.MoveNext()) { var handler = enumer.Current; if (handler.IsTriggered && handler.MessageId != endMsg) { handler.CanSkip = true; } } var cenumer = info.GetConcurrentMessageHandlerEnumerator(); while (cenumer.MoveNext()) { var handler = cenumer.Current; if (handler.IsTriggered && handler.MessageId != endMsg) { handler.CanSkip = true; } } } } }
protected override bool ExecCommand(StoryInstance instance, long delta) { string[] arglist = new string[m_MsgIds.Count]; for (int i = 0; i < m_MsgIds.Count; i++) { arglist[i] = m_MsgIds[i].Value; } instance.ClearMessage(arglist); return false; }
protected override bool ExecCommand(StoryInstance instance, long delta) { string[] arglist = new string[m_MsgIds.Count]; for (int i = 0; i < m_MsgIds.Count; i++) { arglist[i] = m_MsgIds[i].Value; } instance.ClearMessage(arglist); return(false); }
protected override bool ExecCommand(StoryInstance instance, long delta) { string[] arglist = new string[m_MsgIds.Count]; string _namespace = instance.Namespace; if (string.IsNullOrEmpty(_namespace)) { for (int i = 0; i < m_MsgIds.Count; i++) { arglist[i] = m_MsgIds[i].Value; } } else { for (int i = 0; i < m_MsgIds.Count; i++) { arglist[i] = string.Format("{0}:{1}", _namespace, m_MsgIds[i].Value); } } instance.ClearMessage(arglist); return(false); }
protected override bool ExecCommand(StoryInstance instance, long delta) { string[] arglist = new string[m_MsgIds.Count]; string _namespace = instance.Namespace; if (string.IsNullOrEmpty(_namespace)) { for (int i = 0; i < m_MsgIds.Count; i++) { arglist[i] = m_MsgIds[i].Value; } } else { for (int i = 0; i < m_MsgIds.Count; i++) { arglist[i] = string.Format("{0}:{1}", _namespace, m_MsgIds[i].Value); } } instance.ClearMessage(arglist); return false; }