City State Selection

Gurra09

Emperor
Joined
Jan 1, 2008
Messages
1,298
Location
Sweden
I like playing my Civ games with themes for the world, like for example only Native American civs or only African civs. While choosing what civs to put on a map is built-in to the game already, there is no way to choose city states other than altering the game files.

So here's a mod that let's you control what city states the game will load, and it is hopefully easier than editing the originial game files. The mod folder contains an XML file that deletes all city-states from the game. A provided readme, found in the mod folder but also in the spoiler below, tells you how to choose what city-states the game should not delete - and these will be your chosen city-states.

This way you can easily play a game that has not only just specific civs but also specific city-states. I hope someone will enjoy this. :)

This mod is made for BNW expansion. I could put together G&K and Vanilla versions if people would like that though.

Readme on how to use the mod:
Spoiler :
City State Selection is a mod to allow choosing what city states to play in your game.

In the folder for this mod you will find the CityStateSelection.xml file which contains Delete entries for all city-states.

In the top of the XML file you will see a section like this:

<!-- MOVE ENTRIES FOR CITY-STATES YOU WANT IN-GAME HERE (commented entries won't be deleted)

-->

<!-- --> means comment and any entries you put in between these will not be read by the game. This means whatever Delete entries put here will not be read by the game, and thus the game won't delete those City-States. Any Delete entries left outside the comment will be read and the game will delete those city-states for now.

This way you can choose what city-states to play with. For example, if I wanted to play an all-Native American game I would move the entries for Cahokia and La Venta inside the comment, like this:

<!-- MOVE ENTRIES FOR CITY-STATES YOU WANT IN-GAME HERE (commented entries won't be deleted)
<Delete Type="MINOR_CIV_CAHOKIA"/>
<Delete Type="MINOR_CIV_LA_VENTA"/>
-->

...and the game will delete all other city-states when I activate the mod leaving only these 2 city-states available to spawn in the game.

When you copy the Delete entries into the comment section, make sure to delete any traces of it in the other list. If you don't, the game will still see a Delete city-state entry and rule out the city-state.

**THESE CHANGES MUST BE DONE BEFORE LOADING THE MOD IN THE MODS PANEL IN-GAME**


Download
from the CivFanatics database: http://forums.civfanatics.com/downloads.php?do=file&id=22391
 
Gurra09, thank you so much for bringing this MOD, I've been looking for a similar one for quite a while now. However I'm experiencing some problems with it. I can enable it from the MODS menu, but unfortunately once I launch the game, with Gedemon's YnAEMP v22, it buggs...could you please give me more tips regarding your MOD? Do I need to delete the all the entries in the second list maybe?
Thanks so much for your time and help and wish you a great day!
 
I have downloaded this mod and customized to have only 20 City States, and it works great. Only problem is that when I am trying to play with YnAEMP it crashes.
Do you or anyone know what is the cause of this?
Here is the customized mod
 

Attachments

  • City State Selection (v 1).rar
    2.3 KB · Views: 398
Hi, first post and all. But avid mod downloader.

I really liked this idea as in some games I just want to play in a certain map with civs only Asian or Native American and it would be a little more realistic if the city states followed suit. I was looking for a mod that could do something similar to Advanced Setup (Where you can select which civs you want in the game) with City States instead.

I looked at this and love the idea. Shame you couldn't make some have some cool menu thing with it but, I suppose that's pretty advanced making a UI and all! :)

The idea of having themed city states already set up though seems like a good idea, so I copied your files, organised it alphabetically and then in themed order and tried to make different mod files to have a preset that allows 'European' or 'Asian' themed city states only. It seemed to be going well until I got to the mod menu in the game where only the custom version (that was left blank for personal preference) was visible. Need some help!!!

Attached it the zip folder with my version of the mod in, it's basically the same as the original but easier to 'look' at if you will. It's easier if you just looked at it rather than listen to someone with little knowledge deal try to explain it.

Thanks in advance!!

P.S. It's still basically the same mod but organised if you want to download it and not work on it. :)
 

Attachments

  • City State Selection Complete (v 2).rar
    10.7 KB · Views: 421
It seemed to be going well until I got to the mod menu in the game where only the custom version (that was left blank for personal preference) was visible. Need some help!!!
Did you change the mod ID in the modinfo file? The ID is generated randomly, so you can just change any hexadecimal character to another hexadecimal character (0-9 or A-F). Otherwise they're seen as the same mod.
 
Hey, thanks for the advice.

I fiddled around a bit, gave up and finally started again and managed to get it right this time! I cleaned it up and saw that it was good!
It's all done now, and it seems to work pretty damn well.

It doesn't really have the whole custom feature that was promised at the beginning, but at least this means you don't have to fiddle around with the mod folder and XML files. And if you reallllly wanted to, I reckon you could just do it anyway.
It's basically the same as the first iteration but as previously stated, does not require the changing of code.

I uploaded it on Steam, take a look if you'd rather see that there, which has more information on the mod.

http://steamcommunity.com/sharedfiles/filedetails/?id=644634937

I also decided to make it an actual download you can find on this site.
http://forums.civfanatics.com/downloads.php?do=file&id=24841

Should be good for some custom games! :)
 

