summaryrefslogtreecommitdiff
path: root/doc/classes/RigidBody2D.xml
diff options
context:
space:
mode:
Diffstat (limited to 'doc/classes/RigidBody2D.xml')
-rw-r--r--doc/classes/RigidBody2D.xml34
1 files changed, 34 insertions, 0 deletions
diff --git a/doc/classes/RigidBody2D.xml b/doc/classes/RigidBody2D.xml
index 75fbb48454..2265c777c8 100644
--- a/doc/classes/RigidBody2D.xml
+++ b/doc/classes/RigidBody2D.xml
@@ -23,6 +23,14 @@
Allows you to read and safely modify the simulation state for the object. Use this instead of [Node._physics_process] if you need to directly change the body's [code]position[/code] or other physics properties. By default it works in addition to the usual physics behavior, but [member custom_integrator] allows you to disable the default behavior and write custom force integration for a body.
</description>
</method>
+ <method name="add_central_force">
+ <return type="void">
+ </return>
+ <argument index="0" name="force" type="Vector2">
+ </argument>
+ <description>
+ </description>
+ </method>
<method name="add_force">
<return type="void">
</return>
@@ -34,6 +42,22 @@
Adds a positioned force to the body. Both the force and the offset from the body origin are in global coordinates.
</description>
</method>
+ <method name="add_torque">
+ <return type="void">
+ </return>
+ <argument index="0" name="torque" type="float">
+ </argument>
+ <description>
+ </description>
+ </method>
+ <method name="apply_central_impulse">
+ <return type="void">
+ </return>
+ <argument index="0" name="impulse" type="Vector2">
+ </argument>
+ <description>
+ </description>
+ </method>
<method name="apply_impulse">
<return type="void">
</return>
@@ -45,6 +69,14 @@
Applies a positioned impulse to the body (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 instantaneously. Both the impulse and the offset from the body origin are in global coordinates.
</description>
</method>
+ <method name="apply_torque_impulse">
+ <return type="void">
+ </return>
+ <argument index="0" name="torque" type="float">
+ </argument>
+ <description>
+ </description>
+ </method>
<method name="get_colliding_bodies" qualifiers="const">
<return type="Array">
</return>
@@ -130,6 +162,8 @@
<member name="mode" type="int" setter="set_mode" getter="get_mode" enum="RigidBody2D.Mode">
The body's mode. See [code]MODE_*[/code] constants. Default value: [code]MODE_RIGID[/code].
</member>
+ <member name="physics_material_override" type="PhysicsMaterial" setter="set_physics_material_override" getter="get_physics_material_override">
+ </member>
<member name="sleeping" type="bool" setter="set_sleeping" getter="is_sleeping">
If [code]true[/code] the body is sleeping and will not calculate forces until woken up by a collision or by using [method apply_impulse] or [method add_force].
</member>