//全局事件处理 public void GlobalEventHandler(int eventid, object data) { switch (eventid) { case (int)Client.GameEventID.UIEVENTPlayDISPLAYEFFECT: { EffectDisplayManager.EffectDisplayData displayData = data as EffectDisplayManager.EffectDisplayData; PlayDisplayEffect(displayData); } break; } }
/// <summary> /// 播放展示效果 /// </summary> /// <param name="displayData"></param> private void PlayDisplayEffect(EffectDisplayManager.EffectDisplayData displayData) { switch (displayData.DisPlayType) { case EffectDisplayManager.EffectDisplayData.EffectDisplayType.Disp_MapName: { PlayMapDisplayEffect((string)displayData.Data); } break; case EffectDisplayManager.EffectDisplayData.EffectDisplayType.Disp_Partical: { PlayParticalDisplayEffect((uint)displayData.Data); } break; case EffectDisplayManager.EffectDisplayData.EffectDisplayType.Disp_Tips: { PlayTipsDisplayEffect((string)displayData.Data); } break; } }