Historical Wonders Update ?

Benthesis

Chieftain
Joined
Jun 22, 2013
Messages
12
Location
Central England
Hello All,

I am the type of player who prefers some historical accuracy/Realism in his game so i use MODS that do this such as the Native Wonders MOD, however, the creator does not come to this site anymore and has not been updated for along time and i am a man who does not know how to MOD at all other than the WB, so i was hoping a good samaritan might come along and help me with these issues.


This MOD here is called Native Wonders and all wonders in the game, ancient or Modern go to the Civ who in reality created it, or an adopted Civ if their is not that civ in the game.


http://forums.civfanatics.com/downloads.php?do=file&id=21419

Another MOD Which is really simple but i would like changing but don't know how to is the MOD Atlas Timeline which has a mask over the HUB which is at a static date for each era, i would prefer different dates and new dates for the Eras that came with G&Ks.
Ancient Era: 2584 BC
Classical Era: 71 BC
Medieval Era: 632 AD
Renaissance Era: 1511 AD
Industrial Era: 1889 AD
Modern Era: 1914 AD
Atomic Era: 1962 AD
Info Era: 2050 AD


http://forums.civfanatics.com/downloads.php?do=my

I understand it is a lot to ask when people have other things to be getting on with but if your free and looking to help someone out i'm here :)
 
Moderator Action: Thread moved to the main Creation & Customization forum, no request or question in the other subforums please :)
 
And please wait a few days before bumping.
 
If you want help on this forum, you usually have to start by helping yourself and then come back when you get stuck. There are perhaps rare exceptions where someone gets a really neat idea that inspires a modder, but this isn't that kind of request.

If you want someone to help you with Native Wonders, you should at least list where you want the new wonders to be placed.

Until then, I'll give you some help with Atlas Time Line.

Like others here, I also adhere to the "give a man a fish and you feed him for a day; teach a man to fish and you feed him for a lifetime" proverb, so I'm going to make this a tutorial.

First, you didn't need to reupload the mod. It's here, created for this mod and designed to mesh with its scale.

OK, so the change to the years is trivial. See line 9 of NewTurn.lua and line 5 of TopPanel.lua where an array of 7 years is defined.
Code:
local g_eraYear1 = {-2134, -331, 1211, 1776, 1861, 1969, 2012};
That should be an obvious fix even to the uninitiated. Make your changes, adding the eighth year.

However, you're going to run into issues because the mod was designed for an older version of the vanilla game, and the four files included are wholesale replacements for files from the base game. Some have since been patched and/or updated for G+K. Using a program like WinMerge, you can easily compare changes between revised versions of the same file.

NewTurn.lua and NewTurn.xml can be found in your CiV installation folder (something like C:\Program Files (x86)\Steam\steamapps\common\Sid Meier's Civilization V) in the Assets\UI\InGame subfolder. TopPanel.lua and TopPanel.xml can also be found in the same folder, however because they also exist in Assets\DLC\Expansion\UI\InGame, the versions in that folder will control when G+K is active.

Unfortunately, the author (Redox) didn't comment where s/he made changes. So I started out with a compare between TopPanel.lua from the mod and the one from the vanilla game, just to get a baseline without being confused by the changes that G+K introduced to accommodate the addition of the faith resource.

Opening the files in WinMerge revealed a few changes. Of course, there's the new array mentioned above. The next change occurs on line 222, where this:
Code:
		-- Update date
			
		local date = Game.GetTurnString();
was changed to this:
Code:
		-- Update date
		--local year = Game.GetGameTurnYear();
		local era = pPlayer:GetCurrentEra();
		local year = g_eraYear1[era + 1];
		
		local date;
		if(year < 0) then
			date = Locale.ConvertTextKey("TXT_KEY_TIME_BC", math.abs(year));
		else
			date = Locale.ConvertTextKey("TXT_KEY_TIME_AD", math.abs(year));
		end

Note that the commented out line (--local year...) differs from the line in the vanilla file. That calculation was revised a bit by a Firaxis patch that occured since the mod was created.

Looking through the other differences in the file, it appears that none of them are related to the mod, and occur because of other Firaxis patches. Now we can simply make a copy of the G+K version and reintroduce the changes. Of course, this is complicated a bit by the addition of the Maya and the long count date display. I'm not sure how you want to deal with them, so I just left their alternative date display alone and made a couple of appropriate changes.

The G+K version of that section of code starts around line 234. I changed this:
Code:
		-- Update date
		local date;
		local traditionalDate = Game.GetTurnString();
		
		if (pPlayer:IsUsingMayaCalendar()) then
			date = pPlayer:GetMayaCalendarString();
			local toolTipString = Locale.ConvertTextKey("TXT_KEY_MAYA_DATE_TOOLTIP", pPlayer:GetMayaCalendarLongString(), traditionalDate);
			Controls.CurrentDate:SetToolTipString(toolTipString);
		else
			date = traditionalDate;
		end
		
		Controls.CurrentDate:SetText(date);
to this:
Code:
		-- Update date
		local date;

--UPDATED FOR ATLAS TIME LINE
		local era = pPlayer:GetCurrentEra();
		local year = g_eraYear1[era + 1];
		
		local traditionalDate;
		--local traditionalDate = Game.GetTurnString();
		if(year < 0) then
			traditionalDate = Locale.ConvertTextKey("TXT_KEY_TIME_BC", math.abs(year));
		else
			traditionalDate = Locale.ConvertTextKey("TXT_KEY_TIME_AD", math.abs(year));
		end
--END UPDATE
		
		if (pPlayer:IsUsingMayaCalendar()) then
			date = pPlayer:GetMayaCalendarString();
			local toolTipString = Locale.ConvertTextKey("TXT_KEY_MAYA_DATE_TOOLTIP", pPlayer:GetMayaCalendarLongString(), traditionalDate);
			Controls.CurrentDate:SetToolTipString(toolTipString);
		else
			date = traditionalDate;
		end
		
		Controls.CurrentDate:SetText(date);

The only changes in NewTurn.lua are the additional array definition, and the update year section, so that file can remain untouched.

NewTurn.xml is identical, and didn't need to be included with the mod. TopPanel.xml is nearly identical, and I suspect that the additional line in the vanilla version was added by a patch rather than being removed by Redox.

OK, so here's a summary of what I did:
  1. In the mod's folder, rename NewTurn.xml to NewTurn.xml.bak, TopPanel.lua to TopPanel.lua.bak, and TopPanel.xml to TopPanel.xml.bak. Leave NewTurn.lua alone.
  2. Copy TopPanel.lua from C:\Program Files (x86)\Steam\steamapps\common\Sid Meier's Civilization V\Assets\DLC\Expansion\UI\InGame (or a similar equivalent if your installation folder is different) to your mod folder.
  3. Edit the new copy of TopPanel in your mod folder, changing the section at line 234 as indicated above.
  4. If you like, you can change the .modinfo to distinguish it from the original mod. If you want to make it your own, be sure to change any one of the characters in the Mod id="" section to another (0-9 or a-f) to indicate to the game that it's a different mod.

Note I haven't tested that the mod actually works...

If you absolutely can't figure this out, I'll attach the mod for you.
 
Top Bottom