CharonM72 / SatelliteMapMaker

Creates a satellite imagery-like map of Dwarf Fortress worlds!
14 stars 2 forks source link

Use known filename pattern to avoid passing all names as arguments #15

Closed PeridexisErrant closed 9 years ago

PeridexisErrant commented 9 years ago

Instead of passing every filename, why not pass a directory and can the contents for the required files?

CharonM72 commented 9 years ago

Do you mean when checking if all the map files are present?

PeridexisErrant commented 9 years ago

My proposal is to remove the file names from the .bat script, and simply pass a folder containing all the maps and the dirt/trees/mountains images. The scheme script would then find the set itself, meaning that far fewer parameters are required. This could be done by passing a single file, then applying file-glob and knowledge of the naming pattern to find the others.

I generally favor setting up good defaults and a minimal interface, since it's easier for people to use and integrate into other tools - so as well as this, I'd make the flags for atmosphere etc optional and just default to something sensible if it's left out. I might eventually try my own fork of the FMM again, and give that a minimal interface.

CharonM72 commented 9 years ago

Well the main reason I had it scan for all of them individually was to check if they were there at all. Then it could output a helpful "you didn't export all your maps," instead of GIMP just closing with no output and the batch file saying "Complete". I could change it so that the GIMP command line that the batch file runs isn't horrendously long, but it doesn't really affect functionality or speed or usability so I haven't bothered so far.

PeridexisErrant commented 9 years ago

Makes sense.