From 34bf847913a0041d6073d2a443389e34cf6a72a8 Mon Sep 17 00:00:00 2001 From: Alex Szpakowski Date: Mon, 27 Apr 2015 19:08:02 -0300 Subject: [PATCH] Removed redundant definition of ChainShape:getChildCount. --- src/modules/physics/box2d/ChainShape.cpp | 6 ------ src/modules/physics/box2d/ChainShape.h | 5 ----- src/modules/physics/box2d/wrap_ChainShape.cpp | 8 -------- src/modules/physics/box2d/wrap_ChainShape.h | 1 - 4 files changed, 20 deletions(-) diff --git a/src/modules/physics/box2d/ChainShape.cpp b/src/modules/physics/box2d/ChainShape.cpp index 63cdf9f04..b85f4ed29 100644 --- a/src/modules/physics/box2d/ChainShape.cpp +++ b/src/modules/physics/box2d/ChainShape.cpp @@ -85,12 +85,6 @@ EdgeShape *ChainShape::getChildEdge(int index) const return new EdgeShape(e, true); } -int ChainShape::getChildCount() const -{ - b2ChainShape *c = (b2ChainShape *)shape; - return c->GetChildCount(); -} - int ChainShape::getVertexCount() const { b2ChainShape *c = (b2ChainShape *)shape; diff --git a/src/modules/physics/box2d/ChainShape.h b/src/modules/physics/box2d/ChainShape.h index f2defdf05..74c7b6dd3 100644 --- a/src/modules/physics/box2d/ChainShape.h +++ b/src/modules/physics/box2d/ChainShape.h @@ -63,11 +63,6 @@ public: **/ void setPreviousVertex(float x, float y); - /** - * Gets the number of children shapes. - **/ - int getChildCount() const; - /** * Returns a child EdgeShape. * @param index The index of the child shape. diff --git a/src/modules/physics/box2d/wrap_ChainShape.cpp b/src/modules/physics/box2d/wrap_ChainShape.cpp index 918aecc35..cdf3f6aee 100644 --- a/src/modules/physics/box2d/wrap_ChainShape.cpp +++ b/src/modules/physics/box2d/wrap_ChainShape.cpp @@ -52,13 +52,6 @@ int w_ChainShape_setPreviousVertex(lua_State *L) return 0; } -int w_ChainShape_getChildCount(lua_State *L) -{ - ChainShape *c = luax_checkchainshape(L, 1); - lua_pushinteger(L, c->getChildCount()); - return 1; -} - int w_ChainShape_getChildEdge(lua_State *L) { ChainShape *c = luax_checkchainshape(L, 1); @@ -109,7 +102,6 @@ static const luaL_Reg functions[] = { { "setNextVertex", w_ChainShape_setNextVertex }, { "setPreviousVertex", w_ChainShape_setPreviousVertex }, - { "getChildCount", w_ChainShape_getChildCount }, { "getChildEdge", w_ChainShape_getChildEdge }, { "getVertexCount", w_ChainShape_getVertexCount }, { "getPoint", w_ChainShape_getPoint }, diff --git a/src/modules/physics/box2d/wrap_ChainShape.h b/src/modules/physics/box2d/wrap_ChainShape.h index 2a2f878ff..312730fcf 100644 --- a/src/modules/physics/box2d/wrap_ChainShape.h +++ b/src/modules/physics/box2d/wrap_ChainShape.h @@ -37,7 +37,6 @@ ChainShape *luax_checkchainshape(lua_State *L, int idx); int w_ChainShape_setNextVertex(lua_State *L); int w_ChainShape_setPreviousVertex(lua_State *L); -int w_ChainShape_getChildCount(lua_State *L); int w_ChainShape_getChildEdge(lua_State *L); int w_ChainShape_getVertexCount(lua_State *L); int w_ChainShape_getPoint(lua_State *L);