Need help with some technical stuff

Hi all!

Me and a friend of mine are planning to start a new mod after Christmas break, once he’s back in town, and we need some help. One of the basic premises of the mod is to make new layouts for current buildings, as well as making these locations really feel unique. However, we’re having problems locating certain location files. Specifically, locations such as prisons, gun stores, bars, etc.

We’ve tried looking in the json folder pertaining to buildings, but no files related to these locations are there.

Any help you can offer would be greatly appreciated.

Most of the buildings are still hardcoded. mapgen and mapgenfunctions.cpp are where non-JSON buildings either are, or can be traced from.

Thanks. Honestly, we were afraid this was the case. Still, it’s a start at least.

Is there any word on weather these buildings will be moved to .json format?

We’d like to, but it’s a fairly low priority so there’s no particular timeframe. Sorry.

You can create additional layouts in json for those buildings however. If you look at the gunsmith.json you’ll see it replaces s_gun, which is the id for gun stores. The hard coded map gen functions are in mapgen_functions.cpp, and if you want to take a crack at translating them to json it’d be appreciated.

If you haven’t played around with adding json before, it’s really easy to test, as you just need to launch and load a game after adding a new json, and it’ll spit out debug info if there’s any issue.

One last thing: someone mentioned that more buildings should use carpets instead of flooring. It’s a good idea, I just haven’t had time to switch it out in some jsons, but something to keep in mind if you’re making new layouts.

Good luck, and feel free to ask if you have any more questions. :slight_smile: