History

don't always send actiondata along with other physics related properties

Seth Alves committed 11 years ago

Commit 7979fb31 parent dbaea572 files · +4 −3Browse files

Unified · Split

2 files
  1. libraries/entities/src/EntityTree.cpp +0 −1
  2. libraries/physics/src/EntityMotionState.cpp +4 −2
libraries/entities/src/EntityTree.cpp+0−1
@@ -198,7 +198,6 @@ bool EntityTree::updateEntityWithElement(EntityItemPointer entity, const EntityI · 197 unmodified lines
198 properties.setVelocityChanged(false);198 properties.setVelocityChanged(false);
199 properties.setAngularVelocityChanged(false);199 properties.setAngularVelocityChanged(false);
200 properties.setAccelerationChanged(false);200 properties.setAccelerationChanged(false);
201 properties.setActionDataChanged(false);
202 201
203 if (wantTerseEditLogging()) {202 if (wantTerseEditLogging()) {
204 qCDebug(entities) << senderNode->getUUID() << "physical edits suppressed";203 qCDebug(entities) << senderNode->getUUID() << "physical edits suppressed";
libraries/physics/src/EntityMotionState.cpp+4−2
@@ -294,7 +294,6 @@ bool EntityMotionState::remoteSimulationOutOfSync(uint32_t simulationStep) { · 293 unmodified lines
294 294
295 if (_entity->actionDataNeedsTransmit()) {295 if (_entity->actionDataNeedsTransmit()) {
296 setOutgoingPriority(SCRIPT_EDIT_SIMULATION_PRIORITY);296 setOutgoingPriority(SCRIPT_EDIT_SIMULATION_PRIORITY);
297 _entity->setActionDataNeedsTransmit(false);
298 return true;297 return true;
299 }298 }
300 299
@@ -457,7 +456,10 @@ void EntityMotionState::sendUpdate(OctreeEditPacketSender* packetSender, const Q · 156 unmodified lines
457 properties.setVelocity(_serverVelocity);456 properties.setVelocity(_serverVelocity);
458 properties.setAcceleration(_serverAcceleration);457 properties.setAcceleration(_serverAcceleration);
459 properties.setAngularVelocity(_serverAngularVelocity);458 properties.setAngularVelocity(_serverAngularVelocity);
460 properties.setActionData(_serverActionData);459 if (_entity->actionDataNeedsTransmit()) {
460 _entity->setActionDataNeedsTransmit(false);
461 properties.setActionData(_serverActionData);
462 }
461 463
462 // set the LastEdited of the properties but NOT the entity itself464 // set the LastEdited of the properties but NOT the entity itself
463 quint64 now = usecTimestampNow();465 quint64 now = usecTimestampNow();