public override void AddHeartBeat(string strHeartBeatName, float fTime, NFIHeartBeat.HeartBeatEventHandler handler, NFIDataList valueList) { if (!mhtHeartBeat.ContainsKey(strHeartBeatName)) { NFIHeartBeat xHeartBeat = new NFCHeartBeat(mSelf, strHeartBeatName, fTime, valueList); mhtHeartBeat.Add(strHeartBeatName, xHeartBeat); xHeartBeat.RegisterCallback(handler); } }
public override void Update(float fPassTime) { NFIDataList xRemoveKeyList = new NFCDataList();; foreach (KeyValuePair <string, NFIHeartBeat> kv in mhtHeartBeat) { NFIHeartBeat xHeartBeat = (NFIHeartBeat)kv.Value; if (xHeartBeat.NeedRemove()) { xRemoveKeyList.AddString((string)kv.Key); } else { xHeartBeat.Update(fPassTime); } } for (int i = 0; i < xRemoveKeyList.Count(); i++) { mhtHeartBeat.Remove(xRemoveKeyList.StringVal(i)); } }
public abstract void RegisterCallback(NFIHeartBeat.HeartBeatEventHandler handler);
public override bool AddHeartBeat(NFGUID self, string strHeartBeatName, NFIHeartBeat.HeartBeatEventHandler handler, float fTime, int nCount) { NFIObject xGameObject = GetObject(self); if (null != xGameObject) { xGameObject.GetHeartBeatManager().AddHeartBeat(strHeartBeatName, fTime, nCount, handler); } return true; }
public abstract void AddHeartBeat(string strHeartBeatName, float fTime, int nCount, NFIHeartBeat.HeartBeatEventHandler handler);
public override void AddHeartBeat(string strHeartBeatName, float fTime, int nCount, NFIHeartBeat.HeartBeatEventHandler handler) { GetHeartBeatManager().AddHeartBeat(strHeartBeatName, fTime, nCount, handler); }
public override void RegisterCallback(NFIHeartBeat.HeartBeatEventHandler handler) { doHandlerDel += handler; }
public abstract void AddHeartBeat(string strHeartBeatName, float fTime, NFIHeartBeat.HeartBeatEventHandler handler, NFIDataList valueList);
public abstract bool AddHeartBeat(NFIDENTID self, string strHeartBeatName, NFIHeartBeat.HeartBeatEventHandler handler, float fTime, NFIDataList valueList);
public abstract bool AddHeartBeat(NFGUID self, string strHeartBeatName, NFIHeartBeat.HeartBeatEventHandler handler, float fTime, int nCount);