View Full Version : Dynamic Civ Names


jdog5000
Jun 11, 2007, 01:32 AM
DynamicCivNames Description
Version 0.41
By jdog5000
For BTS 3.13

The goal:

This component renames civs based on their civics choices and other status factors. A civs names will change many times over the course of a game. While it has no actual effect on gameplay, it adds dynamic variety to the game.

How it works:

When a civ is created or changes their civics, they are potentially assigned a new name based on many factors. Civs spawned by either Revolution or BarbarianCiv will get temporary names indicating their status, like Mongolian Horde or Russian Rebels, until they're more firmly established. When a civ switches to Hereditary Rule their name will change to something like Kingdom of America, while under Representation or Universal Sufferage they would be the American Republic. Civs with only one city in the later stages of the game may have the city name included in their title, but their civ type will always be clarified as in the French Kingom of Paris. There are many different potential names, and even variations for civs with the same status to provide some flavor.

All of these civics determinations are made using the added Revolution flags in the civics xml file to support variations on the standard civics systems. Having a civic with the isCommunism bool set will cause Communist style names. In addition, some civs have special names like show up in certain circumstances, like the German Reich and Arabian Caliphate. These determinations are made by matching text in the civs adjective (ie German or Arabian).

This component has several features designed to support names of civs created by BarbarianCiv and Revolution, but will provides plenty of fun flavor name changes as a standalone mod or addition for other mods. It requires changes to the DLL to allow name changes to stick, but all name changes are generated in Python.

Feedback and suggestions for how to improve the names and add more variety would be great.

Download

