示例#1
0
        private void DestroyBuffs()
        {
            int count = this._buffs.Count;

            for (int i = 0; i < count; i++)
            {
                Buff buff = this._buffs[i];
                if (!buff.markToDestroy)
                {
                    continue;
                }

                buff.OnDiscard();

                SyncEvent.DestroyBuff(buff.rid);

                this._buffs.RemoveAt(i);
                this._idToBuff.Remove(buff.rid);
                this._gPool.Push(buff);
                --i;
                --count;
            }
        }