diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2017-08-22 00:58:12 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-08-22 00:58:12 +0200 |
commit | df590fc2d33c1ba715a4ce58f71d83e0ed9f5693 (patch) | |
tree | 8bfdc3e033aaf4dc9a5de5e8040e4f99afa0c540 /servers/physics | |
parent | 13f879587dd9bce59528e44b0faaf6e062f6d918 (diff) | |
parent | 738d2ab96997faa1e13b91e38cf8a0000d829f70 (diff) |
Merge pull request #10340 from Rubonnek/remove-unnecessary-assignments
Removed unnecessary assignments
Diffstat (limited to 'servers/physics')
-rw-r--r-- | servers/physics/broad_phase_octree.cpp | 1 | ||||
-rw-r--r-- | servers/physics/space_sw.cpp | 10 |
2 files changed, 3 insertions, 8 deletions
diff --git a/servers/physics/broad_phase_octree.cpp b/servers/physics/broad_phase_octree.cpp index e1aaf4e31a..fb2144bd03 100644 --- a/servers/physics/broad_phase_octree.cpp +++ b/servers/physics/broad_phase_octree.cpp @@ -124,6 +124,5 @@ BroadPhaseOctree::BroadPhaseOctree() { octree.set_unpair_callback(_unpair_callback, this); pair_callback = NULL; pair_userdata = NULL; - pair_callback = NULL; unpair_userdata = NULL; } diff --git a/servers/physics/space_sw.cpp b/servers/physics/space_sw.cpp index 094cfa4656..fc52aa45aa 100644 --- a/servers/physics/space_sw.cpp +++ b/servers/physics/space_sw.cpp @@ -474,8 +474,7 @@ bool PhysicsDirectSpaceStateSW::rest_info(RID p_shape, const Transform &p_shape_ Vector3 PhysicsDirectSpaceStateSW::get_closest_point_to_object_volume(RID p_object, const Vector3 p_point) const { - CollisionObjectSW *obj = NULL; - obj = PhysicsServerSW::singleton->area_owner.getornull(p_object); + CollisionObjectSW *obj = PhysicsServerSW::singleton->area_owner.getornull(p_object); if (!obj) { obj = PhysicsServerSW::singleton->body_owner.getornull(p_object); } @@ -598,11 +597,8 @@ bool SpaceSW::test_body_motion(BodySW *p_body, const Transform &p_from, const Ve cbk.amount = 0; cbk.ptr = sr; - CollisionSolverSW::CallbackResult cbkres = NULL; - - PhysicsServerSW::CollCbkData *cbkptr = NULL; - cbkptr = &cbk; - cbkres = PhysicsServerSW::_shape_col_cbk; + PhysicsServerSW::CollCbkData *cbkptr = &cbk; + CollisionSolverSW::CallbackResult cbkres = PhysicsServerSW::_shape_col_cbk; bool collided = false; |