Skip to content
Snippets Groups Projects
Commit f97ae9fe authored by Amorilia's avatar Amorilia
Browse files

Fixed RemoveChild for nifs that have their skin influence flag set on NiNodes...

Fixed RemoveChild for nifs that have their skin influence flag set on NiNodes that aren't actually bone influences.
parent 637005ae
No related branches found
No related tags found
No related merge requests found
......@@ -228,11 +228,6 @@ void NiNode::RemoveChild( Ref<NiAVObject> obj ) {
//Search child list for the one to remove
for ( vector< NiAVObjectRef >::iterator it = children.begin(); it != children.end(); ) {
if ( *it == obj ) {
//Ensure that this child is not a skin influence
NiNodeRef niNode = DynamicCast<NiNode>((*it));
if ( niNode != NULL && niNode->IsSkinInfluence() == true ) {
throw runtime_error("You cannot remove a node child that is a skin influence. Detatch the skin first.");
}
(*it)->SetParent(NULL);
it = children.erase( it );
} else {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment