keywords = { ".mat": "material",
".mesh": "mesh",
".object": "object",
- ".tech": "technique" }
+ ".tech": "technique",
+ ".tex2d": "texture2d" }
with open(os.path.join(path, base+"_resources.mdc"), "w") as res_out:
for r in refs:
st = Statement(keywords[os.path.splitext(r.name)[1]], r.name)
object_export = ObjectExporter()
object_export.single_file = False
+ material_maps = {}
+
for i, o in enumerate(objs):
progress.push_task_slice(o.name, i, len(objs))
- object_export.export_object_resources(context, o, resources, progress)
+ object_export.export_object_resources(context, o, resources, progress, material_maps=material_maps)
obj_name = o.name+".object"
resources[obj_name] = object_export.export_object(context, o, progress, resources=resources)
progress.pop_task()