MREA bug fixes

This commit is contained in:
Jack Andersen 2015-09-08 15:37:00 -10:00
parent 850fcd2747
commit 273a21a7f1
5 changed files with 5 additions and 5 deletions

View File

@ -97,7 +97,7 @@ void FinishBlenderMesh(HECL::BlenderConnection::PyOutStream& os,
"bpy.context.scene.objects.link(obj)\n"
"mesh.hecl_material_count = %u\n", matSetCount);
else
os.format("mesh = bpy.data.meshes.new(bpy.context.scene.name + '_%3d')\n"
os.format("mesh = bpy.data.meshes.new(bpy.context.scene.name + '_%03d')\n"
"obj = bpy.data.objects.new(mesh.name, mesh)\n"
"obj.show_transparent = True\n"
"bpy.context.scene.objects.link(obj)\n"

View File

@ -219,7 +219,7 @@ ResExtractor<PAKBridge> PAKBridge::LookupExtractor(const PAK::Entry& entry)
case SBIG('ANCS'):
return {nullptr, ANCS::Extract, {_S(".yaml"), _S(".blend")}, 2};
case SBIG('MREA'):
return {nullptr, MREA::Extract, {_S(".yaml"), _S(".blend")}, 3};
return {nullptr, MREA::Extract, {_S(".blend")}, 3};
case SBIG('MLVL'):
return {MLVL::Extract, nullptr, {_S(".yaml")}};
}

View File

@ -22,7 +22,7 @@ bool MREA::Extract(const SpecBase& dataSpec,
rs.seekAlign32();
HECL::BlenderConnection& conn = HECL::BlenderConnection::SharedConnection();
if (!conn.createBlend(outPath.getWithExtension(_S(".blend")).getAbsolutePath()))
if (!conn.createBlend(outPath.getAbsolutePath()))
return false;
/* Open Py Stream and read sections */

View File

@ -226,7 +226,7 @@ ResExtractor<PAKBridge> PAKBridge::LookupExtractor(const DNAMP1::PAK::Entry& ent
case SBIG('ANCS'):
return {nullptr, ANCS::Extract, {_S(".yaml"), _S(".blend")}, 2};
case SBIG('MREA'):
return {nullptr, MREA::Extract, {_S(".yaml"), _S(".blend")}, 3};
return {nullptr, MREA::Extract, {_S(".blend")}, 3};
}
return {};
}

View File

@ -164,7 +164,7 @@ bool MREA::Extract(const SpecBase& dataSpec,
/* Start up blender connection */
HECL::BlenderConnection& conn = HECL::BlenderConnection::SharedConnection();
if (!conn.createBlend(outPath.getWithExtension(_S(".blend")).getAbsolutePath()))
if (!conn.createBlend(outPath.getAbsolutePath()))
return false;
/* Open Py Stream and read sections */