public bool ChangeData(int nPower, int nSecs, int nTimes = 0, uint wCaster = 0) { try { m_nData = nPower; m_tKeep.SetInterval(nSecs); m_tKeep.Update(); m_dwCaster = wCaster; if (m_pOwner is Character) { // todo recalculate attributes } return(true); } catch { return(false); } }
public WangNianWuLing(PlayerObject _play, short x, short y, byte dir, uint _id, int nAi_Id) : base(_id, nAi_Id, x, y, false) { type = OBJECTTYPE.CALLOBJECT; typeid = IDManager.CreateTypeId(OBJECTTYPE.GUARDKNIGHT); SetPoint(x, y); mRebirthTime = 0;//不允许复活 mPlay = _play; SetDir(dir); mnRefreshTick = System.Environment.TickCount; mAddHP_Time = new TimeOut(); mAddHP_Time.SetInterval(2); }
public void SetBan(int nTime) { m_tBanTime.SetInterval(nTime); m_tBanTime.Update(); }