Changing barb city names

Koning

Warlord
Joined
Sep 19, 2009
Messages
128
Location
Netherlands
When I conquer a barbarian city, I always immediately rename it. I mean, who is a fan of those crappy adjectives of tribe names like Cimmerian or Gepid???
I'd really like it if the other AI civs would do the same, and automatically pick the next city name on their list. Or even better, pick a random name of their city list! So you won't see the Zulu city of Burgundian, the Dutch city of Zapotec, or the American city of Uzbek anymore (although Illinois or Apache are not that bad in case of the Americans;)

Does anyone happen to know whether a app/mod like this is already written? I don't like, btw, any conquered city to be renamed. Only the uncultured brabarian cities that quickly assimilate into the "civilized" culture that conquered them.
 
I don't know of any mod that does that, but I'm sure it's possible. In R&F, when someone captures a city, it changes to more fit the Civ it's now part of. Like if Willem founded Cape Town, it would be called like "Kaapstadt" or whatever, and if England conquered it, it changes itself to "Cape Town". I'm sure it possible to do it.
 
You could try altering the XML to change the names of the barbarian cities, that way, although there might still be a culture clash thing going on, at least they would be real cities, perhaps even from the same culture, here are a few example,

Assyria = Nineveh
Cherokee = Kituwa
Teotihuacan = Teotihuacan, this was the cities name, hence it's inclusion on the Aztec city list
Saxon = Eresburg
Goth = Gothiscandza
Etruscan = Velzna
Bantu = Zvongombe

Another thing which I think would be interesting, and I've no idea how to do it, would be to randomise city names every game.
After all, when the barbarians found cities, they are always a random order, never the same, and if you destroy the barbarian city of, say, Ainu, the next one they build will not be Ainu again, but a different one. Is there any way of doing this with every civs cities? Or you could go even further and have semi-randomisation. So there will be some cities which you have to build first, but you won't know what order, then others, and again, you won't know what order.
So for example with the Mongolian list, you would have to build all the "old" cities first, Karakorum, Beshbalik, Turfan, etc... although you wouldn't know what order they would be in, then when you had built them all you could build all the "new" cities, Ulaan Bataar, Hovd, etc... but again, you wouldn't know what order they would appear. It would add some diversity to the game I feel.
 
Proper name of cities include [but not limited to]: izzy blocker, double-fish north, marble cow, etc
 
I do the opposite. I choose my own names for cities I found and don't rename conquered cities.
 
Should be an easy change in python. Go into CvEventsManager.py and find the method "onCityAquired".

Code:
	def onCityAcquired(self, argsList):
		'City Acquired'
		iPreviousOwner,iNewOwner,pCity,bConquest,bTrade = argsList
		CvUtil.pyPrint('City Acquired Event: %s' %(pCity.getName()))

Replace all of that with this:

Code:
	def onCityAcquired(self, argsList):
		'City Acquired'
		iPreviousOwner,iNewOwner,pCity,bConquest,bTrade = argsList
		CvUtil.pyPrint('City Acquired Event: %s' %(pCity.getName()))
		if gc.getPlayer(iPreviousOwner).isBarbarian():
			pCity.setName(gc.getPlayer(iNewOwner).getNewCityName(),0)

The only change should be the two lines on the end. This should set the barb city to whatever the civ would normally name their next city. I haven't used the function before, so I'm not sure if it will "check off" the city from the list when it does this. If not, I'll see if can figure out how to do that.
 
Should be an easy change in python. Go into CvEventsManager.py and find the method "onCityAquired".

Code:
	def onCityAcquired(self, argsList):
		'City Acquired'
		iPreviousOwner,iNewOwner,pCity,bConquest,bTrade = argsList
		CvUtil.pyPrint('City Acquired Event: %s' %(pCity.getName()))

Replace all of that with this:

Code:
	def onCityAcquired(self, argsList):
		'City Acquired'
		iPreviousOwner,iNewOwner,pCity,bConquest,bTrade = argsList
		CvUtil.pyPrint('City Acquired Event: %s' %(pCity.getName()))
		if gc.getPlayer(iPreviousOwner).isBarbarian():
			pCity.setName(gc.getPlayer(iNewOwner).getNewCityName(),0)

The only change should be the two lines on the end. This should set the barb city to whatever the civ would normally name their next city. I haven't used the function before, so I'm not sure if it will "check off" the city from the list when it does this. If not, I'll see if can figure out how to do that.

You do not know how happy I am to see that! I've been manually renaming the cities each time!


EDIT: It works, and I settled a new city afterwards and it progressed to the next name in the list, as it should. Awesome.
 
Top Bottom