Improved ray shape (2D and 3D) by addiing the possibility to act as regular shape

This commit is contained in:
Andrea Catania
2018-02-19 20:59:57 +01:00
parent cbdd410a6f
commit ffc3ef8677
15 changed files with 117 additions and 20 deletions

View File

@@ -54,6 +54,11 @@ void btRayShape::setLength(btScalar p_length) {
reload_cache();
}
void btRayShape::setSlipsOnSlope(bool p_slipsOnSlope) {
slipsOnSlope = p_slipsOnSlope;
}
btVector3 btRayShape::localGetSupportingVertex(const btVector3 &vec) const {
return localGetSupportingVertexWithoutMargin(vec) + (m_shapeAxis * m_collisionMargin);
}