Random City Naming?

MythicCommodore

Chieftain
Joined
Feb 27, 2009
Messages
33
Hi all, I have a question that's been nagging me for some time and I can't find an answer. Is it possible for the city names to be pulled from the Civ4CivilizationInfos.xml in a random order? IE so that the Romans will always found Rome first, but then their next city might be Mediolanium or Cumae. I'm getting a little tired of always founding the same cities in the same order. ;) Anyway, I've done some searches and it seems like I'm not the first person to ask this question, but every time it's been asked, no one's answered it. Is this possible through the SDK or even the python without being horrendously complicated? Anyway, thanks for any answers.

mythic
 
Easy in the SDK. In CvWString CvPlayer::getNewCityName() const, change this code,

Code:
	for (pNode = headCityNameNode(); (pNode != NULL); pNode = nextCityNameNode(pNode))
to
Code:
	for (pNode = headCityNameNode(); (pNode != NULL) && getCapitalCity() == NULL; pNode = nextCityNameNode(pNode))

Which should cause it to generate a random city name instead of the ordered list, after the capital has been named. Haven't tested it though, curious to see if it works.
 
Back
Top Bottom