internal override void DestroyObject(MonocleObject toDestroy) { lock (_lock) { if (toDestroy.InstanceID == -1) return; toDestroy.DestroySelf(); long id = toDestroy.InstanceID; toDestroy.InstanceID = -1; if (id == NextID - 1) { NextID = id; return; } this.avalibleIDs.Add(id); } }
internal override void DestroyObject(MonocleObject toDestroy) { lock (_lock) { if (toDestroy.InstanceID == -1) { return; } toDestroy.DestroySelf(); long id = toDestroy.InstanceID; toDestroy.InstanceID = -1; if (id == NextID - 1) { NextID = id; return; } this.avalibleIDs.Add(id); } }