Click or drag to resize

Physics2DServerBodyAddForce Method

Adds a positioned force to the applied force and torque. As with BodyApplyImpulse(RID, Vector2, Vector2), both the force and the offset from the body origin are in global coordinates. A force differs from an impulse in that, while the two are forces, the impulse clears itself after being applied.

Namespace:  Godot
Assembly:  GodotSharp (in GodotSharp.dll) Version: 1.0.0
Syntax
C#
public static void BodyAddForce(
	RID body,
	Vector2 offset,
	Vector2 force
)

Parameters

body
Type: GodotRID

[Missing <param name="body"/> documentation for "M:Godot.Physics2DServer.BodyAddForce(Godot.RID,Godot.Vector2,Godot.Vector2)"]

offset
Type: GodotVector2

[Missing <param name="offset"/> documentation for "M:Godot.Physics2DServer.BodyAddForce(Godot.RID,Godot.Vector2,Godot.Vector2)"]

force
Type: GodotVector2

[Missing <param name="force"/> documentation for "M:Godot.Physics2DServer.BodyAddForce(Godot.RID,Godot.Vector2,Godot.Vector2)"]

See Also