From ec7e82c9de37b99edd62f0d26fe33aa21a5b4d57 Mon Sep 17 00:00:00 2001 From: Gyedo Jeon Date: Thu, 19 Mar 2009 21:36:26 +0000 Subject: [PATCH] Made other egg flags be set properly --- pandatool/src/mayaegg/mayaEggLoader.cxx | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/pandatool/src/mayaegg/mayaEggLoader.cxx b/pandatool/src/mayaegg/mayaEggLoader.cxx index 5ea0c0cea9..194f4cc8c4 100755 --- a/pandatool/src/mayaegg/mayaEggLoader.cxx +++ b/pandatool/src/mayaegg/mayaEggLoader.cxx @@ -1372,6 +1372,11 @@ void MayaEggLoader::TraverseEggNode(EggNode *node, EggGroup *context, string del if (context->get_model_flag()) { mesh->AddEggFlag("model"); } + + // [gjeon] to handle other flags + for (int i = 0; i < context->get_num_object_types(); i++) { + mesh->AddEggFlag(MString(context->get_object_type(i).c_str())); + } } else if (node->is_of_type(EggNurbsSurface::get_class_type())) { // [gjeon] to convert nurbsSurface @@ -1449,6 +1454,11 @@ void MayaEggLoader::TraverseEggNode(EggNode *node, EggGroup *context, string del surface->AddEggFlag("model"); } + // [gjeon] to handle other flags + for (int i = 0; i < context->get_num_object_types(); i++) { + surface->AddEggFlag(MString(context->get_object_type(i).c_str())); + } + } else if (node->is_of_type(EggComment::get_class_type())) { string comment = (DCAST(EggComment, node))->get_comment(); if (comment.find("2egg") != string::npos) {