Beispiel #1
0
        public void Read(ADT combinedFile)
        {
            var mcnkIdx = 0;

            foreach (var subChunk in Data.Chunks)
            {
                switch (subChunk.Name)
                {
                case "MMDX":
                    combinedFile.MMDX = new MMDX(subChunk);
                    break;

                case "MMID":
                    combinedFile.MMID = new MMID(subChunk);
                    break;

                case "MWMO":
                    combinedFile.MWMO = new MWMO(subChunk);
                    break;

                case "MWID":
                    combinedFile.MWID = new MWID(subChunk);
                    break;

                case "MDDF":
                    combinedFile.MDDF = new MDDF(subChunk);
                    break;

                case "MODF":
                    combinedFile.MODF = new MODF(subChunk);
                    break;

                case "MCNK":
                    combinedFile.UpdateMapChunk(subChunk, mcnkIdx++);
                    break;

                default:
                    Console.WriteLine($"Unhandled {subChunk.Name} chunk in Objects ADT.");
                    break;
                }
            }
        }
Beispiel #2
0
        public void Read(ADT combinedFile)
        {
            var mcnkIdx = 0;

            foreach (var subChunk in Data.Chunks)
            {
                switch (subChunk.Name)
                {
                case "MTEX":
                    combinedFile.MTEX = new MTEX(subChunk);
                    break;

                case "MCNK":
                    combinedFile.UpdateMapChunk(subChunk, mcnkIdx++);
                    break;

                default:
                    Console.WriteLine($"Unhandled {subChunk.Name} chunk in Textures ADT.");
                    break;
                }
            }
        }