Building as requirement for units/buildings OR improvements that look like cities? ?

Wilting

Chieftain
Joined
Jun 9, 2012
Messages
9
I would like to make it so rather than civilizations having unique units/buildings, anyone who captures a city of a civilization can build their units in that city.

Initially I was thinking of a resource/improvement of small towns, placed for a scenario in the right historical area, but am at a loss how to get a resource/improvement that looks like pop 1 cities (Also haven't been able to find entries for resource requirements in xml files).

So now I am thinking that each civ could have a unique "building" (so 'Romans' in Rome) automatically built in each of their cities, which is a requirement for that civs units/buildings, and could possibly also confer civ traits as well. When the city is captured, the conqueror could recruit the relevant units etc.

But I'm not sure if it is possible to do that with buildings?

Anyway, a solution to either problem would be great. I would greatly appreciate any help.
 
There are several ways you may attempt this with the easiest being via the building system and the hardest via LUA using function CityTrainingRestriction (iPlayer, iCity, iUnitType).

Easiest way (which I use in my scenario) is to require a building for a specific unit and then require that building to need a resource nearby the city via XML. Then all you do is place the resource directly under that city.

The LUA version is more complex and best answered by some of the LUA gurus in this thread as I am still learning myself!
 
Back
Top Bottom