|
Thread: GK's Command-line Map Editor | |
|
gnollking

 
    
Supreme Hero
|
posted March 18, 2024 03:22 PM |
|
|
GK's Command-line Map Editor
h3_map_editor (GitHub)
While working on my maps, the limitations of the normal map editor grew quite annoying. Working on HotA and already having a lot of progress in some maps, using RoseKavalier's excellent Unleashed editor was not an option, so the most logical and simple solution for me was to learn the entire map file format and make my own .
Description
- h3_map_editor is a simple command-line tool made with pure python, useful for mass changes that are tedious to make with the normal editor, or changing literally anything you want with no limitations. Currently supports HotA version 1.7.0.
- The program parses a given map into easily editable python dictionaries, allows you to modify it with custom scripts in any way you need, then saves the map into a new file. The code itself still needs quite a lot of cleanup, but the provided README should be enough for any interested people to check it out. The code is released under the MIT license, allowing anyone to do pretty much anything they want with it.
- Cleaning up the code and explaining what every part does is an ongoing project. The goal is for the editor to be easy to use and expand, especially for making custom scripts. The way the map data is stored is not likely to change much, so any scripts made now should work for a long time. It's just the way the editor reads and writes that map data that needs cleaning up. Hope someone finds it useful!
____________
|
|
Warmonger

  
     
Promising
Legendary Hero
fallen artist
|
posted March 19, 2024 07:33 AM |
|
|
|
gnollking

 
    
Supreme Hero
|
posted March 19, 2024 12:00 PM |
|
|
That's a pretty nice idea. I did think about making some helper functions to place and remove objects on the map and modify the terrain, but haven't really had the time. The objects "handler" is probably the one file that needs the most cleaning up (thanks for all the additional bytes to decipher and parse for almost every visitable object, HotA 1.7.0 ).
|
|
|
|