So was Game.ChangePlayerEraScore function REMOVED?

Windflier

Chieftain
Joined
Dec 15, 2017
Messages
39
I was calling this function in my latest mod, but the lua log keep saying the line "Game.ChangePlayerEraScore(playerID, amount)" as "function expected instead of nil"
I was playing on the GS ruleset, so it's no way I don't have the era score functions.
So did this function get removed? if so, is there another function to adjust player's era score?
 
I get the same error when I test for it, so apparently the function was removed from the "Game." methods.

It may have been removed completely or it may have been moved to a "Player:" method. But Firaxis don't send us documentation on what was removed or moved so all you can do is try alternative methods something like
pPlayer:ChangeEraScore(Amount)
 
I get the same error when I test for it, so apparently the function was removed from the "Game." methods.

It may have been removed completely or it may have been moved to a "Player:" method. But Firaxis don't send us documentation on what was removed or moved so all you can do is try alternative methods something like

So, after looking into the FireTuner, I found out the function has been changing into Game.GetEras():ChangePlayerEraScore(playerID, amount)
I don't know why they changed that, but fortunately we can found it out. The Lua Object table is outdated, hope someone can update it.
 
Forgive necropost, has anyone found a way to display erascore on tuner page?

I have been able to add a few using the existing panel controls as a guide, but Era Score is the only one I havnt got to work yet.

For example. I found Gold Bal (was already there)
Code:
  return Players[g_TunerSelectedPlayer]:GetTreasury():GetGoldBalance();

and figured out Gold Yield, and did the same with faith and culture.

Code:
  return Players[g_TunerSelectedPlayer]:GetTreasury():GetGoldYield();

Using the pre-existing +/- Era Score Controls I tried to get a label to show current era score like with everything else but have had no luck.
Tried:
Code:
  return Players[g_TunerSelectedPlayer]:Game.GetEras():GetPlayerEraScore();

Here is screenshot of my tweaked panel with everything else working.
Spoiler :

e9DnOyr.png

 
Back
Top Bottom