From b92beca7d150ae4ff8bee4b12b1b460003061cb2 Mon Sep 17 00:00:00 2001 From: David Back Date: Wed, 2 Jan 2019 11:26:38 -0800 Subject: [PATCH] bad merge --- .../entities/src/EntityScriptingInterface.cpp | 15 --------------- libraries/entities/src/EntityScriptingInterface.h | 6 +++--- 2 files changed, 3 insertions(+), 18 deletions(-) diff --git a/libraries/entities/src/EntityScriptingInterface.cpp b/libraries/entities/src/EntityScriptingInterface.cpp index 314604a9da..709e7f4508 100644 --- a/libraries/entities/src/EntityScriptingInterface.cpp +++ b/libraries/entities/src/EntityScriptingInterface.cpp @@ -1089,9 +1089,6 @@ QUuid EntityScriptingInterface::findClosestEntity(const glm::vec3& center, float _entityTree->withReadLock([&] { result = _entityTree->evalClosestEntity(center, radius, PickFilter(searchFilter)); }); - if (closestEntity) { - result = closestEntity->getEntityItemID(); - } } return result; } @@ -1114,10 +1111,6 @@ QVector EntityScriptingInterface::findEntities(const glm::vec3& center, f _entityTree->withReadLock([&] { _entityTree->evalEntitiesInSphere(center, radius, PickFilter(searchFilter), result); }); - - foreach (EntityItemPointer entity, entities) { - result << entity->getEntityItemID(); - } } return result; } @@ -1132,10 +1125,6 @@ QVector EntityScriptingInterface::findEntitiesInBox(const glm::vec3& corn AABox box(corner, dimensions); _entityTree->evalEntitiesInBox(box, PickFilter(searchFilter), result); }); - - foreach (EntityItemPointer entity, entities) { - result << entity->getEntityItemID(); - } } return result; } @@ -1174,10 +1163,6 @@ QVector EntityScriptingInterface::findEntitiesInFrustum(QVariantMap frust _entityTree->withReadLock([&] { _entityTree->evalEntitiesInFrustum(viewFrustum, PickFilter(searchFilter), result); }); - - foreach(EntityItemPointer entity, entities) { - result << entity->getEntityItemID(); - } } } diff --git a/libraries/entities/src/EntityScriptingInterface.h b/libraries/entities/src/EntityScriptingInterface.h index 7b8378f6ce..1f09198f0f 100644 --- a/libraries/entities/src/EntityScriptingInterface.h +++ b/libraries/entities/src/EntityScriptingInterface.h @@ -427,7 +427,7 @@ public slots: * @function Entities.findEntitiesInBox * @param {Vec3} corner - The corner of the search AA box with minimum co-ordinate values. * @param {Vec3} dimensions - The dimensions of the search AA box. - * @returns {Uuid[]} An array of entity IDs whose AA boxes intersect the search AA box. The array is empty if no entities + * @returns {Uuid[]} An array of entity IDs whose AA boxes intersect the search AA box. The array is empty if no entities * could be found. */ /// this function will not find any models in script engine contexts which don't have access to models @@ -438,7 +438,7 @@ public slots: * @function Entities.findEntitiesInFrustum * @param {ViewFrustum} frustum - The frustum to search in. The position, orientation, * projection, and centerRadius properties must be specified. - * @returns {Uuid[]} An array of entity IDs axis-aligned boxes intersect the frustum. The array is empty if no entities + * @returns {Uuid[]} An array of entity IDs axis-aligned boxes intersect the frustum. The array is empty if no entities * could be found. * @example Report the number of entities in view. * var entityIDs = Entities.findEntitiesInFrustum(Camera.frustum); @@ -453,7 +453,7 @@ public slots: * @param {Entities.EntityType} entityType - The type of entity to search for. * @param {Vec3} center - The point about which to search. * @param {number} radius - The radius within which to search. - * @returns {Uuid[]} An array of entity IDs of the specified type that intersect the search sphere. The array is empty if + * @returns {Uuid[]} An array of entity IDs of the specified type that intersect the search sphere. The array is empty if * no entities could be found. * @example Report the number of Model entities within 10m of your avatar. * var entityIDs = Entities.findEntitiesByType("Model", MyAvatar.position, 10);