Open Halo Parser: Demo
Posted: Fri Jan 15, 2010 8:22 pm
Not having anything to do during my winter break, I started writing classes for RB on map parsing. I'll have a link to the source of some of the classes. A few still need work, such as "Linked Maps," the driving force of map decompiling, memory loading, and compiling.
This demo of sorts contains the roots of my little project. It's basically a class for loading maps and pulling information from them without having to go back to the file itself, once loaded, of course. It also has a few universal methods and such which could be useful in other, non-Halo applications. An example of this is my basic "string reader." Will read strings without a set length, like those in map files. I know many programs do the same thing, but they also seem to set the stream backwards to read a character, this doesn't, making it a little faster.
Well, not much more to say, so here's a few examples of using it:
Loading a map:
Once we've got our map loaded, we can pull any info we'd like from the tags or header and whatnot:
It's pretty much that easy to pull anything you need.
Download
This demo of sorts contains the roots of my little project. It's basically a class for loading maps and pulling information from them without having to go back to the file itself, once loaded, of course. It also has a few universal methods and such which could be useful in other, non-Halo applications. An example of this is my basic "string reader." Will read strings without a set length, like those in map files. I know many programs do the same thing, but they also seem to set the stream backwards to read a character, this doesn't, making it a little faster.
Well, not much more to say, so here's a few examples of using it:
Loading a map:
Code: Select all
//f will be our folderitem, already having a file assigned to it.
Dim New_map As New Halo_map
New_map.load(f)
Code: Select all
\\Displaying a message box stating the SCNR's, or first tag in the map's, length
Msgbox Str(New_map.tags(0).length)
Download