diff --git a/components/nifosg/nifloader.cpp b/components/nifosg/nifloader.cpp index 25e5a38641..d4ecee0e87 100644 --- a/components/nifosg/nifloader.cpp +++ b/components/nifosg/nifloader.cpp @@ -1134,8 +1134,7 @@ namespace NifOsg void handleTriShape(const Nif::Node* nifNode, osg::Group* parentNode, SceneUtil::CompositeStateSetUpdater* composite, const std::vector& boundTextures, int animflags) { - if (nifNode->recType != Nif::RC_NiTriShape && nifNode->recType != Nif::RC_NiTriStrips) - return; + assert(nifNode->recType == Nif::RC_NiTriShape || nifNode->recType == Nif::RC_NiTriStrips); osg::ref_ptr drawable; osg::ref_ptr geom (new osg::Geometry); @@ -1197,12 +1196,11 @@ namespace NifOsg void handleSkinnedTriShape(const Nif::Node *nifNode, osg::Group *parentNode, SceneUtil::CompositeStateSetUpdater* composite, const std::vector& boundTextures, int animflags) { - if (nifNode->recType != Nif::RC_NiTriShape && nifNode->recType != Nif::RC_NiTriStrips) - return; + assert(nifNode->recType == Nif::RC_NiTriShape || nifNode->recType == Nif::RC_NiTriStrips); osg::ref_ptr geometry (new osg::Geometry); Nif::NiSkinInstancePtr skinPtr; - if (nifNode->recType != Nif::RC_NiTriShape) + if (nifNode->recType == Nif::RC_NiTriShape) { const Nif::NiTriShape* triShape = static_cast(nifNode); triShapeToGeometry(triShape, geometry, parentNode, composite, boundTextures, animflags);