mirror of
https://github.com/overte-org/overte.git
synced 2025-04-22 05:04:14 +02:00
attempting to fix windows and linux builds again
This commit is contained in:
parent
e36099f2b6
commit
9125b3a2a9
2 changed files with 0 additions and 51 deletions
libraries/entities/src
|
@ -488,42 +488,6 @@ bool EntityScriptingInterface::setPoints(QUuid entityID, std::function<bool(Line
|
|||
return success;
|
||||
}
|
||||
|
||||
bool EntityScriptingInterface::setPoints(QUuid entityID, std::function<bool(PolyLineEntityItem&)> actor) {
|
||||
if (!_entityTree) {
|
||||
return false;
|
||||
}
|
||||
|
||||
EntityItemPointer entity = static_cast<EntityItemPointer>(_entityTree->findEntityByEntityItemID(entityID));
|
||||
if (!entity) {
|
||||
qCDebug(entities) << "EntityScriptingInterface::setPoints no entity with ID" << entityID;
|
||||
}
|
||||
|
||||
EntityTypes::EntityType entityType = entity->getType();
|
||||
|
||||
if (entityType != EntityTypes::PolyLine) {
|
||||
return false;
|
||||
}
|
||||
|
||||
auto now = usecTimestampNow();
|
||||
|
||||
auto polyLineEntity = std::static_pointer_cast<PolyLineEntityItem>(entity);
|
||||
_entityTree->lockForWrite();
|
||||
bool success = actor(*polyLineEntity);
|
||||
entity->setLastEdited(now);
|
||||
entity->setLastBroadcast(now);
|
||||
_entityTree->unlock();
|
||||
|
||||
_entityTree->lockForRead();
|
||||
EntityItemProperties properties = entity->getProperties();
|
||||
_entityTree->unlock();
|
||||
|
||||
properties.setLinePointsDirty();
|
||||
properties.setLastEdited(now);
|
||||
|
||||
|
||||
queueEntityMessage(PacketType::EntityEdit, entityID, properties);
|
||||
return success;
|
||||
}
|
||||
|
||||
bool EntityScriptingInterface::setVoxelSphere(QUuid entityID, const glm::vec3& center, float radius, int value) {
|
||||
return setVoxels(entityID, [center, radius, value](PolyVoxEntityItem& polyVoxEntity) {
|
||||
|
@ -558,13 +522,6 @@ bool EntityScriptingInterface::setAllPoints(QUuid entityID, const QVector<glm::v
|
|||
});
|
||||
}
|
||||
|
||||
if (entityType == EntityTypes::PolyLine) {
|
||||
return setPoints(entityID, [points](PolyLineEntityItem& polyLineEntity) -> bool
|
||||
{
|
||||
return (PolyLineEntityItem*)polyLineEntity.setLinePoints(points);
|
||||
});
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -583,13 +540,6 @@ bool EntityScriptingInterface::appendPoint(QUuid entityID, const glm::vec3& poin
|
|||
});
|
||||
}
|
||||
|
||||
if (entityType == EntityTypes::PolyLine) {
|
||||
return setPoints(entityID, [point](PolyLineEntityItem& PolyLineEntity) -> bool
|
||||
{
|
||||
return (PolyLineEntityItem*)PolyLineEntity.appendPoint(point);
|
||||
});
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
@ -165,7 +165,6 @@ private:
|
|||
bool actionWorker(const QUuid& entityID, std::function<bool(EntitySimulation*, EntityItemPointer)> actor);
|
||||
bool setVoxels(QUuid entityID, std::function<void(PolyVoxEntityItem&)> actor);
|
||||
bool setPoints(QUuid entityID, std::function<bool(LineEntityItem&)> actor);
|
||||
bool setPoints(QUuid entityID, std::function<bool(PolyLineEntityItem&)> actor);
|
||||
void queueEntityMessage(PacketType::Value packetType, EntityItemID entityID, const EntityItemProperties& properties);
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue