summaryrefslogtreecommitdiff
path: root/servers/physics
diff options
context:
space:
mode:
authorRaphaelHunter <Raphael10241024@gmail.com>2019-08-15 19:34:47 +0800
committerRaphaelHunter <Raphael10241024@gmail.com>2019-08-22 20:30:03 +0800
commit74713fe970716818b643f7043b655129943624f3 (patch)
tree35f3992af1eed3fe4d55faa4c6eaec90ad3b1965 /servers/physics
parent7978e9071b9b2e5056a6a4ef2ece44d7ea00b4fb (diff)
Fix custom inertia in physics2d, closes#30838
Diffstat (limited to 'servers/physics')
-rw-r--r--servers/physics/body_sw.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/servers/physics/body_sw.cpp b/servers/physics/body_sw.cpp
index 172a2a3429..a3bb581cb5 100644
--- a/servers/physics/body_sw.cpp
+++ b/servers/physics/body_sw.cpp
@@ -266,6 +266,7 @@ void BodySW::set_mode(PhysicsServer::BodyMode p_mode) {
_inv_mass = mass > 0 ? (1.0 / mass) : 0;
_set_static(false);
+ angular_velocity = Vector3();
} break;
}