diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2018-08-30 08:05:42 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-08-30 08:05:42 +0200 |
commit | 9a5f3624948404df2f3720dc4bac433509893f6d (patch) | |
tree | bba4ffde3b535b7b5a2a0b953f89a433ed1baf9a /doc/classes | |
parent | 9eb4d4ab2d65c7e29b07308c7f18f40b6530f5a2 (diff) | |
parent | 74aa104607ee48f07e21c20dd073c7d117b16886 (diff) |
Merge pull request #21585 from TGRCdev/rigidbody_docs
Documented some RigidBody and PhysicsDirectBodyState methods
Diffstat (limited to 'doc/classes')
-rw-r--r-- | doc/classes/PhysicsDirectBodyState.xml | 8 | ||||
-rw-r--r-- | doc/classes/RigidBody.xml | 6 |
2 files changed, 14 insertions, 0 deletions
diff --git a/doc/classes/PhysicsDirectBodyState.xml b/doc/classes/PhysicsDirectBodyState.xml index 91fc4df4ff..2f3501ae5d 100644 --- a/doc/classes/PhysicsDirectBodyState.xml +++ b/doc/classes/PhysicsDirectBodyState.xml @@ -15,6 +15,8 @@ <argument index="0" name="force" type="Vector3"> </argument> <description> + Adds a constant directional force without affecting rotation. + This is equivalent to [code]add_force(force, Vector3(0,0,0))[/code]. </description> </method> <method name="add_force"> @@ -25,6 +27,7 @@ <argument index="1" name="position" type="Vector3"> </argument> <description> + Adds a constant force (i.e. acceleration). </description> </method> <method name="add_torque"> @@ -33,6 +36,7 @@ <argument index="0" name="torque" type="Vector3"> </argument> <description> + Adds a constant rotational force (i.e. a motor) without affecting position. </description> </method> <method name="apply_central_impulse"> @@ -41,6 +45,8 @@ <argument index="0" name="j" type="Vector3"> </argument> <description> + Applies a single directional impulse without affecting rotation. + This is equivalent to ``apply_impulse(Vector3(0,0,0), impulse)``. </description> </method> <method name="apply_impulse"> @@ -51,6 +57,7 @@ <argument index="1" name="j" type="Vector3"> </argument> <description> + Apply a positioned impulse (which will be affected by the body mass and shape). This is the equivalent of hitting a billiard ball with a cue: a force that is applied once, and only once. Both the impulse and the position are in global coordinates, and the position is relative to the object's origin. </description> </method> <method name="apply_torque_impulse"> @@ -59,6 +66,7 @@ <argument index="0" name="j" type="Vector3"> </argument> <description> + Apply a torque impulse (which will be affected by the body mass and shape). This will rotate the body around the passed in vector. </description> </method> <method name="get_contact_collider" qualifiers="const"> diff --git a/doc/classes/RigidBody.xml b/doc/classes/RigidBody.xml index 038464e127..4ae1ef8e94 100644 --- a/doc/classes/RigidBody.xml +++ b/doc/classes/RigidBody.xml @@ -30,6 +30,8 @@ <argument index="0" name="force" type="Vector3"> </argument> <description> + Adds a constant directional force without affecting rotation. + This is equivalent to [code]add_force(force, Vector3(0,0,0))[/code]. </description> </method> <method name="add_force"> @@ -40,6 +42,7 @@ <argument index="1" name="position" type="Vector3"> </argument> <description> + Adds a constant force (i.e. acceleration). </description> </method> <method name="add_torque"> @@ -48,6 +51,7 @@ <argument index="0" name="torque" type="Vector3"> </argument> <description> + Adds a constant rotational force (i.e. a motor) without affecting position. </description> </method> <method name="apply_central_impulse"> @@ -56,6 +60,8 @@ <argument index="0" name="impulse" type="Vector3"> </argument> <description> + Applies a single directional impulse without affecting rotation. + This is equivalent to ``apply_impulse(Vector3(0,0,0), impulse)``. </description> </method> <method name="apply_impulse"> |