You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: doc/classes/PhysicsServer3D.xml
+36Lines changed: 36 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -1058,6 +1058,42 @@
1058
1058
Adds the given body to the list of bodies exempt from collisions.
1059
1059
</description>
1060
1060
</method>
1061
+
<methodname="soft_body_apply_central_force">
1062
+
<returntype="void" />
1063
+
<paramindex="0"name="body"type="RID" />
1064
+
<paramindex="1"name="force"type="Vector3" />
1065
+
<description>
1066
+
Distributes and applies a force to all points. A force is time dependent and meant to be applied every physics update.
1067
+
</description>
1068
+
</method>
1069
+
<methodname="soft_body_apply_central_impulse">
1070
+
<returntype="void" />
1071
+
<paramindex="0"name="body"type="RID" />
1072
+
<paramindex="1"name="impulse"type="Vector3" />
1073
+
<description>
1074
+
Distributes and applies an impulse to all points.
1075
+
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).
1076
+
</description>
1077
+
</method>
1078
+
<methodname="soft_body_apply_point_force">
1079
+
<returntype="void" />
1080
+
<paramindex="0"name="body"type="RID" />
1081
+
<paramindex="1"name="point_index"type="int" />
1082
+
<paramindex="2"name="force"type="Vector3" />
1083
+
<description>
1084
+
Applies a force to a point. A force is time dependent and meant to be applied every physics update.
1085
+
</description>
1086
+
</method>
1087
+
<methodname="soft_body_apply_point_impulse">
1088
+
<returntype="void" />
1089
+
<paramindex="0"name="body"type="RID" />
1090
+
<paramindex="1"name="point_index"type="int" />
1091
+
<paramindex="2"name="impulse"type="Vector3" />
1092
+
<description>
1093
+
Applies an impulse to a point.
1094
+
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).
Copy file name to clipboardExpand all lines: doc/classes/SoftBody3D.xml
+32Lines changed: 32 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -19,6 +19,38 @@
19
19
Adds a body to the list of bodies that this body can't collide with.
20
20
</description>
21
21
</method>
22
+
<methodname="apply_central_force">
23
+
<returntype="void" />
24
+
<paramindex="0"name="force"type="Vector3" />
25
+
<description>
26
+
Distributes and applies a force to all points. A force is time dependent and meant to be applied every physics update.
27
+
</description>
28
+
</method>
29
+
<methodname="apply_central_impulse">
30
+
<returntype="void" />
31
+
<paramindex="0"name="impulse"type="Vector3" />
32
+
<description>
33
+
Distributes and applies an impulse to all points.
34
+
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).
35
+
</description>
36
+
</method>
37
+
<methodname="apply_force">
38
+
<returntype="void" />
39
+
<paramindex="0"name="point_index"type="int" />
40
+
<paramindex="1"name="force"type="Vector3" />
41
+
<description>
42
+
Applies a force to a point. A force is time dependent and meant to be applied every physics update.
43
+
</description>
44
+
</method>
45
+
<methodname="apply_impulse">
46
+
<returntype="void" />
47
+
<paramindex="0"name="point_index"type="int" />
48
+
<paramindex="1"name="impulse"type="Vector3" />
49
+
<description>
50
+
Applies an impulse to a point.
51
+
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).
ERR_FAIL_COND_MSG(!in_space(), vformat("Failed to apply impulse to '%s'. Doing so without a physics space is not supported when using Jolt Physics. If this relates to a node, try adding the node to a scene tree first.", to_string()));
ERR_FAIL_COND_MSG(pinned_vertices.has(physics_index), vformat("Failed to apply impulse to point at index %d for '%s'. Point was found to be pinned.", static_cast<int>(physics_index), to_string()));
ERR_FAIL_COND_MSG(!in_space(), vformat("Failed to apply force to '%s'. Doing so without a physics space is not supported when using Jolt Physics. If this relates to a node, try adding the node to a scene tree first.", to_string()));
ERR_FAIL_COND_MSG(!in_space(), vformat("Failed to apply central impulse to '%s'. Doing so without a physics space is not supported when using Jolt Physics. If this relates to a node, try adding the node to a scene tree first.", to_string()));
ERR_FAIL_COND_MSG(!in_space(), vformat("Failed to apply central force to '%s'. Doing so without a physics space is not supported when using Jolt Physics. If this relates to a node, try adding the node to a scene tree first.", to_string()));
0 commit comments