Closed Hoserdud closed 1 year ago
Hello, I'm don't know a lot about the FVTT. Will you be able to raise a Pull Request? Out data model is stated here: https://github.com/Azgaar/Fantasy-Map-Generator/wiki/Data-model
The out data doesn't include the "?size=38" or the "&sea=0.52" part of the burg generator url, so I'll see about raising a pull request, but I think that's needed to get a 1:1 import.
I guess I'm asking if all these const's could be included in burg out data
const sizeRaw = 2.13 Math.pow((burgPopulation populationRate) / urbanDensity, 0.385); const size = minmax(Math.ceil(sizeRaw), 6, 100); const population = rn(burgPopulation populationRate urbanization); const river = cells.r[cell] ? 1 : 0; const coast = Number(burg.port > 0); const sea = coast && cells.haven[cell] ? getSeaDirections(cell) : null;
With that I could fix the FVTT importer
It would be nice if you can raise a pull request.
Closing as I don't really know what to do...
Problem When exporting map files for the FVTT importer, there is no size attribute for burgs, amongst other missing data. This results in certain burgs being much smaller when loaded into the FVTT addon. This essentially means that when using the exported .map data, there's not an easy way to reconstruct the burg generator url to make the same exact burg.
for example, this is the information for a burg in my test map export:
{"cell":2722,"x":1103.5,"y":577.5,"state":0,"i":32,"culture":10,"name":"Harmouth","capital":0,"feature":9,"port":1,"population":17.305,"type":"Naval","coa":{"t1":"azure","charges":[{"charge":"mascle","t":"argent","p":"jlh","size":0.7}],"shield":"fantasy1"},"citadel":0,"plaza":0,"walls":1,"shanty":0,"temple":0}
And the map url gives it a size of 38. If you don't include that size variable, the burg generator defaults to size 15.
Solution Include all data that is in the url of the burg generator.
Alternatives An explanation for how the generator comes up with the burg size attribute so it can be implemented in the FVTT importer.