From f40f360a2c4ca8e6f2a651dbcca3ae82e2abe7a1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Verschelde?= Date: Fri, 8 Jul 2016 00:32:28 +0200 Subject: Remove unused variables (fourth pass) + dead code Also fix a potential regression from 3fcb9b1ec179b99d979d4cfea9b5e3c80e4a3e33. --- servers/physics_2d/shape_2d_sw.cpp | 3 --- servers/physics_2d/space_2d_sw.cpp | 4 ---- 2 files changed, 7 deletions(-) (limited to 'servers/physics_2d') diff --git a/servers/physics_2d/shape_2d_sw.cpp b/servers/physics_2d/shape_2d_sw.cpp index 8b583dd3c6..9291aa6c17 100644 --- a/servers/physics_2d/shape_2d_sw.cpp +++ b/servers/physics_2d/shape_2d_sw.cpp @@ -243,7 +243,6 @@ bool SegmentShape2DSW::intersect_segment(const Vector2& p_begin,const Vector2& p if (!Geometry::segment_intersects_segment_2d(p_begin,p_end,a,b,&r_point)) return false; - Vector2 d = p_end-p_begin; if (n.dot(p_begin) > n.dot(a)) { r_normal=n; } else { @@ -825,7 +824,6 @@ bool ConcavePolygonShape2DSW::intersect_segment(const Vector2& p_begin,const Vec const Segment *segmentptr=&segments[0]; const Vector2 *pointptr=&points[0]; const BVH *bvhptr = &bvh[0]; - int pos=bvh.size()-1; stack[0]=0; @@ -1088,7 +1086,6 @@ void ConcavePolygonShape2DSW::cull(const Rect2& p_local_aabb,Callback p_callback const Segment *segmentptr=&segments[0]; const Vector2 *pointptr=&points[0]; const BVH *bvhptr = &bvh[0]; - int pos=bvh.size()-1; stack[0]=0; diff --git a/servers/physics_2d/space_2d_sw.cpp b/servers/physics_2d/space_2d_sw.cpp index ddef5fc86b..5fde6f567b 100644 --- a/servers/physics_2d/space_2d_sw.cpp +++ b/servers/physics_2d/space_2d_sw.cpp @@ -200,7 +200,6 @@ int Physics2DDirectSpaceStateSW::intersect_shape(const RID& p_shape, const Matri int amount = space->broadphase->cull_aabb(aabb,space->intersection_query_results,p_result_max,space->intersection_query_subindex_results); - bool collided=false; int cc=0; for(int i=0;ibroadphase->cull_aabb(aabb,space->intersection_query_results,Space2DSW::INTERSECTION_QUERY_MAX,space->intersection_query_subindex_results); bool collided=false; - int cc=0; r_result_count=0; Physics2DServerSW::CollCbkData cbk; @@ -768,7 +765,6 @@ bool Space2DSW::test_body_motion(Body2DSW *p_body,const Vector2&p_motion,float p for(int i=0;i<8;i++) { //steps should be customizable.. - //Matrix32 xfa = p_xform; float ofs = (low+hi)*0.5; Vector2 sep=mnormal; //important optimization for this to work fast enough -- cgit v1.2.3