- Prerequisite
- Firaxis Live Tuner for civ5
- Yet (not) Another Bit Map Converter by Zobtzler (remember to thank him !)
- Yet (not) Another Maps Pack
- Civilization 6 & Civilization 5
- 1/ Launch Civ5 and a game with the map you want to convert
Spoiler Set up game :
Make sure to really Enter the game after loading (the Firetuner Lua Console is locked until you pass the presentation screen)
- 2/ Launch Civ5 Firetuner
Spoiler Firetuner :
If it's the first time you launch the Tuner, you may not have the same screen, just the "Lua Console" tab, but the others are not required for the current usage.
- 3/ Click "New Panel"
Then find and check InGame (you can resize the "Panel Builder" windows), fill the "Name" (for example "Export Map" and click "OK"
Spoiler Panel Builder :
- 4/ Click "New Control" drop down menu
Spoiler Action Builder :
Select "Action Control", set the name of the button (for example "Export to Lua"), then in the "Action" entry copy and paste the code below:
Code:
local g_iW, g_iH = Map.GetGridSize()
for iY = 0, g_iH - 1 do
for iX = g_iW - 1, 0, -1 do
local plot = Map.GetPlot(iX, iY)
local NEOfRiver = 0
local WOfRiver = 0
local NWOfRiver = 0
if plot:IsNEOfRiver() then NEOfRiver = 1 end -- GetRiverSWFlowDirection()
if plot:IsWOfRiver() then WOfRiver = 1 end -- GetRiverEFlowDirection()
if plot:IsNWOfRiver() then NWOfRiver = 1 end -- GetRiverSEFlowDirection()
local endStr =""
if plot:IsLake() then endStr = " -- Lake" end
print("MapToConvert["..plot:GetX().."]["..plot:GetY().."]={"..plot:GetTerrainType()..","..plot:GetPlotType()..","..plot:GetFeatureType()..","..plot:GetContinentArtType()..",{{"..NEOfRiver..","..plot:GetRiverSWFlowDirection().. "},{"..WOfRiver..","..plot:GetRiverEFlowDirection().."},{"..NWOfRiver..","..plot:GetRiverSEFlowDirection().."}},{"..plot:GetResourceType(-1)..","..plot:GetNumResource().."}}"..endStr)
end
end
then press "OK" and press the "Export to Lua" button you've just created. The export process can take some time depending on your computer and software, you can follow it in the Lua Console tab.
Spoiler Lua Console tab :
When it's done the last line on the Lua console should show something like
Code:
[1259235.656] InGame: MapToConvert[0][79]={5,3,0,4,{{0,-1},{0,-1},{0,-1}},{-1,0}}
- 5/Exit the game
That's an important step as the YnABMC tool will need to access civ5 Lua.log and that file is locked when civ5 is running.
- 6/ Launch YnABMC.exe
Check the advanced box, then click "Select .log File"
Navigate to your civ5 logs folder (usually "..\Documents\my games\Sid Meier's Civilization 5\Logs\"), select the Lua.log file and click "Open"
Fill the "Project Name" and "Author", then input your Mod ID (or generate a new one for a new project)
Note that if you plan to update a project you've created, you have to use the same Mod ID as the previous export, else you won't be able to load your previously saved game with the old project.
Check the options you want to see on the map setup screen then press "Generate Map"
About the TSL option, the tool will create an empty Map.xml file in your project's Map folder if you've checked the "Map Support TSL" box, but you'll need to fill it manually following the instruction here.
YnABMC can generate cliffs automatically for your map (there is no cliffs on Civ5 maps), you just need to check the "Generated" option in front of "Cliffs"
Spoiler YnABMC :
- 7/ Move your project to the Civilization 6 Mods folder
You'll find your project folder in the logs folder (usually "..\Documents\my games\Sid Meier's Civilization 5\Logs\"), you need to copy it in the Civ6 mods folder (usually "..\Documents\my games\Sid Meier's Civilization VI\Mods\")
- 8/ Launch Civilization 6
Go to the "Additional Content" menu and check that your mod is listed there and enabled. YnAMP should be enabled to.
Spoiler Additional Content menu :
- 9/ Play the map
Go back to the Main Menu, then Create a new game and select the converted map. Enjoy !
Spoiler Play ! :
Last edited: