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

Minor fixes and cleanup

This commit is contained in:
2019-08-03 17:02:53 -07:00
parent 9d2cbf61ed
commit ff83dbc676
12 changed files with 96 additions and 13 deletions

View File

@@ -1650,7 +1650,7 @@ TXTR::Meta TXTR::GetMetaData(DataSpec::PAKEntryReadStream& rs) {
atUint16 palHeight = rs.readUint16Big();
palMeta.elementCount = palWidth * palHeight;
atUint32 palSize = atUint32(palWidth * palHeight * 2);
if (palMeta.format == 4)
if (format == 8)
textureSize /= 2;
std::unique_ptr<u8[]> palData(new u8[palSize]);
rs.readUBytesToBuf(palData.get(), palSize);

View File

@@ -454,6 +454,7 @@ static void _ConstructMaterial(Stream& out, const MAT& material, unsigned groupI
out.format(fmt("new_material = bpy.data.materials.new('MAT_{}_{}')\n"), groupIdx, matIdx);
out << "new_material.use_fake_user = True\n"
"new_material.use_nodes = True\n"
"new_material.use_backface_culling = True\n"
"new_nodetree = new_material.node_tree\n"
"for n in new_nodetree.nodes:\n"
" new_nodetree.nodes.remove(n)\n"

View File

@@ -7,7 +7,7 @@ namespace DataSpec::DNAMP1 {
struct CTweakGame final : ITweakGame {
AT_DECL_DNA_YAML
String<-1> x4_worldPrefix;
String<-1> x14_ruinsArea; // ????
String<-1> x14_defaultRoom;
Value<float> x24_fov;
Value<bool> x28_unknown1;
Value<bool> x29_unknown2;
@@ -30,6 +30,7 @@ struct CTweakGame final : ITweakGame {
Value<float> x64_hardmodeWeaponMult;
std::string_view GetWorldPrefix() const { return x4_worldPrefix; }
std::string_view GetDefaultRoom() const { return x14_defaultRoom; }
bool GetSplashScreensDisabled() const { return x2b_splashScreensDisabled; }
float GetFirstPersonFOV() const { return x24_fov; }
float GetPressStartDelay() const { return x30_pressStartDelay; }