History

Merge pull request #9851 from AndrewMeadows/simulation-ownership-2

zero velocity of deactivated dynamic entities

Brad Hefta-Gaub committed 9 years ago

Commit bc5d7d82 parents ccce4b4 bde222212 files · +77 −28Browse files

Showing the changes to interface/src/Application.cpp (1 of 12 files). Show all

Unified · Split

interface/src/Application.cpp+6−3
@@ -4438,9 +4438,12 @@ void Application::update(float deltaTime) { · 4437 unmodified lines
44384438
44394439 getEntities()->getTree()->withWriteLock([&] {
44404440 PerformanceTimer perfTimer("handleOutgoingChanges");
4441− const VectorOfMotionStates& outgoingChanges = _physicsEngine->getOutgoingChanges();
4442− _entitySimulation->handleOutgoingChanges(outgoingChanges);
4443− avatarManager->handleOutgoingChanges(outgoingChanges);
4441+ const VectorOfMotionStates& deactivations = _physicsEngine->getDeactivatedMotionStates();
4442+ _entitySimulation->handleDeactivatedMotionStates(deactivations);
4443+
4444+ const VectorOfMotionStates& outgoingChanges = _physicsEngine->getChangedMotionStates();
4445+ _entitySimulation->handleChangedMotionStates(outgoingChanges);
4446+ avatarManager->handleChangedMotionStates(outgoingChanges);
44444447 });
44454448
44464449 if (!_aboutToQuit) {