/// <summary> /// 技能释放(瞬发, 引导或引导更新) /// </summary> private void OnRecvSpellCasting(MessageReceivedEvent e) { S2C_SpellCasting ret = MarshalConversion.PtrToStruct <S2C_SpellCasting>(e.MessagePtr); if (ret.CasterId == GameEngine.EngineInstance.LocalPlayer.CharacterID) { GameEngine.EngineInstance.LocalPlayer.OnSpellCasting(ret); if (currentProgressBarTimeStamp <= ret.TimeStamp) { prepareProgressBar.Hide(); } } else { RemoteCharacterController rcc = GameEngine.EngineInstance.FindCharacterController(ret.CasterId); if (rcc != null) { rcc.OnSpellCasting(ret); } else { NLogger.Instance.WriteString(LogType.Warning, string.Format("S2C_SpellCasting can not find controller UintID=[{0}]", ret.CasterId)); } } }
internal virtual void OnSpellCasting(S2C_SpellCasting ret) { // 更新当前SM状态 Type sepllSMType = typeof(SpecialMove_SpellCasting); if (!IsDoingSepcialMove(sepllSMType)) { DoSpecialMoveByType(sepllSMType, false); } SpecialMove_SpellCasting spellSM = SpecialMove as SpecialMove_SpellCasting; if (spellSM != null) { spellSM.CastingData = ret; } }