mirror of
https://github.com/overte-org/overte.git
synced 2025-04-08 08:14:48 +02:00
removeOwnershipData() last minute before EntityMotionState delete
This commit is contained in:
parent
bfe809f3f7
commit
351f9991eb
1 changed files with 2 additions and 0 deletions
|
@ -460,6 +460,8 @@ void PhysicalEntitySimulation::buildPhysicsTransaction(PhysicsEngine::Transactio
|
|||
void PhysicalEntitySimulation::handleProcessedPhysicsTransaction(PhysicsEngine::Transaction& transaction) {
|
||||
// things on objectsToRemove are ready for delete
|
||||
for (auto object : transaction.objectsToRemove) {
|
||||
EntityMotionState* entityState = static_cast<EntityMotionState*>(object);
|
||||
removeOwnershipData(entityState);
|
||||
_physicalObjects.remove(object);
|
||||
delete object;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue