From 4c8f281383e1ae317ee1007a79c091fc63c47ba9 Mon Sep 17 00:00:00 2001 From: David Rowe Date: Sat, 22 Jun 2019 14:16:17 +1200 Subject: [PATCH] Typos etc. --- .../entities/src/EntityDynamicInterface.cpp | 3 +- .../entities/src/EntityItemProperties.cpp | 52 +++++++++---------- .../entities/src/EntityScriptingInterface.h | 33 +++++++----- libraries/physics/src/ObjectDynamic.cpp | 2 +- 4 files changed, 48 insertions(+), 42 deletions(-) diff --git a/libraries/entities/src/EntityDynamicInterface.cpp b/libraries/entities/src/EntityDynamicInterface.cpp index 84ceefa6b9..4586b665ee 100644 --- a/libraries/entities/src/EntityDynamicInterface.cpp +++ b/libraries/entities/src/EntityDynamicInterface.cpp @@ -130,7 +130,8 @@ variables. These argument variables are used by the code which is run when bull * "ball-socket"Object constraint * Connects two entities with a ball and socket joint. * {@link Entities.ActionArguments-BallSocket} - * "spring"Synonym for "tractor". Legacy value. + * "spring"Synonym for "tractor". + * Deprecated. * * * @typedef {string} Entities.ActionType diff --git a/libraries/entities/src/EntityItemProperties.cpp b/libraries/entities/src/EntityItemProperties.cpp index a2e1d5560a..5b3bbb88ee 100644 --- a/libraries/entities/src/EntityItemProperties.cpp +++ b/libraries/entities/src/EntityItemProperties.cpp @@ -656,10 +656,10 @@ EntityPropertyFlags EntityItemProperties::getChangedProperties() const { * @property {Entities.RenderLayer} renderLayer="world" - Which layer the entity renders in. * @property {Entities.PrimitiveMode} primitiveMode="solid" - How the entity's geometry is rendered. * @property {boolean} ignorePickIntersection=false - true if {@link Picks} and {@link RayPick} ignore the entity, - * false if they don't ignore it. + * false if they don't. * - * @property {Vec3} position=0,0,0 - The position of the entity. - * @property {Quat} rotation=0,0,0,1 - The orientation of the entity with respect to world coordinates. + * @property {Vec3} position=0,0,0 - The position of the entity in world coordinates. + * @property {Quat} rotation=0,0,0,1 - The orientation of the entity in world coordinates. * @property {Vec3} registrationPoint=0.5,0.5,0.5 - The point in the entity that is set to the entity's position and is rotated * about, range {@link Vec3(0)|Vec3.ZERO} – {@link Vec3(0)|Vec3.ONE}. A value of {@link Vec3(0)|Vec3.ZERO} is the * entity's minimum x, y, z corner; a value of {@link Vec3(0)|Vec3.ONE} is the entity's maximum x, y, z corner. @@ -670,13 +670,13 @@ EntityPropertyFlags EntityItemProperties::getChangedProperties() const { * {@link Vec3(0)|Vec3.ONE}. Read-only. * * @property {Vec3} velocity=0,0,0 - The linear velocity of the entity in m/s with respect to world coordinates. - * @property {number} damping=0.39347 - How much to slow down the linear velocity of an entity over time, range + * @property {number} damping=0.39347 - How much the linear velocity of an entity slows down over time, range * 0.01.0. A higher damping value slows down the entity more quickly. The default value * is for an exponential decay timescale of 2.0s, where it takes 2.0s for the movement to slow to 1/e = 0.368 * of its initial value. * @property {Vec3} angularVelocity=0,0,0 - The angular velocity of the entity in rad/s with respect to its axes, about its * registration point. - * @property {number} angularDamping=0.39347 - How much to slow down the angular velocity of an entity over time, range + * @property {number} angularDamping=0.39347 - How much the angular velocity of an entity slows down over time, range * 0.01.0. A higher damping value slows down the entity more quickly. The default value * is for an exponential decay timescale of 2.0s, where it takes 2.0s for the movement to slow to 1/e = 0.368 * of its initial value. @@ -694,7 +694,7 @@ EntityPropertyFlags EntityItemProperties::getChangedProperties() const { * velocity in order to kick off physics simulation.

* @property {number} restitution=0.5 - The "bounciness" of an entity when it collides, range 0.0 – * 0.99. The higher the value, the more bouncy. - * @property {number} friction=0.5 - How much to slow down an entity when it's moving against another, range 0.0 + * @property {number} friction=0.5 - How much an entity slows down when it's moving against another, range 0.0 * – 10.0. The higher the value, the more quickly it slows down. Examples: 0.1 for ice, * 0.9 for sandpaper. * @property {number} density=1000 - The density of the entity in kg/m3, range 100 for balsa wood @@ -744,7 +744,7 @@ EntityPropertyFlags EntityItemProperties::getChangedProperties() const { * @property {Vec3} localVelocity=0,0,0 - The velocity of the entity relative to its parent if the entity is parented, * otherwise the same value as velocity. * @property {Vec3} localAngularVelocity=0,0,0 - The angular velocity of the entity relative to its parent if the entity is - * parented, otherwise the same value as position. + * parented, otherwise the same value as angularVelocity. * @property {Vec3} localDimensions - The dimensions of the entity. If the entity is parented to an avatar and is an * avatar entity so that it scales with the avatar, this value remains the original dimensions value while the * avatar scale changes. @@ -1197,24 +1197,24 @@ EntityPropertyFlags EntityItemProperties::getChangedProperties() const { * rejected. * @property {Entities.PolyVoxSurfaceStyle} voxelSurfaceStyle=2 - The style of rendering the voxels' surface and how * neighboring PolyVox entities are joined. - * @property {string} xTextureURL="" - URL of the texture to map to surfaces perpendicular to the entity's local x-axis. JPG or - * PNG format. If no texture is specified the surfaces display white. - * @property {string} yTextureURL="" - URL of the texture to map to surfaces perpendicular to the entity's local y-axis. JPG or - * PNG format. If no texture is specified the surfaces display white. - * @property {string} zTextureURL="" - URL of the texture to map to surfaces perpendicular to the entity's local z-axis. JPG or - * PNG format. If no texture is specified the surfaces display white. - * @property {Uuid} xNNeighborID=Uuid.NULL - ID of the neighboring PolyVox entity in the entity's -ve local x-axis direction, - * if you want them joined. Set to {@link Uuid(0)|Uuid.NULL} if there is none or you don't want to join them. - * @property {Uuid} yNNeighborID=Uuid.NULL - ID of the neighboring PolyVox entity in the entity's -ve local y-axis direction, - * if you want them joined. Set to {@link Uuid(0)|Uuid.NULL} if there is none or you don't want to join them. - * @property {Uuid} zNNeighborID=Uuid.NULL - ID of the neighboring PolyVox entity in the entity's -ve local z-axis direction, - * if you want them joined. Set to {@link Uuid(0)|Uuid.NULL} if there is none or you don't want to join them. - * @property {Uuid} xPNeighborID=Uuid.NULL - ID of the neighboring PolyVox entity in the entity's +ve local x-axis direction, - * if you want them joined. Set to {@link Uuid(0)|Uuid.NULL} if there is none or you don't want to join them. - * @property {Uuid} yPNeighborID=Uuid.NULL - ID of the neighboring PolyVox entity in the entity's +ve local y-axis direction, - * if you want them joined. Set to {@link Uuid(0)|Uuid.NULL} if there is none or you don't want to join them. - * @property {Uuid} zPNeighborID=Uuid.NULL - ID of the neighboring PolyVox entity in the entity's +ve local z-axis direction, - * if you want them joined. Set to {@link Uuid(0)|Uuid.NULL} if there is none or you don't want to join them. + * @property {string} xTextureURL="" - The URL of the texture to map to surfaces perpendicular to the entity's local x-axis. + * JPG or PNG format. If no texture is specified the surfaces display white. + * @property {string} yTextureURL="" - The URL of the texture to map to surfaces perpendicular to the entity's local y-axis. + * JPG or PNG format. If no texture is specified the surfaces display white. + * @property {string} zTextureURL="" - The URL of the texture to map to surfaces perpendicular to the entity's local z-axis. + * JPG or PNG format. If no texture is specified the surfaces display white. + * @property {Uuid} xNNeighborID=Uuid.NULL - The ID of the neighboring PolyVox entity in the entity's -ve local x-axis + * direction, if you want them joined. Set to {@link Uuid(0)|Uuid.NULL} if there is none or you don't want to join them. + * @property {Uuid} yNNeighborID=Uuid.NULL - The ID of the neighboring PolyVox entity in the entity's -ve local y-axis + * direction, if you want them joined. Set to {@link Uuid(0)|Uuid.NULL} if there is none or you don't want to join them. + * @property {Uuid} zNNeighborID=Uuid.NULL - The ID of the neighboring PolyVox entity in the entity's -ve local z-axis + * direction, if you want them joined. Set to {@link Uuid(0)|Uuid.NULL} if there is none or you don't want to join them. + * @property {Uuid} xPNeighborID=Uuid.NULL - The ID of the neighboring PolyVox entity in the entity's +ve local x-axis + * direction, if you want them joined. Set to {@link Uuid(0)|Uuid.NULL} if there is none or you don't want to join them. + * @property {Uuid} yPNeighborID=Uuid.NULL - The ID of the neighboring PolyVox entity in the entity's +ve local y-axis + * direction, if you want them joined. Set to {@link Uuid(0)|Uuid.NULL} if there is none or you don't want to join them. + * @property {Uuid} zPNeighborID=Uuid.NULL - The ID of the neighboring PolyVox entity in the entity's +ve local z-axis + * direction, if you want them joined. Set to {@link Uuid(0)|Uuid.NULL} if there is none or you don't want to join them. * @example Create a textured PolyVox sphere. * var position = Vec3.sum(MyAvatar.position, Vec3.multiplyQbyV(MyAvatar.orientation, { x: 0, y: 0.5, z: -8 })); * var texture = "http://public.highfidelity.com/cozza13/tuscany/Concrete2.jpg"; @@ -1440,7 +1440,7 @@ EntityPropertyFlags EntityItemProperties::getChangedProperties() const { * false. Setting this property to false sets the billboardMode to * "none". *

Deprecated: This property is deprecated and will be removed.

- * @example Create a image entity. + * @example Create an image entity. * var image = Entities.addEntity({ * type: "Image", * position: Vec3.sum(MyAvatar.position, Vec3.multiplyQbyV(MyAvatar.orientation, { x: 0, y: 0, z: -5 })), diff --git a/libraries/entities/src/EntityScriptingInterface.h b/libraries/entities/src/EntityScriptingInterface.h index 605fcf6943..0666bb98df 100644 --- a/libraries/entities/src/EntityScriptingInterface.h +++ b/libraries/entities/src/EntityScriptingInterface.h @@ -111,10 +111,10 @@ public: * *

Entity Methods

* - *

Some of the API's signals correspond to entity methods that are called if, if present, in the entity being interacted - * with. The client or server entity script must expose them as a property. However, unlike {@link Entities.callEntityMethod}, - * server entity scripts do not need to list them in an remotelyCallable property. The entity methods are called - * with parameters per their corresponding signal.

+ *

Some of the API's signals correspond to entity methods that are called, if present, in the entity being interacted with. + * The client or server entity script must expose them as a property. However, unlike {@link Entities.callEntityMethod}, server + * entity scripts do not need to list them in an remotelyCallable property. The entity methods are called with + * parameters per their corresponding signal.

* * * @@ -295,7 +295,8 @@ public slots: * same domain coordinates unless parented to the client's avatar. * + * coordinates unless parented to the client's avatar. Additionally, local entities are always + * collisionless. * *
Method NameCorresponding Signal
"local"Local entities are ephemeral — they aren't stored anywhere — and * are visible only to the client. They follow the client to each domain visited, displaying at the same domain - * coordinates unless parented to the client's avatar. Additionally, local entities are collisionless.
* @typedef {string} Entities.EntityHostType @@ -405,7 +406,7 @@ public slots: * var properties = Entities.getEntityProperties(entityID, ["color"]); * print("Entity color: " + JSON.stringify(properties.color)); * - * Script.setTimeout(function () { // Wait for entity to finish creation before editing. + * Script.setTimeout(function () { // Wait for the entity to be created before editing. * Entities.editEntity(entityID, { * color: { red: 255, green: 0, blue: 0 } * }); @@ -969,7 +970,7 @@ public slots: * position coordinates are rounded to the nearest integer to get the voxel coordinate. The minimum axes * corner voxel is { x: 0, y: 0, z: 0 }. * @param {number} value - If value % 256 == 0 then voxel is cleared, otherwise the voxel is set. - * @example Create a cube PolyVox entity and clear the minimum axes corner voxel. + * @example Create a cube PolyVox entity and clear the minimum axes' corner voxel. * var entity = Entities.addEntity({ * type: "PolyVox", * position: Vec3.sum(MyAvatar.position, Vec3.multiplyQbyV(MyAvatar.orientation, { x: 0, y: 0.5, z: -8 })), @@ -1122,6 +1123,8 @@ public slots: * @returns {boolean} true if the entity was updated, otherwise false. The property may fail to * be updated if the entity does not exist, the entity is not a {@link Entities.EntityProperties-Line|Line} entity, * one of the points is outside the entity's dimensions, or the number of points is greater than the maximum allowed. + * @deprecated This function is deprecated and will be removed. Use {@link Entities.EntityProperties-PolyLine|PolyLine} + * entities instead. * @example Change the shape of a Line entity. * // Draw a horizontal line between two points. * var entity = Entities.addEntity({ @@ -1154,8 +1157,10 @@ public slots: * @param {Uuid} entityID - The ID of the {@link Entities.EntityProperties-Line|Line} entity. * @param {Vec3} point - The point to add to the line. The coordinates are relative to the entity's position. * @returns {boolean} true if the point was added to the line, otherwise false. The point may - * fail to be added if the entity does not exist, the entity is not a {@link Entities.EntityProperties-Line|Line} entity, the - * point is outside the entity's dimensions, or the maximum number of points has been reached. + * fail to be added if the entity does not exist, the entity is not a {@link Entities.EntityProperties-Line|Line} + * entity, the point is outside the entity's dimensions, or the maximum number of points has been reached. + * @deprecated This function is deprecated and will be removed. Use {@link Entities.EntityProperties-PolyLine|PolyLine} + * entities instead. * @example Append a point to a Line entity. * // Draw a line between two points. * var entity = Entities.addEntity({ @@ -1172,9 +1177,9 @@ public slots: * }); * * // Add a third point to create a "V". - * Script.setTimeout(function () { // Wait for entity to finish creation before editing. + * Script.setTimeout(function () { * Entities.appendPoint(entity, { x: 1, y: 1, z: 0 }); - * }, 50); + * }, 50); // Wait for the entity to be created. */ Q_INVOKABLE bool appendPoint(const QUuid& entityID, const glm::vec3& point); @@ -1610,7 +1615,7 @@ public slots: * var root = createEntity("Root", position, Uuid.NULL); * var child = createEntity("Child", Vec3.sum(position, { x: 0, y: -1, z: 0 }), root); * - * Script.setTimeout(function () { // Wait for entity to finish creation before editing. + * Script.setTimeout(function () { // Wait for the entity to be created before editing. * Entities.editEntity(root, { * parentID: MyAvatar.sessionUUID, * parentJointIndex: MyAvatar.getJointIndex("RightHand") @@ -2416,7 +2421,7 @@ signals: void addingEntity(const EntityItemID& entityID); /**jsdoc - * Triggered when an "wearable" entity is deleted, for example when removing a "wearable" from your avatar. + * Triggered when a "wearable" entity is deleted, for example when removing a "wearable" from your avatar. * @function Entities.deletingWearable * @param {Uuid} entityID - The ID of the "wearable" entity deleted. * @returns {Signal} @@ -2428,7 +2433,7 @@ signals: void deletingWearable(const EntityItemID& entityID); /**jsdoc - * Triggered when an "wearable" entity is added to Interface's local in-memory tree of entities it knows about, for example + * Triggered when a "wearable" entity is added to Interface's local in-memory tree of entities it knows about, for example * when adding a "wearable" to your avatar. * @function Entities.addingWearable * @param {Uuid} entityID - The ID of the "wearable" entity added. diff --git a/libraries/physics/src/ObjectDynamic.cpp b/libraries/physics/src/ObjectDynamic.cpp index ad070e296c..f02b7b1c4c 100644 --- a/libraries/physics/src/ObjectDynamic.cpp +++ b/libraries/physics/src/ObjectDynamic.cpp @@ -103,7 +103,7 @@ bool ObjectDynamic::updateArguments(QVariantMap arguments) { * @property {string} tag="" - A string that a script can use for its own purposes. * @property {number} ttl=0 - How long the action should exist, in seconds, before it is automatically deleted. A value of * 0 means that the action should not be deleted. - * @property {boolean} isMine=true - Is true if you created the action during your current Interface session, + * @property {boolean} isMine=true - Is true if the action was created during the current client session, * false otherwise. Read-only. * @property {boolean} ::no-motion-state - Is present when the entity hasn't been registered with the physics engine yet (e.g., * if the action hasn't been properly configured), otherwise undefined. Read-only.