diff --git a/.vs/Toolbox/v15/.suo b/.vs/Toolbox/v15/.suo index f4095352..e9b2feae 100644 Binary files a/.vs/Toolbox/v15/.suo and b/.vs/Toolbox/v15/.suo differ diff --git a/File_Format_Library/FileFormats/Grezzo/CMB.cs b/File_Format_Library/FileFormats/Grezzo/CMB.cs index 452925aa..42140354 100644 --- a/File_Format_Library/FileFormats/Grezzo/CMB.cs +++ b/File_Format_Library/FileFormats/Grezzo/CMB.cs @@ -838,7 +838,7 @@ namespace FirstPlugin for (int i = 0; i < meshCount; i++) { if (header.Version == CMBVersion.OOT3DS) - reader.SeekBegin(meshPos + (i * 0x04)); + reader.SeekBegin(meshPos + (i * 4)); else if (header.Version == CMBVersion.MM3DS) reader.SeekBegin(meshPos + (i * 0x0C)); else if (header.Version >= CMBVersion.LM3DS) @@ -848,6 +848,9 @@ namespace FirstPlugin mesh.SepdIndex = reader.ReadUInt16(); mesh.MaterialIndex = reader.ReadByte(); Meshes.Add(mesh); + + Console.WriteLine($"SepdIndex {mesh.SepdIndex}"); + Console.WriteLine($"MaterialIndex { mesh.MaterialIndex}"); } } @@ -934,6 +937,8 @@ namespace FirstPlugin else reader.SeekBegin(pos + 0x24); + Console.WriteLine("sepd count " + count); + Position = ReadVertexAttrib(reader); Normal = ReadVertexAttrib(reader); if (header.Version >= CMBVersion.MM3DS) diff --git a/File_Format_Library/FileFormats/Grezzo/CMB_Enums.cs b/File_Format_Library/FileFormats/Grezzo/CMB_Enums.cs index 36a0381b..e2d9b0c2 100644 --- a/File_Format_Library/FileFormats/Grezzo/CMB_Enums.cs +++ b/File_Format_Library/FileFormats/Grezzo/CMB_Enums.cs @@ -37,10 +37,10 @@ namespace Grezzo.CmbEnums public enum CullMode : byte { - FRONT_AND_BACK, + NONE, BACK, FRONT, - NONE, + FRONT_AND_BACK, } public enum SkinningMode : ushort diff --git a/File_Format_Library/FileFormats/Grezzo/ZSI.cs b/File_Format_Library/FileFormats/Grezzo/ZSI.cs index 7d104d24..12d79c26 100644 --- a/File_Format_Library/FileFormats/Grezzo/ZSI.cs +++ b/File_Format_Library/FileFormats/Grezzo/ZSI.cs @@ -86,6 +86,8 @@ namespace FirstPlugin string CodeName = reader.ReadString(0x0C); + Console.WriteLine("Version " + Version); + var Rooms = ReadRoomHeaders(reader, Version); foreach (var room in Rooms) LoadRooms(room, this);