That helps a lot with changing it to a new but constant value, like the current giant_map mod does. (Having it in the constants.json helps to avoid overriding the js)
What I’m trying now is adding options to the map selection screen to chose the desired map size (small, normal, large). The ui is done, but I need to change that value according to the option selected.
I’m not sure how the $.widget() works, but here’s a link I found: Widget Factory | jQuery UI
If you check selectSettlement.js, it creates a widget of that type with id #map, passing some values:
It’s possible that you can retrieve #map instead and try to get the options.settlementRadius from there somehow. (Not sure, since I’m not familiar with this).
I discovered that in the end I was kinda doing it right. The problem was the values I was passing to it. For some reason, when trying to use jquery methods the values were not updating, but using pure javascript worked fine.