Buildings with Multiple Specialist Slots

Noatz

Warlord
Joined
Sep 7, 2011
Messages
172
Location
England
I'm working on a mod at the moment, and one of the buildings I am adding I want to have four specialist slots - one of each type. I haven't seen this yet in any published mod which is down to one of two possible reasons:
1. Noone has thought to do it.
2. Noone has worked out how to do it.

In XML this isn't possible; it will only accept one category of specialist per building. Is it possible to write a lua script or edit this in SQL?
 
I'm working on a mod at the moment, and one of the buildings I am adding I want to have four specialist slots - one of each type. I haven't seen this yet in any published mod which is down to one of two possible reasons:
1. Noone has thought to do it.
2. Noone has worked out how to do it.

In XML this isn't possible; it will only accept one category of specialist per building. Is it possible to write a lua script or edit this in SQL?

It's possible to have 4 slots. Old versions of my NiGHTS mod employed this. It's easy, (but tedious) - to implement. You'll need to alter CityView.xml, CityView_small.xml, and CityView.lua, and then include these files in your mod (using the "import into VFS" option). Wherever there's a reference to specialist buildings, you'll have to add an additional one for the 4th slot, (it has a max of 5). If you miss one example in any of these files, expect bugs to show up.

You also might need to alter GlobalDefines.xml and set:

MAX_SPECIALISTS_FROM_BUILDING to 4 (if it isn't already set as this may have been tweaked in one of the patches).

What's not possible is to have different specialists assigned to each slot - you can only have one specialist type per building.
 
Ah I see, a shame its not possible to run different types but oh well, I had a workaround prepared for that outcome in any case.

Thanks for the pointers - I'll still want four slots in it regardless.
 
Back
Top Bottom