[Source]Halo Map Loader
Posted: Thu Jul 04, 2013 4:43 am
Last week I got a bit bored so I wrote a basic Halo retail/full map parser and setup the editor code for it. Much of the scenario loading I based off swordedit code and then rewrote to be at least 2x faster than swordedit and a magnitude more memory efficient. I have also added code to this that will parse entity plugins and allow you to use them to map out the metadata of tags in a loaded map file. This was written with speed in mind, it is very fast, and allows you to load different plugins per map you choose.
How to use:
If something doesn't seem to work, check that you are supplying a valid halo full/retail map and the plugin directory is the one containing all the plugins, it doesn't go looking so you need to provide the immediate folder. To access tags, they are are an array in the struct HaloMap called "struct MapTags *tags;"
and the total tag count is accessed like so:
Code: https://github.com/samdmarshall/SDMHaloMapLoader
How to use:
Code: Select all
HaloMap *myMap = ParseHaloMapFromFileWithPlugins("/path/to/a/map/file/bloodgulch.map", "/path/to/the/folder/with/entity/plugins/in/it");
If something doesn't seem to work, check that you are supplying a valid halo full/retail map and the plugin directory is the one containing all the plugins, it doesn't go looking so you need to provide the immediate folder. To access tags, they are are an array in the struct HaloMap called "struct MapTags *tags;"
Code: Select all
myMap->tags[tagnumber]
Code: Select all
myMap->index->tagCount