Exemplo n.º 1
0
        private void DestroyUnits()
        {
            for (int i = 0; i < _entityToDestroyBuffer.Count; i++)
            {
                var entityId = _entityToDestroyBuffer[i];

                if (_entityPool.ContainsId(entityId))
                {
                    _entityPool.GetById(entityId).Destroy();
                }
            }

            _entityToDestroyBuffer.Clear();
        }