forked from mirror/openmw-tes3mp
Closes #1107: Do not create box shapes unless the box collision flag is enabled
This commit is contained in:
parent
3ea1407ed3
commit
79a6ffd216
1 changed files with 6 additions and 3 deletions
|
@ -228,11 +228,14 @@ void ManualBulletShapeLoader::handleNode(btTriangleMesh* mesh, const Nif::Node *
|
|||
&& (!isMarker || (mShape->mHasCollisionNode && !raycasting)))
|
||||
{
|
||||
if(node->hasBounds)
|
||||
{
|
||||
if (node->flags & Nif::NiNode::Flag_BBoxCollision)
|
||||
{
|
||||
mShape->mBoxTranslation = node->boundPos;
|
||||
mShape->mBoxRotation = node->boundRot;
|
||||
mBoundingBox = new btBoxShape(getbtVector(node->boundXYZ));
|
||||
}
|
||||
}
|
||||
else if(node->recType == Nif::RC_NiTriShape)
|
||||
{
|
||||
mShape->mCollide = !(flags&0x800);
|
||||
|
|
Loading…
Reference in a new issue