Sid Meier's Civilization VI

Sid Meier's Civilization VI

CONUS Map with Navigable Major Rivers
Andre.Miksha  [developer] 31 Jan, 2020 @ 5:42pm
Real City Naming using the YnAMP model
The nuts and bolts of Real City Naming while using Yet not Another Map Pack requires the use of two files: CityMap.xml and MapText.xml. Each entry in CityMap.xml assigns a unique XML-valid value to a tile or group of tiles. The MapText.xml file then contains entries that convert those values into text.


An example from my map CityMap.xml is:
<GameData> <CityMap> <Replace Area="0" MapName="CONUS" CityLocaleName="LOC_CITY_NAME_CONUS_JAL_TAMATLAN" X="31" Y="0" /> <Replace Area="0" MapName="CONUS" CityLocaleName="LOC_CITY_NAME_CONUS_JAL_TAMATLAN" X="32" Y="0" /> <Replace Area="0" MapName="CONUS" CityLocaleName="LOC_CITY_NAME_CONUS_JAL_AUTLAN" X="33" Y="0" /> </CityMap> </GameData>
  • Area sets the radius of tiles affected. That is, zero (0) results in the name only applying to that specific tile; one (1) applies that name to that tile and the six surrounding tiles; and two (2) applies the name to the those seven tiles plus the next twelve outside the ring of six.
  • MapName corresponds to, you guessed it, the map name, which I believe is set in your Config.xml file.
  • CityLocaleName then is a unique name for that city. I kept the LOC_CITY_NAME type format. A key here is to only use standard alphanumerics -- i.e., no spaces, punctuation, special characters, accented characters, etc.
  • X and Y correspond to the coordinates of the tile.

MapText.xml contains the corresponding CityLocaleNames and provides complete text for each entry.
<GameData> <LocalizedText> <Replace Tag="LOC_CITY_NAME_CONUS_JAL_TAMATLAN" Text="Tamatlan, Jal." Language="en_US" /> <Replace Tag="LOC_CITY_NAME_CONUS_JAL_AUTLAN" Text="Autlán, Jal." Language="en_US" /> </LocalizedText> </GameData>
  • Tag is simply each unique CityLocaleName you used in CityMap.xml
  • Text is the text you want displayed. You can see here that punctuation, accented characters, etc. are fair game.

To help keep all these straight, I recommend the use of a spreadsheet with columns for, at a minimum: X, Y, CityLocaleName, and Text. It'll make the XML development a breeze!

Then, to activate these updates, the ModInfo needs:
<InGameActions> <UpdateDatabase id="NewAction"> <File>Map/CityMap.xml</File> </UpdateDatabase> <UpdateText id="YNAMP_DEFAULT_LOC"> <File>Map/MapText.xml</File> </UpdateText> </InGameActions>
Last edited by Andre.Miksha; 9 Feb, 2020 @ 6:06am
< >
Showing 1-2 of 2 comments
ZackAttack51801 29 Apr, 2020 @ 2:39pm 
Hey Andre.Miksha, I know it has been a long time since you created this discussion but I finally have the time now to create real city naming. I created a spreadsheet with all of the city names, the X and Y coordinates and the CityLocaleName I will use for my own map mod. Your guide is very helpful, it's just I don't know how to access the CityMap.xml and MapText.xml files for my WorldBuilder map. I can find it for your CONUS mod and for Gedemon's YnAMP maps but I don't know where to go for my own WorldBuilder maps. Any help would be very much appreciated. Thank you!
Last edited by ZackAttack51801; 29 Apr, 2020 @ 2:40pm
Andre.Miksha  [developer] 1 May, 2020 @ 5:01pm 
@ZackAttack51801: Have you created a mod folder for your WorldBuilder map and the naming XMLs? If not, check out the_Jack's guide to doing so in the CivFanatics' forum on the subject: https://forums.civfanatics.com/threads/a-guide-to-worldbuilder-wip.645136/#post-15440540
< >
Showing 1-2 of 2 comments
Per page: 1530 50