Just answered my own question by browsing existing mods. Thanks to Eotinb for using this function in his "simple reminders" mod
I'm using this to show a message when a city grows. I know quite a few other ppl were looking for this as well. The automatic assigning of new citizens can be a pain.
So, if you want this, make a copy of CvEventManager.py, and place it in your ...\My Games\Sid Meier's Civilization 4\CustomAssets\python folder.
Right after this:
Code:
def onCityGrowth(self, argsList):
'City Population Growth'
pCity = argsList[0]
iPlayer = argsList[1]
CvUtil.pyPrint("%s has grown" %(pCity.getName(),))
add this:
Code:
# Notify me when a city grows.
message = pCity.getName() + " has grown."
CyInterface().addMessage(iPlayer, True, 30, message, '', 0, None, ColorTypes(11), 0, 0, False, False)
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.