summaryrefslogtreecommitdiffstats
path: root/servers/physics_3d/physics_server_3d_sw.cpp
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 /servers/physics_3d/physics_server_3d_sw.cpp
parent030a26206ff70b1050c885270afce89b0430af70 (diff)
downloadredot-engine-ba27deef06f0152a59c86e3b0ab3ebb0976344ad.tar.gz
Refactor physics force and impulse code
Diffstat (limited to 'servers/physics_3d/physics_server_3d_sw.cpp')
-rw-r--r--servers/physics_3d/physics_server_3d_sw.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/servers/physics_3d/physics_server_3d_sw.cpp b/servers/physics_3d/physics_server_3d_sw.cpp
index 1c2329f2dc..143cc9ebbd 100644
--- a/servers/physics_3d/physics_server_3d_sw.cpp
+++ b/servers/physics_3d/physics_server_3d_sw.cpp
@@ -710,11 +710,11 @@ void PhysicsServer3DSW::body_add_central_force(RID p_body, const Vector3 &p_forc
body->wakeup();
}
-void PhysicsServer3DSW::body_add_force(RID p_body, const Vector3 &p_force, const Vector3 &p_pos) {
+void PhysicsServer3DSW::body_add_force(RID p_body, const Vector3 &p_force, const Vector3 &p_position) {
Body3DSW *body = body_owner.getornull(p_body);
ERR_FAIL_COND(!body);
- body->add_force(p_force, p_pos);
+ body->add_force(p_force, p_position);
body->wakeup();
};
@@ -736,13 +736,13 @@ void PhysicsServer3DSW::body_apply_central_impulse(RID p_body, const Vector3 &p_
body->wakeup();
}
-void PhysicsServer3DSW::body_apply_impulse(RID p_body, const Vector3 &p_pos, const Vector3 &p_impulse) {
+void PhysicsServer3DSW::body_apply_impulse(RID p_body, const Vector3 &p_impulse, const Vector3 &p_position) {
Body3DSW *body = body_owner.getornull(p_body);
ERR_FAIL_COND(!body);
_update_shapes();
- body->apply_impulse(p_pos, p_impulse);
+ body->apply_impulse(p_impulse, p_position);
body->wakeup();
};