2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-08 15:04:56 +00:00

Work on cooking features

This commit is contained in:
Jack Andersen
2015-09-30 14:40:21 -10:00
parent 5f68a2a992
commit 1f9c8811d2
21 changed files with 152 additions and 27 deletions

View File

@@ -51,7 +51,7 @@ bool ReadANCSToBlender(HECL::BlenderConnection& conn,
HECL::ProjectPath cmdlPath = pakRouter.getWorking(cmdlE);
if (force || cmdlPath.getPathType() == HECL::ProjectPath::PT_NONE)
{
if (!conn.createBlend(cmdlPath.getAbsolutePath()))
if (!conn.createBlend(cmdlPath.getAbsolutePath(), HECL::BlenderConnection::TypeMesh))
return false;
HECL::SystemStringView bestNameView(pakRouter.getBestEntryName(*cmdlE));
@@ -77,14 +77,13 @@ bool ReadANCSToBlender(HECL::BlenderConnection& conn,
fileChanged(bestNameView.sys_str().c_str());
/* Establish ANCS blend */
if (!conn.createBlend(outPath.getAbsolutePath()))
if (!conn.createBlend(outPath.getAbsolutePath(), HECL::BlenderConnection::TypeActor))
return false;
HECL::BlenderConnection::PyOutStream os = conn.beginPythonOut(true);
os.format("import bpy\n"
"from mathutils import Vector\n"
"bpy.context.scene.name = '%s'\n"
"bpy.context.scene.hecl_type = 'ACTOR'\n"
"bpy.context.scene.hecl_mesh_obj = bpy.context.scene.name\n"
"\n"
"# Using 'Blender Game'\n"

View File

@@ -1001,7 +1001,6 @@ bool ReadCMDLToBlender(HECL::BlenderConnection& conn,
"import bmesh\n"
"\n"
"bpy.context.scene.name = '%s'\n"
"bpy.context.scene.hecl_type = 'MESH'\n"
"bpy.context.scene.hecl_mesh_obj = bpy.context.scene.name\n",
pakRouter.getBestEntryName(entry).c_str());
InitGeomBlenderContext(os, dataspec.getMasterShaderPath());