Attachments

  • Only... City State Collection.rar
    8.1 KB · Views: 363
Trying to remove specific city state availability from the game: Is there something wrong with my xml?

<?xml version="1.0" encoding="utf-8"?>
<!-- Created by ModBuddy on 3/18/2016 3:04:26 PM -->
<GameData>
<!-- Delete Minor Civilization from base game. -->
<MinorCivilization_CityNames>
<DELETE Type="MINOR_CIV_ANTANANARIVO"/>
</MinorCivilization_CityNames>
<MinorCivilization_Flavors>
<DELETE Type="MINOR_CIV_ANTANANARIVO"/>
</MinorCivilization_Flavors>
<MinorCivilizations>
<DELETE Type="MINOR_CIV_ANTANANARIVO"/>
</MinorCivilizations>
<!-- Delete Minor Civilization text from base game. -->
<Language_en_US>
<DELETE Type="TXT_KEY_CITYSTATE_ANTANANARIVO"/>
<DELETE Type="TXT_KEY_CITYSTATE_ANTANANARIVO_ADJ"/>
<DELETE Type="TXT_KEY_CIV5_ANTANANARIVO_TEXT"/>
</Language_en_US>
</GameData>
 
Without trying to sell myself here, the mod I (and Gurra09 mostly) made should allow you to delete an individual city state without the need to go and make your own mod (not that I'm trying to stop you of course!).
If you download my recent version, head into: Documents, Civilization 5, MODS, 'City States - Middle Eastern Only (v 1)' file, open the XML file (same name as folder just without spaces) in either ModBuddy or alternatively Notebook - which is preferable- and just cut and paste all the other city states into the upper section (which should be well-labelled) and then remove any city states you don't want into the lower section.
It doesn't necessarily have to be the Middle Eastern one, of course.

If you want to change the name, just as easily, open the other file in the same folder and adjust the name and description!

Don't mean to step on your work or anything. Just an easier alternative to making your own mod! :)

Hope I've helped!
 
Many thanks Nutty, a big lesson learned!

Thanks for the input mattc however I have a bigger project in mind and need to get the basics right first. :)

I have a made many attempts at removing the possibility of specific city states spawning in a variety of set up conditions without success. As I don't like deleting game elements if at all possible my preference would be to set a switch for the City States I wish to remove, similar to the way Major Civilizations can be removed from the game.

<GameData>
<!-- Make Civilizations not playable by human -->
<Civilizations>
<Update>
<Set Playable="false" />
<Where Type="CIVILIZATION_AMERICA" />
</Update>
</Civilizations>
<!-- Make Civilizations not playable by AI -->
<Civilizations>
<Update>
<Set AIPlayable="false" />
<Where Type="CIVILIZATION_AMERICA" />
</Update>
</Civilizations>
</GameData>

After much research I have concluded that this is not possible, please correct me if I am wrong.

Therefore I believe that my only choice is to delete the City States in question, via an xml update to the game database when my mod is activated. All attempts at this have failed. So I have returned to first principles in an attempt to understand what I am doing wrong.

1) Clear contents in my local C:\Users\Sam\Documents\My Games\Sid Meier's Civilization 5 folder.

Cache
ModdedSaves

2) Create a simple mod to test my xml.

<?xml version="1.0" encoding="utf-8"?>
<!-- Created by ModBuddy on 3/23/2016 3:12:27 AM -->
<GameData>
<!-- Delete Minor Civilization from base game. -->
<!-- Delete Almaty. -->
<MinorCivilization_CityNames>
<Delete Type="MINOR_CIV_ALMATY"/>
</MinorCivilization_CityNames>
<MinorCivilization_Flavors>
<Delete Type="MINOR_CIV_ALMATY"/>
</MinorCivilization_Flavors>
<MinorCivilizations>
<Delete Type="MINOR_CIV_ALMATY"/>
</MinorCivilizations>
</GameData>

3) Set Mod actions to up date database OnModActivated.

4) Load Civ 5.

5) Uncheck all DLC.

6) Load minimum mods.
Ingame Editor v.39 - to view results.
Delete City States - Vanilla - containing my xml above.

7) Start game via Advanced Set Up screen.

8) View using Ingame Editor.

Almaty - City state is still present!

I would really appreciate some help resolving this problem, enabling me to get on with my bigger project.
 
@Sam the Sage, it should work as you've described it, so please open a new thread in the main Creation & Customization subforum (this isn't the right place for this conversation). We can best help you if you zip up the built mod (from your mods folder, NOT the ModBuddy project) and attach it to your post.
 
Top Bottom