Apply offset on meshes with exact collision shape, fixes #2300
This commit is contained in:
parent
90b95c7fb5
commit
9a6b41d2b5
@ -324,7 +324,6 @@ void PhysicalObject::init()
|
||||
}
|
||||
case MP_EXACT:
|
||||
{
|
||||
m_graphical_offset = Vec3(0,0,0);
|
||||
extend.setY(0);
|
||||
TriangleMesh* triangle_mesh = new TriangleMesh();
|
||||
|
||||
@ -450,7 +449,8 @@ void PhysicalObject::init()
|
||||
triangle_mesh->createCollisionShape();
|
||||
m_shape = &triangle_mesh->getCollisionShape();
|
||||
m_triangle_mesh = triangle_mesh;
|
||||
|
||||
m_init_pos.setOrigin(m_init_pos.getOrigin() + m_graphical_offset);
|
||||
// m_graphical_offset = Vec3(0,0,0);
|
||||
break;
|
||||
}
|
||||
case MP_NONE:
|
||||
|
Loading…
Reference in New Issue
Block a user