| | |
| | | public static event OnObjAddBuff Even_ObjAddBuf;//关于Buff的增加
|
| | | public delegate void OnObjDelBuff();
|
| | | public static event OnObjDelBuff Even_ObjDelBuff;//关于Buff的减少
|
| | | public static event Action<int> BuffUpdateEvent;//buff状态改变
|
| | | public Dictionary<int, ObjBuff> _BuffDic = new Dictionary<int, ObjBuff>();//buff字典
|
| | | VipModel m_VipModel;
|
| | | VipModel vipModel { get { return m_VipModel ?? (m_VipModel = ModelCenter.Instance.GetModel<VipModel>()); } }
|
| | |
| | | _ObjBuff.Layer = (int)info.Layer;
|
| | | _BuffDic.Add((int)info.SkillID, _ObjBuff);
|
| | | }
|
| | | if (BuffUpdateEvent != null)
|
| | | {
|
| | | BuffUpdateEvent((int)info.ObjID);
|
| | | }
|
| | | if (Even_ObjAddBuf != null)
|
| | | Even_ObjAddBuf();
|
| | | }
|
| | |
| | | {
|
| | | return;
|
| | | }
|
| | | if (BuffUpdateEvent != null)
|
| | | {
|
| | | BuffUpdateEvent(playerId);
|
| | | }
|
| | | if (_BuffDic.ContainsKey(_BuffID))
|
| | | {
|
| | | _BuffDic.Remove(_BuffID);
|