add and use Entity::getClassName(), Entity::hasKeyValue()

do not return default value from getKeyValue()
This commit is contained in:
Garux
2021-05-16 10:13:42 +03:00
parent ed04f90497
commit da98f5f9d9
18 changed files with 73 additions and 78 deletions

View File

@@ -212,7 +212,7 @@ public:
: pFile( pFile ), exclusionList( exclusionList ){
}
void operator()( scene::Instance& instance ) const {
const char* classname = Node_getEntity( instance.path().top() )->getKeyValue( "classname" );
const char* classname = Node_getEntity( instance.path().top() )->getClassName();
if ( !strcmp( classname, "worldspawn" ) ) {
world.LoadFromEntity( instance.path().top(), false );