This commit is contained in:
Garrett Brown
2020-08-16 19:01:59 -04:00
parent 59a1a4b2cd
commit 09db462fd6
16 changed files with 111 additions and 124 deletions
+4 -8
View File
@@ -57,22 +57,18 @@ void ChainShape::setPreviousVertex(float x, float y)
c->m_prevVertex = Physics::scaleDown(v);
}
void ChainShape::getNextVertex(float &x, float &y) const
b2Vec2 ChainShape::getNextVertex() const
{
b2ChainShape *c = (b2ChainShape *)shape;
b2Vec2 v = Physics::scaleUp(c->m_nextVertex);
x = v.x;
y = v.y;
return Physics::scaleUp(c->m_nextVertex);
}
void ChainShape::getPreviousVertex(float &x, float &y) const
b2Vec2 ChainShape::getPreviousVertex() const
{
b2ChainShape *c = (b2ChainShape *)shape;
b2Vec2 v = Physics::scaleUp(c->m_prevVertex);
x = v.x;
y = v.y;
return Physics::scaleUp(c->m_prevVertex);
}
EdgeShape *ChainShape::getChildEdge(int index) const