Dynamic Civ Names (http://forums.civfanatics.com/downloads.php?do=file&id=5843)

SDK Additions

To enable civ name changing, several new functions have been added to CvPlayer and exposed to Python in CyPlayer. The most important of these is:

setCivName(std::wstring szNewDesc, std::wstring szNewShort, std::wstring szNewAdj)

This function will assign the strings passed in to their respective fields for the player, description, short description, and adjective.

This component includes all of the SDK changes from the Revolution mod. It does not need all of them, but those it does not use have no effect on gameplay. The other changes this component makes use of are augmentation of the civics XML data to easily distinguish between different types of government and other civics without being hardcoded. Check out the Revolution mod sub-forum (http://forums.civfanatics.com/forumdisplay.php?f=261) and help files in the Revolution download to learn about how to get custom civics to work with these new features.

The included DLL supports 34 civs.

strategyonly
Jun 11, 2007, 03:47 AM
I wish some of you'll who do this python stuff, would not use the square boxes at the end of a line, might be useful for some but some of us trying to figure out this stuff is almost impossible to read!! Just my opinion, is all!!

Shqype
Jun 11, 2007, 06:47 AM
This sounds very nice (and seems to be what many have been asking for). Might I suggest providing more information as to how one may alter Dynamic Civ Names. In other words, have you exposed to python a function that changes the civ's name? What XML tags have you added? Etc.

jdog5000
Jun 11, 2007, 11:54 AM
I wish some of you'll who do this python stuff, would not use the square boxes at the end of a line, might be useful for some but some of us trying to figure out this stuff is almost impossible to read!! Just my opinion, is all!!

Check out notepad++ on sourceforge or use another editor that is UNIX file format savy and you won't see those boxes anymore.

dh_epic
Jun 11, 2007, 12:23 PM
It's definitely cool that the names vary between civics.

Does the mod let you evolve from their early civilization to their modern name? Like, Arabia-->United Arab Republic (Syria) ... or Rome-->Italy, or England-->United Kingdom?

Gaius Octavius
Jun 11, 2007, 12:29 PM
I believe this one simply changes the names based on civics, however Zebra 9 is currently doing one that also changes them over time, so you get things like Germanic Tribes -> Holy Roman Empire -> Prussia -> German Empire.

Dom Pedro II
Jun 11, 2007, 01:56 PM
It's definitely cool that the names vary between civics.

Does the mod let you evolve from their early civilization to their modern name? Like, Arabia-->United Arab Republic (Syria) ... or Rome-->Italy, or England-->United Kingdom?

It doesn't currently, but you could make it do that... you would just need to establish what would be triggers for name changes... civics? # of turns?

dh_epic
Jun 11, 2007, 08:55 PM
I think the safest thing is to have an "early name" and "modern name", with the transition point being, say, Nationalism. Maybe sooner.

Rome-->Italy
Hispania-->Spain
Franks-->French
England-->United Kingdom
New England-->United States of America
Aztec-->Mexico
Maya-->Guatemala
Inca-->Peru

I figure having multiple changes would be tough, since not all civilizations are old enough to warrant multiple changes.

Edgecrusher
Jun 11, 2007, 09:03 PM
I think the safest thing is to have an "early name" and "modern name", with the transition point being, say, Nationalism. Maybe sooner.

Rome-->Italy
Hispania-->Spain
Franks-->French
England-->United Kingdom
New England-->United States of America
Aztec-->Mexico
Maya-->Guatemala
Inca-->Peru

I figure having multiple changes would be tough, since not all civilizations are old enough to warrant multiple changes.

I think thats a horrible idea. specifically the Aztec/Inca/Maya to Mexico/Peru/Guatemala. Those 3 didnt "evolve" into the later, they were taken over by the Spanish which subsequently lost control and the later were granted independence.

I love the idea of this MOD, having the names change depending on civics. Hereditary Rule = Kingdom of _______, ______ Republic, or even a unique name depending on that civilizations period in History, specifically with Russia (Soviet Union with Police State, and so on. The civilization will still be represented, those other suggestions about changing the name to something modern, seems crazy.

jdog5000
Jun 11, 2007, 11:35 PM
This sounds very nice (and seems to be what many have been asking for). Might I suggest providing more information as to how one may alter Dynamic Civ Names. In other words, have you exposed to python a function that changes the civ's name? What XML tags have you added? Etc.

Added some details to the first post.

jdog5000
Jun 11, 2007, 11:42 PM
I love the idea of this MOD, having the names change depending on civics. Hereditary Rule = Kingdom of _______, ______ Republic, or even a unique name depending on that civilizations period in History, specifically with Russia (Soviet Union with Police State, and so on. The civilization will still be represented, those other suggestions about changing the name to something modern, seems crazy.

Good! This is exactly what this mod will do, mostly civics based names with a few cultural things for flavor here and there. My feeling is each game of civ is a sort of alternative history, and so it doesn't seem appropriate to marry the names too closely to history. However, nothing is stopping someone from using the pieces from this mod to have Incans become Peruvians if it suits them.

dh_epic
Jun 12, 2007, 08:38 AM
I guess that's part of the problem. A lot of civilizations, arguably, have gone extinct, or did not exist before clear borders had developed. One suggestion was to have Germanic Tribes -> Holy Roman Empire -> Prussia -> German Empire... but if even Aztec-->Mexico becomes an issue, it's hard to imagine how you'll come up with 4 "levels" for every civilization.

Dom Pedro II
Jun 12, 2007, 08:47 AM
I guess that's part of the problem. A lot of civilizations, arguably, have gone extinct, or did not exist before clear borders had developed. One suggestion was to have Germanic Tribes -> Holy Roman Empire -> Prussia -> German Empire... but if even Aztec-->Mexico becomes an issue, it's hard to imagine how you'll come up with 4 "levels" for every civilization.

Well, although I don't like the idea of rigid historical names for civs, I'm absolutely certain you could come up with at least 4 names for each civ if you really want this in the game... I mean, virtually every civ in the game existed in a place that has been continuously occupied for thousands of years. You might have trouble if you went with "Aztec" as the first name.. you'd probably need to have the first name be one of the peoples that preceded the Aztecs.

D. Minky
Jun 17, 2007, 07:24 PM
Well, although I don't like the idea of rigid historical names for civs, I'm absolutely certain you could come up with at least 4 names for each civ if you really want this in the game... I mean, virtually every civ in the game existed in a place that has been continuously occupied for thousands of years. You might have trouble if you went with "Aztec" as the first name.. you'd probably need to have the first name be one of the peoples that preceded the Aztecs.

All you'd need to do is remove the current system of naming -- based on Nationalities -- and create one based on cultures. After all, the country "Mexico" is named for the region "Mexica," which the Aztecs and Maya both used. The "Roman" empire was just the named of an empire of many nationalities with Rome as the capital.

Now, if you had a culture-based system, you could have games with many "German" civs -- Bavarians, Prussians, Bohemians, Saxons, Franks -- who maybe need to fight eachother for the title "Germany." So once the other civs have been defeated, the remaining one could be renamed "Germany." Same goes for Italy. You could have Romans, Latins, Etruscans, Venetians, and so on, and if all are defeated, the survivor could become "Italy." Just a thought...

callicles
Jun 18, 2007, 11:20 PM
Would it be possible to make it so leaderheads change along with civic changes too? To do it properly it would take static leaderheads because it would take forever to make that many variations on animated leaderheads, but I always thought it would be neat if certain elements of the leaderheads changed depending on civics and religion type. (Say, for example, that Isabella under despotism looked more like a Barbarian Queen; when she adopts hereditary rule she looks more "dark-ages" like; when she adopts theocracy she looks close to how she looks now, etc.)

jdog5000
Jun 19, 2007, 01:45 PM
@ callicles:

Yes, it would be possible ... the easiest way would probably be to just create lots of duplicate leaderheads that just had different graphics. It might be possible to create a mechanic similar to the BTS flavor unit graphics, but that remains to be seen. However, the large art time investment will keep me from attempting it.

T_F
Aug 17, 2007, 11:43 PM
It's awesome! Can you install it separately from the Revolutions mod, maybe without all the code that allows for the BarbarianCiv and Rebellion civ names?

Bug(?) - Once I was playing against a well-established China (as a starting civ, no barbarians or rebellion) and it called them the Chinese Empire of Beijing, even though they had quite a few cities.

Also, how do you check what you are?

ewu.7waker
Aug 18, 2007, 12:41 AM
so how exactly do you add this component to a mod? sorry i'm not good with these things do i just extract the component to the mod or is there more to it?

jdog5000
Aug 18, 2007, 05:13 PM
It's awesome! Can you install it separately from the Revolutions mod, maybe without all the code that allows for the BarbarianCiv and Rebellion civ names?

Bug(?) - Once I was playing against a well-established China (as a starting civ, no barbarians or rebellion) and it called them the Chinese Empire of Beijing, even though they had quite a few cities.

Also, how do you check what you are?

Glad you like it! Not sure quite what you mean with your first question, I will post a BTS version soon. I don't really have time to pull the SDK portions out can create a separate DLL just for this, particularly because the other SDK doesn't change gameplay if not called by Revolution and BarbarianCiv python functions. The code that names rebel and barbarian civs is fairly small, and doesn't fire at all when those functions are not included.

As for the Chinese name, names are generally saved unless there's a good reason to change them. As soon as the Chinese switch to something other than Despotism, their name will change.

As for checking your own name, you should be able to mouseover your flag, next to the minimap at the bottom of the screen. I haven't added this into the BTS Revolution version yet, but it's in the Warlords version here.

so how exactly do you add this component to a mod? sorry i'm not good with these things do i just extract the component to the mod or is there more to it?

Depends very much on what the other mod is and how it works. You could simply copy over files if the other mod just changes XML files (you'd have to merge any that overlap). If the other mod changes Python code, you'll probably have to merge small bits of event handling. If the other mod has a custom DLL, then SDK source code would have to be merge and recompiled.

Note that the version posted here now works only for Warlords ... the BTS version is basically ready but I haven't pulled it out of the whole Revolution mod.

T_F
Aug 18, 2007, 05:42 PM
I will post a BTS version soon.
That's basically what I meant.

As for the Chinese name, names are generally saved unless there's a good reason to change them. As soon as the Chinese switch to something other than Despotism, their name will change.
What was weird about it was that it changed from a normal one - I didn't discover the Chinese Empire of Beijing, I discovered the Chinese Empire.

As for checking your own name, you should be able to mouseover your flag, next to the minimap at the bottom of the screen. I haven't added this into the BTS Revolution version yet, but it's in the Warlords version here.
No wonder - I was playing BtS Revolutions.

hahntsak
Oct 04, 2007, 08:37 AM
This mod doesn't seem to work with BtS. could you rework it so it does?

jdog5000
Oct 05, 2007, 03:04 PM
Sure. Will update this component for BTS 3.13.

jdog5000
Nov 07, 2007, 07:19 PM
Well, it may have taken me a long time to finally get to it, but the update for BTS 3.13 is done. You can get it from the download link in the FP.

Note that this includes Bhuric's 1.09 SDK changes by default and 34 civs by default. A few other civ counts are available here (http://forums.civfanatics.com/showthread.php?t=226032), including 18 which is necessary to support most custom maps. Just download the appropriate DLL and replace the one in the mod's assets folder.

cfkane
Dec 22, 2007, 05:58 PM
I just downloaded it and it didn't seem to work for me. I have BTS 3.13, by the way.

Leif
Dec 22, 2007, 07:41 PM
IMO it would be better to stick with simple changes [Kingdom of the Vikings, Peoples' Republic of Zulu, Aztec Republic] before moving on to several stages [Germanic Tribes - HRE - Prussia, Germany].

I can't wait to see this included in a mod!

jdog5000
Dec 23, 2007, 07:55 AM
@ cfkane:

The download should be unzipped, and the the DynamicCivNames folder placed in the BTS mods folder under Program Files (not the one in my Documents ...). You should then have an option to load DynamicCivNames as a mod under the advanced option in CivIV.

Hope that helps.

@ Leif:

This mod comp is going to stick with the 'simple' changes, so with only one or two small exceptions the Germans will always have German in their name somehow.

It's used in my Revolution mod which you check out through the link in my sig. Enjoy!

cfkane
Dec 23, 2007, 08:05 AM
I did all that.

Maybe my problem is that it's a bit difficult to check. What's the easiest way to see the civilization names? Generally you only see the leader names on the score bar and in the foreign adviser.

jdog5000
Dec 23, 2007, 02:15 PM
Hold your cursor over someone's territory that's in the fog of war, in the bottom left of the screen it will say the name of their empire. Also, with this mod when you put your cursor over their name on the scoreboard the full civ name will also appear. One last place is along the top of the diplomacy window when you're dealing with someone. The mod doesn't have too much of an effect until new civic options like Hereditary Rule and Theocracy come along.

Those are the places I know of, though you should have gotten a popup letting you know the mod was running when loading or starting a game ...

medwarth100
Jan 06, 2008, 10:51 AM
Exellent component! I'm playing Revolutions, know it from there ; )

I think it would be interesting if the name was affected by wheter or not the civ was a vassal state. For example, of a civ became a vassal state, it might by considered a "Duchy", "province" or "viceroyalty". Few kings ruled over kings you know (unless you count the sassanid kings of course (; rather off-topic )

But all in all, it could be cool to have the Ethiopian King and it vassals, the duchy of Arabia and the fief of China ;)

jdog5000
Jan 06, 2008, 04:42 PM
Yeah, good idea! Certainly works well for the middle ages/renaissance when people are running hereditary rule or even despotism.

For civs running republics etc later in the game it seems like the normal names would still be appropriate. However, I could make vassals who formed as liberated colonies carry the name "Colony of America" for a while after forming.

Glad you like the mod!

Specusci
Apr 12, 2008, 11:02 AM
Can someone re-upload the file? I get an error when I click on the download link.

hahntsak
Apr 12, 2008, 11:35 AM
http://forums.civfanatics.com/downloads.php?do=file&id=9084

that's the link. it works fine for me and I used it to get all leaders represented at once. 3 russia, 3 americas, 3 englands, 3 frances, whew.. any way hope this helps you all out.

jdog5000
Apr 12, 2008, 04:17 PM
Re-uploaded, same somewhat dated version. Will post a new version in a few weeks if there's no news on this ill-fated final patch.

hahntsak
Apr 12, 2008, 04:29 PM
coolness, thanks for the update.

BakingTheArt
Nov 02, 2008, 03:23 PM
Anything that would stop someone from playing this in Warlords? I know it refers to BtS only civs in the Python, but I could probably edit that out. Anything else?

EDIT: Aw, shucks. It has a dll file, so I can't use it on my Mac. Never mind.

The Capo
Nov 03, 2008, 01:14 AM
A few questions (which may or may not also contain indirect suggestions):

1) Is this updated to work with BtS 3.17?

2) Is this MP compatible? (i.e. will it cause crashes or OOS errors or anything)

3) If you are in a Theocracy is there mention of your state religion or is it just Holy ______ Empire or something to that effect?

4) Did you wind up changing the name of Vassals/Colonies?

5) Is there a way to make this culturally-based? Or is there any cultural basis to names? Or are they all pretty general?

6) In general, what civic is the focus on when the name of the civ is created?

7) Awesome concept, and all of the mods I've played with this in it were pretty good but I couldn't figure out the answers to these questions because I haven't played them enough times or I didn't notice.

Caesium
Nov 03, 2008, 02:25 AM
http://forums.civfanatics.com/forumdisplay.php?f=261

jdog5000
Nov 03, 2008, 12:11 PM
There will be a new stand-alone version soon, right now the mod is being translated into Spanish and I'll post it when that's done and tested.

2) It should be MP compatible, haven't tried though

3) Just Holy ... there's a limit to how long you want the names to be

4) Yes

5) A few names are civ specific, Reich or Sultanate for example

6) The government civic is the most important

Glad you like it!