Changes

Jump to navigation Jump to search
2 bytes removed ,  21:35, 23 June 2017
→‎Reading the body: Renamed GetChunkFlags to original CMwNod class member function GetChunkInfo
Line 79: Line 79:  
             return;
 
             return;
 
   
 
   
         chunkFlags = GetChunkFlags(chunkID);
+
         chunkFlags = GetChunkInfo(chunkID);
 
         if (chunkFlags & 0x10)
 
         if (chunkFlags & 0x10)
 
         {
 
         {
Line 90: Line 90:  
  }
 
  }
   −
GetChunkFlags() doesn't read anything from the file; it provides loading flags for the specified chunk ID. The only important flag is whether or not the chunk is "skippable". If it is, the chunk ID is followed by an uint32 0x50494B53 ("SKIP", shows up as "PIKS" in the file due to little-endian ordering) and an uint32 specifying the size of the chunk data. This allows older versions of TrackMania that don't know how to parse this chunk ID to skip over the chunk data and go to the next chunk. If the chunk is not skippable, the chunk data follows immediately after the chunk ID.
+
GetChunkInfo() doesn't read anything from the file; it provides loading flags for the specified chunk ID. The only important flag is whether or not the chunk is "skippable". If it is, the chunk ID is followed by an uint32 0x50494B53 ("SKIP", shows up as "PIKS" in the file due to little-endian ordering) and an uint32 specifying the size of the chunk data. This allows older versions of TrackMania that don't know how to parse this chunk ID to skip over the chunk data and go to the next chunk. If the chunk is not skippable, the chunk data follows immediately after the chunk ID.
    
A dummy chunk ID of 0xFACADE01 signifies the end of the chunk list for the current class.
 
A dummy chunk ID of 0xFACADE01 signifies the end of the chunk list for the current class.

Navigation menu