summaryrefslogtreecommitdiffstats
path: root/doc/classes/RigidBody2D.xml
diff options
context:
space:
mode:
authorAaron Franke <arnfranke@yahoo.com>2020-03-26 00:23:34 -0400
committerAaron Franke <arnfranke@yahoo.com>2020-06-02 23:18:59 -0400
commitba27deef06f0152a59c86e3b0ab3ebb0976344ad (patch)
tree9c5e8fac16de8beb6a657c7a2f5386f3190292f5 /doc/classes/RigidBody2D.xml
parent030a26206ff70b1050c885270afce89b0430af70 (diff)
downloadredot-engine-ba27deef06f0152a59c86e3b0ab3ebb0976344ad.tar.gz
Refactor physics force and impulse code
Diffstat (limited to 'doc/classes/RigidBody2D.xml')
-rw-r--r--doc/classes/RigidBody2D.xml10
1 files changed, 5 insertions, 5 deletions
diff --git a/doc/classes/RigidBody2D.xml b/doc/classes/RigidBody2D.xml
index 8379fc5b58..9bf1627a09 100644
--- a/doc/classes/RigidBody2D.xml
+++ b/doc/classes/RigidBody2D.xml
@@ -34,9 +34,9 @@
<method name="add_force">
<return type="void">
</return>
- <argument index="0" name="offset" type="Vector2">
+ <argument index="0" name="force" type="Vector2">
</argument>
- <argument index="1" name="force" type="Vector2">
+ <argument index="1" name="position" type="Vector2" default="Vector2( 0, 0 )">
</argument>
<description>
Adds a positioned force to the body. Both the force and the offset from the body origin are in global coordinates.
@@ -54,7 +54,7 @@
<method name="apply_central_impulse">
<return type="void">
</return>
- <argument index="0" name="impulse" type="Vector2">
+ <argument index="0" name="impulse" type="Vector2" default="Vector2( 0, 0 )">
</argument>
<description>
Applies a directional impulse without affecting rotation.
@@ -63,9 +63,9 @@
<method name="apply_impulse">
<return type="void">
</return>
- <argument index="0" name="offset" type="Vector2">
+ <argument index="0" name="impulse" type="Vector2">
</argument>
- <argument index="1" name="impulse" type="Vector2">
+ <argument index="1" name="position" type="Vector2" default="Vector2( 0, 0 )">
</argument>
<description>
Applies a positioned impulse to the body. An impulse is time-independent! Applying an impulse every frame would result in a framerate-dependent force. For this reason it should only be used when simulating one-time impacts (use the "_force" functions otherwise). The position uses the rotation of the global coordinate system, but is centered at the object's origin.