浏览代码

eggprogs: Fix compiler warnings

rdb 1 年之前
父节点
当前提交
b50ad2efe9
共有 2 个文件被更改,包括 6 次插入7 次删除
  1. 4 5
      pandatool/src/daeegg/daeCharacter.cxx
  2. 2 2
      pandatool/src/eggprogs/eggRename.cxx

+ 4 - 5
pandatool/src/daeegg/daeCharacter.cxx

@@ -40,12 +40,11 @@ TypeHandle DaeCharacter::_type_handle;
 DaeCharacter::
 DaeCharacter::
 DaeCharacter(EggGroup *node_group, const FCDControllerInstance *instance) :
 DaeCharacter(EggGroup *node_group, const FCDControllerInstance *instance) :
   _node_group(node_group),
   _node_group(node_group),
-  _name(node_group->get_name()),
+  _skin_mesh(nullptr),
   _instance(instance),
   _instance(instance),
-  _skin_controller(nullptr),
-  _skin_mesh(nullptr) {
-
-  _bind_shape_mat = LMatrix4d::ident_mat();
+  _bind_shape_mat(LMatrix4d::ident_mat()),
+  _name(node_group->get_name()),
+  _skin_controller(nullptr) {
 
 
   // If it's a skin controller, add the controller joints.
   // If it's a skin controller, add the controller joints.
   const FCDController *controller = (const FCDController *)instance->GetEntity();
   const FCDController *controller = (const FCDController *)instance->GetEntity();

+ 2 - 2
pandatool/src/eggprogs/eggRename.cxx

@@ -37,11 +37,11 @@ run() {
   if (!_strip_prefix.empty()) {
   if (!_strip_prefix.empty()) {
     nout << "Stripping prefix from nodes.\n";
     nout << "Stripping prefix from nodes.\n";
     int num_renamed = 0;
     int num_renamed = 0;
-    int num_egg_files = 0;
+    //int num_egg_files = 0;
     Eggs::iterator ei;
     Eggs::iterator ei;
     for (ei = _eggs.begin(); ei != _eggs.end(); ++ei) {
     for (ei = _eggs.begin(); ei != _eggs.end(); ++ei) {
       num_renamed += (*ei)->rename_nodes(_strip_prefix, true);
       num_renamed += (*ei)->rename_nodes(_strip_prefix, true);
-      ++num_egg_files;
+      //++num_egg_files;
     }
     }
     nout << "  (" << num_renamed << " renamed.)\n";
     nout << "  (" << num_renamed << " renamed.)\n";
   }
   }