Author Topic: Yet another simple(?) question.  (Read 688 times)

Legacy_Tarot Redhand

  • Hero Member
  • *****
  • Posts: 4165
  • Karma: +0/-0
Yet another simple(?) question.
« on: July 23, 2010, 02:34:47 pm »


               OK guys another of my little questions that I hope someone can help me with. When either the toolset or the game itself loads a .mdl file how does it know whether the model has already been compiled or not? Both have the same extension so as far as they are concerned it could be either. Does the compiled version have some sort of code at the start that should never occur in the ascii version? If so how many bytes long is it and what are the actual values of the bytes.

Thanks in advance.

TR
               
               

               
            

Legacy_Michael DarkAngel

  • Hero Member
  • *****
  • Posts: 627
  • Karma: +0/-0
Yet another simple(?) question.
« Reply #1 on: July 23, 2010, 10:47:13 pm »


               A binary or compiled version of the mdl file's first byte should always be hex 0x00



An ascii version of the mdl file should always start with a remark line such as "#MAXMODEL" or something similar depending on what tool was used to decompile the binary mdl.



'Posted

MDA
               
               

               
            

Legacy_Tarot Redhand

  • Hero Member
  • *****
  • Posts: 4165
  • Karma: +0/-0
Yet another simple(?) question.
« Reply #2 on: July 23, 2010, 11:35:45 pm »


               Thanks. I knew it had to be something simple like that. Having looked inside a couple of compiled ones I just wondered if it was more bytes in size because all the ones I looked at had 4 nul bytes at the start.
               
               

               


                     Modifié par Tarot Redhand, 23 juillet 2010 - 10:36 .
                     
                  


            

Legacy_Michael DarkAngel

  • Hero Member
  • *****
  • Posts: 627
  • Karma: +0/-0
Yet another simple(?) question.
« Reply #3 on: July 24, 2010, 12:37:57 am »


               Now that I think about it, it is 4 bytes.
               
               

               


                     Modifié par Michael DarkAngel, 23 juillet 2010 - 11:39 .