Refactor el big #1
[convexer.git] / __init__.py
index 0e4ddd283edf8fbbdf125f4f38b01793ee1dc2fe..624bce098f7740768c3f6e2204ff5c4b25e67bdb 100644 (file)
@@ -396,8 +396,8 @@ cxr_graph_mapping = {
       {
          "ShaderNodeMixRGB":
          {
-            "Color1": material_tex_image("$basetexture"),
-            "Color2": material_tex_image("$decaltexture")
+            "Color1": material_tex_image("basetexture"),
+            "Color2": material_tex_image("decaltexture")
          },
          "ShaderNodeTexImage":
          {
@@ -412,7 +412,7 @@ cxr_graph_mapping = {
       {
          "ShaderNodeNormalMap":
          {
-            "Color": material_tex_image("$bumpmap")
+            "Color": material_tex_image("bumpmap")
          }
       }
    }
@@ -636,6 +636,16 @@ cxr_entities = {
          "enabled": {"type": "int", "default": 1 },
       })
    },
+   "info_player_terrorist":
+   {
+      "gizmo": [],
+      "allow": ('EMPTY',),
+      "keyvalues": ent_baseclass([ent_transform],\
+      {
+         "priority": {"type": "int", "default": 0 },
+         "enabled": {"type": "int", "default": 1 },
+      })
+   },
    "light": { "keyvalues": ent_lights },
    "light_spot": { "keyvalues": ent_lights },
    # SUN
@@ -957,12 +967,17 @@ class CXR_WRITE_VMF(bpy.types.Operator):
          def _collect(collection,transform):
             if collection.name.startswith('.'):
                return
+            
+            if collection.hide_render:
+               return
 
             if collection.name.startswith('mdl_'):
                _collect.heros += [(collection,transform)]
                return
 
             for obj in collection.objects:
+               if obj.hide_get(): continue
+
                classname = cxr_classname( obj )
 
                if classname != None:
@@ -976,6 +991,7 @@ class CXR_WRITE_VMF(bpy.types.Operator):
          _collect.a_models = set()
          _collect.entities = []
          _collect.geo = []
+         _collect.heros = []
 
          transform_main = cxr_object_context( context.scene.cxr_data.scale_factor, 0.0 )
          transform_sky = cxr_object_context( context.scene.cxr_data.skybox_scale_factor, \