Bug and crash fixes
* Fixes end portals' solidity * Fixed crashes to do with multithreading and removing an entity from the wrong world * Fixed crashes due to bad merge * Fixed crashes due to an object being deleted twice * Simplified cWorld::Start() and added comments to configuration files
This commit is contained in:
@@ -591,7 +591,6 @@ void cChunk::Tick(float a_Dt)
|
||||
if (!((*itr)->IsMob()))
|
||||
{
|
||||
(*itr)->Tick(a_Dt, *this);
|
||||
continue;
|
||||
}
|
||||
} // for itr - m_Entitites[]
|
||||
|
||||
@@ -605,10 +604,10 @@ void cChunk::Tick(float a_Dt)
|
||||
itr = m_Entities.erase(itr);
|
||||
delete ToDelete;
|
||||
}
|
||||
else if ((*itr)->IsTravellingThroughPortal()) // Remove all entities that are travelling to another world
|
||||
else if ((*itr)->IsWorldTravellingFrom(m_World)) // Remove all entities that are travelling to another world
|
||||
{
|
||||
MarkDirty();
|
||||
(*itr)->SetIsTravellingThroughPortal(false);
|
||||
(*itr)->SetWorldTravellingFrom(NULL);
|
||||
itr = m_Entities.erase(itr);
|
||||
}
|
||||
else if ( // If any entity moved out of the chunk, move it to the neighbor:
|
||||
|
||||
Reference in New Issue
Block a user