public void InnerHandle_InBat_PreConfigMsg(COM_INBATTLE_CHAT_TYPE chatType, uint herocfgID, uint cfg_id, ulong ullUid) { ResInBatMsgHeroActCfg heroActCfg = Singleton <InBattleMsgMgr> .instance.GetHeroActCfg(herocfgID, cfg_id); ResInBatMsgCfg cfgData = Singleton <InBattleMsgMgr> .instance.GetCfgData(cfg_id); if (cfgData != null) { if (heroActCfg != null) { InBattleMsgUT.ShowInBattleMsg(chatType, ullUid, herocfgID, heroActCfg.szContent, heroActCfg.szSound, true); } else { InBattleMsgUT.ShowInBattleMsg(chatType, ullUid, herocfgID, cfgData.szContent, cfgData.szSound, false); } if ((chatType == COM_INBATTLE_CHAT_TYPE.COM_INBATTLE_CHATTYPE_SIGNAL) && (Singleton <CBattleSystem> .instance.TheMinimapSys.CurMapType() == MinimapSys.EMapType.Mini)) { ReadonlyContext <PoolObjHandle <ActorRoot> > allHeroes = Singleton <GamePlayerCenter> .instance.GetPlayerByUid(ullUid).GetAllHeroes(); for (int i = 0; i < allHeroes.Count; i++) { PoolObjHandle <ActorRoot> handle = allHeroes[i]; ActorRoot root = handle.handle; if ((root != null) && (root.TheActorMeta.ConfigId == herocfgID)) { Vector2 sreenLoc = CUIUtility.WorldToScreenPoint(this.m_battleForm.GetCamera(), root.HudControl.GetSmallMapPointer_WorldPosition()); Singleton <CUIParticleSystem> .instance.AddParticle(cfgData.szMiniMapEffect, 2f, sreenLoc); return; } } } } }
public void InnerHandle_InBat_PreConfigMsg(COM_INBATTLE_CHAT_TYPE chatType, uint herocfgID, uint cfg_id, ulong ullUid) { ResInBatMsgHeroActCfg heroActCfg = Singleton <InBattleMsgMgr> .get_instance().GetHeroActCfg(herocfgID, cfg_id); ResInBatMsgCfg cfgData = Singleton <InBattleMsgMgr> .get_instance().GetCfgData(cfg_id); if (cfgData == null) { return; } if (heroActCfg != null) { InBattleMsgUT.ShowInBattleMsg(chatType, ullUid, herocfgID, heroActCfg.szContent, heroActCfg.szSound); } else { InBattleMsgUT.ShowInBattleMsg(chatType, ullUid, herocfgID, cfgData.szContent, cfgData.szSound); } if (chatType == 1 && Singleton <CBattleSystem> .get_instance().TheMinimapSys.CurMapType() == MinimapSys.EMapType.Mini) { Player playerByUid = Singleton <GamePlayerCenter> .get_instance().GetPlayerByUid(ullUid); ReadonlyContext <PoolObjHandle <ActorRoot> > allHeroes = playerByUid.GetAllHeroes(); for (int i = 0; i < allHeroes.get_Count(); i++) { ActorRoot handle = allHeroes.get_Item(i).get_handle(); if (handle != null && (long)handle.TheActorMeta.ConfigId == (long)((ulong)herocfgID)) { Camera currentCamera = Singleton <Camera_UI3D> .GetInstance().GetCurrentCamera(); if (currentCamera != null) { Vector2 sreenLoc = currentCamera.WorldToScreenPoint(handle.HudControl.GetSmallMapPointer_WorldPosition()); Singleton <CUIParticleSystem> .get_instance().AddParticle(cfgData.szMiniMapEffect, 2f, sreenLoc); } } } } }