Some small fixes
This commit is contained in:
parent
f964d7bf85
commit
3719cdaee0
2 changed files with 3 additions and 1 deletions
|
|
@ -56,6 +56,7 @@ struct IDManager
|
|||
*/
|
||||
void releaseID(EntityID id) nothrow @nogc
|
||||
{
|
||||
optimize();
|
||||
Data* data = &m_ids_array[id.id];
|
||||
if (data.counter != id.counter)
|
||||
return;
|
||||
|
|
|
|||
|
|
@ -2923,6 +2923,7 @@ export struct EntityManager
|
|||
|
||||
private void updateBlock(EntitiesBlock* block) @nogc nothrow
|
||||
{
|
||||
if(block.added_count == 0)return;
|
||||
EntityInfo* info = block.type_info;
|
||||
ushort entities_count = block.entities_count;
|
||||
block.entities_count += block.added_count;
|
||||
|
|
@ -3056,7 +3057,7 @@ export struct EntityManager
|
|||
has_work = false;
|
||||
has_work |= updateEvents();
|
||||
|
||||
id_manager.optimize();
|
||||
//id_manager.optimize();
|
||||
has_work |= updateBlocks();
|
||||
has_work |= changeEntities();
|
||||
has_work |= removeEntities();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue