History

Merge branch 'master' into particleFix

Sam Gondelman committed 8 years ago

Commit 850e2d52 parents 223350b 4088035224 files · +15663 −3863Browse files

Showing the changes to libraries/entities/src/EntityScriptingInterface.cpp (1 of 224 files). Show all

Unified · Split

libraries/entities/src/EntityScriptingInterface.cpp+5−5
@@ -290,7 +290,7 @@ bool EntityScriptingInterface::addLocalEntityCopy(EntityItemProperties& properti · 289 unmodified lines
290 290
291 entity->setLastBroadcast(usecTimestampNow());291 entity->setLastBroadcast(usecTimestampNow());
292 // since we're creating this object we will immediately volunteer to own its simulation292 // since we're creating this object we will immediately volunteer to own its simulation
293 entity->flagForOwnershipBid(VOLUNTEER_SIMULATION_PRIORITY);293 entity->setScriptSimulationPriority(VOLUNTEER_SIMULATION_PRIORITY);
294 properties.setLastEdited(entity->getLastEdited());294 properties.setLastEdited(entity->getLastEdited());
295 } else {295 } else {
296 qCDebug(entities) << "script failed to add new Entity to local Octree";296 qCDebug(entities) << "script failed to add new Entity to local Octree";
@@ -494,7 +494,7 @@ QUuid EntityScriptingInterface::editEntity(QUuid id, const EntityItemProperties& · 197 unmodified lines
494 } else {494 } else {
495 // we make a bid for simulation ownership495 // we make a bid for simulation ownership
496 properties.setSimulationOwner(myNodeID, SCRIPT_POKE_SIMULATION_PRIORITY);496 properties.setSimulationOwner(myNodeID, SCRIPT_POKE_SIMULATION_PRIORITY);
497 entity->flagForOwnershipBid(SCRIPT_POKE_SIMULATION_PRIORITY);497 entity->setScriptSimulationPriority(SCRIPT_POKE_SIMULATION_PRIORITY);
498 }498 }
499 }499 }
500 if (properties.queryAACubeRelatedPropertyChanged()) {500 if (properties.queryAACubeRelatedPropertyChanged()) {
@@ -1363,7 +1363,7 @@ QUuid EntityScriptingInterface::addAction(const QString& actionTypeString, · 862 unmodified lines
1363 }1363 }
1364 action->setIsMine(true);1364 action->setIsMine(true);
1365 success = entity->addAction(simulation, action);1365 success = entity->addAction(simulation, action);
1366 entity->flagForOwnershipBid(SCRIPT_GRAB_SIMULATION_PRIORITY);1366 entity->setScriptSimulationPriority(SCRIPT_GRAB_SIMULATION_PRIORITY);
1367 return false; // Physics will cause a packet to be sent, so don't send from here.1367 return false; // Physics will cause a packet to be sent, so don't send from here.
1368 });1368 });
1369 if (success) {1369 if (success) {
@@ -1379,7 +1379,7 @@ bool EntityScriptingInterface::updateAction(const QUuid& entityID, const QUuid& · 9 unmodified lines
1379 return actionWorker(entityID, [&](EntitySimulationPointer simulation, EntityItemPointer entity) {1379 return actionWorker(entityID, [&](EntitySimulationPointer simulation, EntityItemPointer entity) {
1380 bool success = entity->updateAction(simulation, actionID, arguments);1380 bool success = entity->updateAction(simulation, actionID, arguments);
1381 if (success) {1381 if (success) {
1382 entity->flagForOwnershipBid(SCRIPT_GRAB_SIMULATION_PRIORITY);1382 entity->setScriptSimulationPriority(SCRIPT_GRAB_SIMULATION_PRIORITY);
1383 }1383 }
1384 return success;1384 return success;
1385 });1385 });
@@ -1393,7 +1393,7 @@ bool EntityScriptingInterface::deleteAction(const QUuid& entityID, const QUuid& · 7 unmodified lines
1393 success = entity->removeAction(simulation, actionID);1393 success = entity->removeAction(simulation, actionID);
1394 if (success) {1394 if (success) {
1395 // reduce from grab to poke1395 // reduce from grab to poke
1396 entity->flagForOwnershipBid(SCRIPT_POKE_SIMULATION_PRIORITY);1396 entity->setScriptSimulationPriority(SCRIPT_POKE_SIMULATION_PRIORITY);
1397 }1397 }
1398 return false; // Physics will cause a packet to be sent, so don't send from here.1398 return false; // Physics will cause a packet to be sent, so don't send from here.
1399 });1399 });

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t