Ok, what I'm trying to do here is make an event that removes a random religion from all cities. The event uses this python function:
It's mostly modified from the Gods of Old Inquisitor function, and I assume I've left out some important part, but I don't know enough about python to be sure. It doesn't seem to do anything at all, is the problem. Can anyone see anything immediately wrong with it?
Code:
def doObsoleteReligion1(argsList):
kTriggeredData = argsList[0]
iReligion = kTriggeredData.eReligion
gc.getGame( ).clearHolyCity( iReligion )
for iPlayer in range(gc.getGame( ).getNumCivPlayers()):
pPlayer = gc.getPlayer(iPlayer)
for iCity in range(pPlayer.getNumCities()):
pCity = pPlayer.getCity(iCity)
pCity.setHasReligion(iReligion, 0, 0, 0)
It's mostly modified from the Gods of Old Inquisitor function, and I assume I've left out some important part, but I don't know enough about python to be sure. It doesn't seem to do anything at all, is the problem. Can anyone see anything immediately wrong with it?