As an FYI, I think I managed to clean this up in the source configs, importing the DoC source into VS (at least if it's the same version as mine) should be easier now.
Something like: when 1500 AD, select a city in the Punjab province and found Sikhism there? I assume Sikhism has already been added to the game and you can defined iSikhism in Consts.py correctly.
The place to put the trigger is the checkTurn() (or maybe onBeginGameTurn()) method in either CvRFCEventHandler.py or maybe Religions.py (if something like that exists). You should have an iGameTurn variable in those methods, and be able to check the years as
Code:
iGameTurn == getTurnForYear(1500)
There should be examples of that.
I'm pretty sure SoI has a utility method (in RFCUtils) that selects a random city in a province, but I don't know what it's called. Let's say it's utils.getRandomCityByProvince, but you have to look it up and make sure what arguments it requires and what values it returns (it might return a city directly, or the coordinates of a city).
Then you can do:
Code:
punjabiCity = utils.getRandomCityByProvince(rPunjab)
if (punjabiCity):
gc.getGame().setHolyCity(iSikhism, punjabiCity)
This also checks if there is a city in Punjab at all. Depending on what you want to happen in case no city exists there you need to change how this works.