Single Player bugs and crashes v37 plus (SVN) - After the 24th of December 2016

I agree, do what you gotta do to update the variant speed games, but I can play on 9494 until that comes out. No need to revert stuff unless it's absolutely necessary.
 
I'd rather keep the more streamlined math that TB introduced, and readjust the tags instead.

Why? It's not more streamlined and it will not do the job in this area.

Disclaimer: This is just my Observations from doing all the balancing of the GS and Mod balance and is also My Personal Opinion. Others may not like what I have done to GS and have will have differing opinions.
 
It is more streamlined because world size and other things that affect research times will not amplify or reduce the effect gamespeeds have on research times.

To make this example as simple as possible I will only consider world size and gamespeed research modifiers.
Lets say a tech has a base cost of 1000 :science:.
Old Math:
Scenario 1 - You have a Huge size map that modify it by 150%
So the tech cost is now 1500
  1. Normal game-speed modifies it by 250% and the tech cost ends up at 3750 :science:
    • The tech cost has increase by a factor of 3.75
  2. Eternity game-speed modifies it by 2100% and the tech cost ends up at 31500 :science:
    • The tech cost has increase by a factor of 31.5
  • Game-speed factor difference = 31.5 - 3.75 = 27.75 (WTH eternity has 27.75 times longer research times than normal game-speed)
Scenario 2 - You have a Standard map size that modify it by 100%
So the tech cost is now 1000
  1. Normal game-speed modifies it by 250% and the tech cost ends up at 2500 :science:
    • The tech cost has increase by a factor of 2.5
  2. Eternity game-speed modifies it by 2100% and the tech cost ends up at 21000 :science:
    • The tech cost has increase by a factor of 21
  • End conclusion game-speed factor difference = 21 - 2.5 = 18.5
New Math:
Scenario 1 - You have a Huge size map that modify it by 150%
  1. Normal game-speed modifies it by 250%, so the total modifier is now 300%,and the tech cost ends up at 3000 :science:
    • The tech cost has increase by a factor of 3
  2. Eternity game-speed modifies it by 2100% and ends up at 21500 :science:
    • The tech cost has increase by a factor of 21.5
  • End conclusion game-speed factor difference = 21.5 - 3 = 18.5
Scenario 2 - You have a Standard map size that modify it by 100%
  1. Normal game-speed modifies it by 250%, so the total modifier is now 250%, and the tech cost ends up at 2500 :science:
    • The tech cost has increase by a factor of 2.5
  2. Eternity game-speed modifies it by 2100%, so the total modifier is now 2100%, and ends up at 21000 :science:
    • The tech cost has increase by a factor of 21
  • End conclusion game-speed factor difference = 21 - 2.5 = 18.5
-----------------------------------------------------------------------------------------------------------------------------------------
Incidentally, the difference between the <iResearchPercent> used in eternity and normal game-speed is (2100 - 250 = 1850) a factor of 18.5
Research modifiers from world size or elsewhere should never make eternity have tech costs that are 27.75 times bigger than if you had played on normal game-speed!!!!!!!!!!!!!!!!!!!!!!!!!! lol ^^
 
Last edited:
Yeah, I had a feeling something was wrong with the tech cost. As I've said before, my game is like 2000 years behind the historical version of things. AI and player alike...

But does this mean that the version after 9495 is the correct one? I mean there's a massive difference in tech cost between rev. 94 & 95...
 
Yeah, I had a feeling something was wrong with the tech cost. As I've said before, my game is like 2000 years behind the historical version of things. AI and player alike...

But does this mean that the version after 9495 is the correct one? I mean there's a massive difference in tech cost between rev. 94 & 95...

rev. 9495 had a serious bug unrelated to the new and old math formula. The bug was fixed in rev. 9504.
 
I know, didn't change anything for my game. If you go back a bit you will see the conversation I had with Joseph about it.
Your conversation with Joe did not reveal to me that rev 9504 was just as bad as rev. 9495... If this is the case then there is still something really wrong with the math and TB would have to look at it again.

The new math TB tried to implement would have increased or reduced tech cost somewhat depending on what game options you use, but a research time reduction from 30 rounds to 3 means something is really wrong.
 
It isn't from 30 turns to 3, but based on sci point value more like 30 turns to 6. I've quoted both messages so it's quite clear what I've tested and what the exact problem is. I'm really just interested in whether this works as intended now, before I update my game to the latest revision.

I've installed SVN 9504, run the recalc and the tech cost is still bugged. No change from earlier...

Well, I can say this much for certain: At some point after 9494, the tech cost of Classical Lifestyle in my eternity nightmare game went from 83505 pts to 16821 pts. I just reverted the game to 9494 and it works as it did before.


EDIT: Yeah, I double-checked and it's definitely 9495 that makes this change... Classical lifestyle on eternity, nightmare, has gone from costing 83505 to 16821. And the same incremental drop for all other techs (at a glance).

I can't say if it's a bug or an improvement... It would definitely make the game faster. I mean I am around 1300 AD and all of us, AI and player, are only just heading into classical civilization, which is behind by like 2000 years give or take a few hundred years, historically.
 
It is more streamlined because world size and other things that affect research times will not amplify or reduce the effect gamespeeds have on research times.

To make this example as simple as possible I will only consider world size and gamespeed research modifiers.
Lets say a tech has a base cost of 1000 :science:.
Old Math:
Scenario 1 - You have a giant size map that modify it by 150%
So the tech cost is now 1500
  1. Normal game-speed modifies it by 250% and the tech cost ends up at 3750 :science:
    • The tech cost has increase by a factor of 3.75
  2. Eternity game-speed modifies it by 2100% and the tech cost ends up at 31500 :science:
    • The tech cost has increase by a factor of 31.5
  • Game-speed factor difference = 31.5 - 3.75 = 27.75 (WTH eternity has 27.75 times longer research times than normal game-speed)
Scenario 2 - You have a Standard map size that modify it by 100%
So the tech cost is now 1000
  1. Normal game-speed modifies it by 250% and the tech cost ends up at 2500 :science:
    • The tech cost has increase by a factor of 2.5
  2. Eternity game-speed modifies it by 2100% and the tech cost ends up at 21000 :science:
    • The tech cost has increase by a factor of 21
  • End conclusion game-speed factor difference = 21 - 2.5 = 18.5
New Math:
Scenario 1 - You have a giant size map that modify it by 150%
  1. Normal game-speed modifies it by 250%, so the total modifier is now 300%,and the tech cost ends up at 3000 :science:
    • The tech cost has increase by a factor of 3
  2. Eternity game-speed modifies it by 2100% and ends up at 21500 :science:
    • The tech cost has increase by a factor of 21.5
  • End conclusion game-speed factor difference = 21.5 - 3 = 18.5
Scenario 2 - You have a Standard map size that modify it by 100%
  1. Normal game-speed modifies it by 250%, so the total modifier is now 250%, and the tech cost ends up at 2500 :science:
    • The tech cost has increase by a factor of 2.5
  2. Eternity game-speed modifies it by 2100%, so the total modifier is now 2100%, and ends up at 21000 :science:
    • The tech cost has increase by a factor of 21
  • End conclusion game-speed factor difference = 21 - 2.5 = 18.5
-----------------------------------------------------------------------------------------------------------------------------------------
Incidentally, the difference between the <iResearchPercent> used in eternity and normal game-speed is (2100 - 250 = 1850) a factor of 18.5
Research modifiers from world size or elsewhere should never make eternity have tech costs that are 27.75 times bigger than if you had played on normal game-speed!!!!!!!!!!!!!!!!!!!!!!!!!! lol ^^

Nice write up Except, This is Only what the Factors are at Game start. As the game progresses thru the Eras the players research points out pace the "Factor" you display here. So it shrinks, ever faster and faster. And yes you would think that a 27.75 is too large. Guess again! It's not even enough for the Preh Era alone. And as an aside, I got royally *****ed at by Eternity players because Research was tooooooo fast at game start. Yeah that's right too fast.

So I had to start using the BBAI tech cost modifier And the Era related Modifier to keep the pace even somewhat close to what Preh Era had. And I had to ask for player input inthe Game Speed thread because I could not run enough test games to cover all the Option variables. But even then Diety players were having their own cows over it being too fast as well.

I spent months on this. Test game after test game on All Game Speeds with and w/o Tech diffusion (which really screws the numbers up even worse) to get it where it was, before T-brd's changes made a dumpster fire out of it.

Another side note: With Tech D Off and T-brds new WFL Option ON the WFL acts just like TD Except you don't have to meet any other Civs to get it's benefits! Especially at game start. Started a Snail game on Noble, large, PM map today to test DH's complaint, I was getting +7 from WLF to my initial Research rate of 11 from my start location by the time I popped my 1st set of adjacent tiles from the main city tile (I city tile start was On). By the time I was researching column x4 and x5 the tech research times were down from 7 turns to 3 and 4. DH was complaining his research had dropped from his preferred times of 16 turns to 6.

So while you think it's simple straight forward progression that T-brd's math should help, it is anything but.

And as I have posted eslewhere the Game Speed modifiers in All categories have to be the Highest level Modifiers, on par with Global Defines. With the modifiers In EraInfo the 2nd highest. OR someone can do a complete Redo of all TECH COSTs in the TechInfo xml, all 800+ of them. And then someone can test them to see if they come close. Any volunteers???
 
Nice write up Except, This is Only what the Factors are at Game start. As the game progresses thru the Eras the players research points out pace the "Factor" you display here. So it shrinks, ever faster and faster. And yes you would think that a 27.75 is too large. Guess again! It's not even enough for the Preh Era alone. And as an aside, I got royally *****ed at by Eternity players because Research was tooooooo fast at game start. Yeah that's right too fast.
With the new math the game-speed factor would be constant regardless of game progression and game options used.
It is impossible to balance research cost between game speeds with the old math because the factor keeps changing throughout the game.

New math: eternity techs cost are always 18.5 times higher than what they are at normal gamespeed troughout the game.
Old math: eternity techs cost are X times higher than than what they are at normal gamespeed, X changes throughout the game based on what other research modifiers are in effect, it is hard to say what X is and who knows what the top and low limits are for X at this moment.
The top limit is probably far higher than 27.75, because it would get bigger the more tech cost modifiers are in effect, I only considered world size.

Do you really want this?
So I had to start using the BBAI tech cost modifier And the Era related Modifier to keep the pace even somewhat close to what Preh Era had. And I had to ask for player input inthe Game Speed thread because I could not run enough test games to cover all the Option variables. But even then Diety players were having their own cows over it being too fast as well.

I spent months on this. Test game after test game on All Game Speeds with and w/o Tech diffusion (which really screws the numbers up even worse) to get it where it was, before T-brd's changes made a dumpster fire out of it.
Yes, it does ruin a lot of your work on tech cost, but I believe it is a necessary change for us to reach an even more balanced mod.

So while you think it's simple straight forward progression that T-brd's math should help, it is anything but.
Sure tech cost are probably off right now, but should we all stop working on the mod because it might unbalance it to do anything?
TB's adjustment should help when XML values have been readjusted for the new and sane math instead of for the old and insane math.

OR someone can do a complete Redo of all TECH COSTs in the TechInfo xml, all 800+ of them. And then someone can test them to see if they come close. Any volunteers???
Would be easier to adjust <iTechCostModifier> in era xml instead.
 
Last edited:
It isn't from 30 turns to 3, but based on sci point value more like 30 turns to 6. I've quoted both messages so it's quite clear what I've tested and what the exact problem is. I'm really just interested in whether this works as intended now, before I update my game to the latest revision.
Didn't realize it was that far back, I should have looked better, sorry.

I'm not sure if it works as intended yet. ^^
 
I was going to quote a bunch of stuff here and reply with a 'case' but I do understand the frustrations.

I'm pretty certain my math is accurate now. Toffer is also making every point I was going to make and you'd really have to read the math examples closely to understand it. The examples we've given don't add up to the dramatic 'problems' that the original system presented. But the difference in correcting the math certainly does. I get that at the moment, the end result does not appear to be a debug, nor is it an improvement.

And it does make a bit of an incidental bonfire out of the finely measured adaptations that have had things dialed in to near perfection.

But here's the messed up thing... it was dialed in to near perfection on a mechanism where, without a complete understanding of the order in which modifiers were being added, you could never calculate out what you were going to get with the numbers you were using. The change this introduces is to make it possible for you to actually hand calculate the end results of tech costs based on the variables you are working with.

I know that may not seem like much of an advantage when you've had everything perfect and it gets shattered by a change in the machinery. But we're constantly changing things here in various measures on the surface so just how long is our current perfection going to be maintained?

We're about to have a new cost assignment chart for techs and yes, almost all techs are going to have to get a new reassignment of base tech costs anyhow. Mind you, I wasn't planning a dramatic change to the base, just making sure the progression now matched the changes to era shifts on the x grid and the new length of the x grid and so on. And I also get that this doesn't help the immediate now to resolve things either.

I have seen, in game, some comparisons between old and new tech costs and yeah, it's pretty dramatic.

So we have a quandry. And again, let's be clear, this has very little to do directly with the new options. I'll address what was brought up about that in a moment.

To resolve,
I can revert the method:
Pros:
We'll still be currently fairly dialed in as to what our end result tech costs should be by all optional factors.
Cons: It's going to make rebalancing after changes start to corrupt that fine tuned balance a real pain. You won't be able to directly calculate the end result without a much more intensive set of calculations based on deep knowledge of the hierarchy of modifiers as established in the code. I CAN deliver that knowledge to the Modder's Documentation so you don't have to be a coder to sort it out. BUT do you want to have to make 10 calculation steps to come to a final conclusion as to what the tech costs should be for various options?

I can leave it as is:
Pros:
When you apply a modifier, it applies directly to the base amount the same no matter what the source of the modifier may be. A Gamespeed modifier will apply exactly the same to a base value as a Handicap (game difficulty) modifier. This if you have a base cost of 100 and you apply a 30% modifier (as 130 in the xml) to the Gamespeed and a 50% modifier (as 150 in the xml) to the Handicap, you will get a total of a 180% modifier. This is very easy to then see the final results WILL be a total of 180 research cost for that tech. The current way would require knowing which modifier applies first to find out the end result. We have something like 8 modifier sources... trying to keep the order of those in mind to come up with the end total would be hell. So just how much control do we really have under the old method?
Cons: It will completely bork all game balance we've achieved so far in the rate of tech achievement and require a complete re-evaluation of the modifiers from all sources of modification. To get us back to the balances we were at up to now, some modifiers will seem to be requiring incredibly dramatic numbers. I totally respect the perspective that this adjustment is not helpful if you've become very comfortable working with the numbers the way they were.

I personally lean towards the second because it's the technically 'right' way to go about it. But I also understand the massive frustration (and admission that the current game structure is totally screwed up until a complete rework of a LOT of stuff) that presents. It's too bad it was all setup incorrectly to begin with is all I can say.


As for:
Another side note: With Tech D Off and T-brds new WFL Option ON the WFL acts just like TD Except you don't have to meet any other Civs to get it's benefits! Especially at game start.
It will have a major impact when you fall behind the AI in population right away, sure. So on harder handicaps, it's quite possible you'll get a pretty immediately visible benefit from it. If you're the one leading in population and city counts, however, you'll not get any benefit from it. It does not offer any nation a penalty because penalties are perceived as 'unfun'. So it's all positive and only for nations falling behind the leader in population and/or city count. This is very different to the technical function and purpose of TD but not so much in perception of the system when you are benefiting from it.

However, I recognize the manner in which TD and WFL can have an impact on date matching. For that reason, we might want to add an additional cost modifier for all techs if TD and/or WFL is on if we want to help those systems to compensate to match the dates a little better. If we make them all a little more expensive, that can help to balance out the fact that across the globe, most nations are getting some form of benefit from these handicap systems.

Of course, Tech Trading has a far more dramatic impact on trying to match tech dating as well, so that would also qualify as another massive headache that makes it very difficult for eras after trading is introduced to be balanced against.


I have just been running the XMLValidator program by Koshing over some of the C2C folders, I was trying to find a strangeness in one of my files. I found a whole heap of problems, mostly due to the schema not being pointed to correctly and I will post the fixes for all of them to the SVN shortly. However there were 2 which weren't in mods I have worked on and I am not sure what needs to be fixed.

Code:
eValidating files in the current directory and all subdirectories
F:\Games\Firaxis Games\Sid Meier's Civilization 4\Beyond the Sword\Mods\Caveman2Cosmos\Assets\Modules\My_Mods\Neanderthal_Units\Neanderthal_Units_CIV4UnitInfos.xml:2260,6: The 'x-schema:Neanderthal_Units_CIV4UnitSchema.xml:NotUnitAI' element is not declared.
-----------------------------------
F:\Games\Firaxis Games\Sid Meier's Civilization 4\Beyond the Sword\Mods\Caveman2Cosmos\Assets\Modules\My_Mods\New_Cultures\XML\Heroes_CIV4UnitInfos.xml:34867,5: The 'x-schema:New_Cultures_CIV4UnitSchema.xml:iBaseFoodChange' element is not declared.

Someone else needs to look at these as fix them, probably after I get the other fixes up there as I did fix some of the Neanderthal_Units files.
All that needs to happen is to update these schemas. This, I think anyone can do right? The schemas in the core are what all schemas should look like... it's just that they get outdated and then checks like this show that there could be real bugs due to letting them get out of date. I'll try to update these ones if someone else hasn't gotten to them by this evening.
 
Didn't realize it was that far back, I should have looked better, sorry.

I'm not sure if it works as intended yet. ^^
The way it is now, it shouldn't be too hard to look at the modifiers and actually do the math by hand and see exactly how it gets to the tech costs as shown in any existing game to test the accuracy. The only modifier that doesn't zero at 100, but rather at 0, is the new Beeline Stings modifier.

The discord we are seeing now is proving our point as to how dramatically skewed the old system was forcing things to be. You had to play it by ear and zero in by feel like twisting analog dials rather than by digital math.


It occurs to me that it might be pretty easy to fix all this up through the modifiers by looking at the tech trees of various games and their settings and charting out the end costs of the techs under the older, reverted SVN, so we know what the DESIRED end results should be. Then we have some understanding of what the end results we want are and we can better rig the modifiers to get us there rationally.
 
Unfortunately I did not keep a save of my game as I felt it was too broken. I was the first to reach Sedentary Lifestyle so was the Tech leader and yet the Classical Era techs were costing between 10 and 13 turns less than they should on snail speed.

All that needs to happen is to update these schemas. This, I think anyone can do right? The schemas in the core are what all schemas should look like... it's just that they get outdated and then checks like this show that there could be real bugs due to letting them get out of date. I'll try to update these ones if someone else hasn't gotten to them by this evening.
I tried that on the Neanderthal one and it did not work. There is a tag wrong or missing. I found that in a couple of other files. I was just to tired to continue which explains how come I uploaded my A_New_Dawn_GlobalDefines when I should not. If someone could revert that file that would be good. It is all meetings for me today starting in 5 mins...
 
I started two test games at normal and eternity game-speed and looked at the math for all instances of iResearchPercent and found that tech costs now works as TB intended, the math is correct.
Nice work TB, finally it works as it should.

Conclusion of my test:
Game-speed iResearchPercent is now too low for all game-speeds.

Since normal gamespeed is already adjusted to 250% I would suggest tuning it down to 100% and
use the Era <iTechCostModifier> to increase all tech costs for all eras by an additional 200%.

Why reduce normal gamespeed, because it didn't seem that off by the recent change and because it would be good to balance the mod with a standardized baseline for the normal gamespeed.
I want normal gamespeed to have 100% for as many of its modifiers as possible, and rather tweak the cost elsewhere to balance out the normal gamespeed.

@JosEPh_II: Do you want to work on tech costs from here? You are free to disregard my above suggestion.

I could do some rough initial adjustments if you don't feel like working on this for a while.
 
Last edited:
I tried that on the Neanderthal one and it did not work. There is a tag wrong or missing. I found that in a couple of other files. I was just to tired to continue which explains how come I uploaded my A_New_Dawn_GlobalDefines when I should not. If someone could revert that file that would be good. It is all meetings for me today starting in 5 mins...
Ah... ok. Interesting. The stranger thing still is that the debug dll doesn't catch it. I'll look later as time permits.

Nice work TB, finally it works as it should.
Thank you T! I appreciate you verifying that for me because I checked and rechecked to make sure and when I saw the resulting tech costs I, too, had to wonder if I was going nuts or if it really was that dramatically skewed by the old system of ladder modifiers.

Conclusion of my test:
Game-speed iResearchPercent is now too low for all game-speeds.

Since normal gamespeed is already adjusted to 250% I would suggest tuning it down to 100% and
use the Era <iTechCostModifier> to increase all tech costs for all eras by an additional 200%.

Why reduce normal gamespeed, because it didn't seem that off by the recent change and because it would be good to balance the mod with a standardized baseline for the normal gamespeed.
I want normal gamespeed to have 100% for as many of its modifiers as possible, and rather tweak the cost elsewhere to balance out the normal gamespeed.
That's probably a very good analysis.

The reason to do it that way with gamespeeds is that we can get a very direct % adjustment measurement of the ratios we intend for gamespeeds which SHOULD make the application of the modifiers there as straightforward and obvious as it should be. It finally makes sense to me why it couldn't be as direct as I figured all this time.
 
Yes, it does ruin a lot of your work on tech cost, but I believe it is a necessary change for us to reach an even more balanced mod.

I'll defer to the more skilled modders.
@JosEPh_II: Do you want to work on tech costs from here? You are free to disregard my above suggestion.

I could do some rough initial adjustments if you don't feel like working on this for a while.

Not sure Which suggestion you are referring to to disregard? As for some "rough initial adjustments" go for it.

I can leave it as is:
Might as well.
It will have a major impact when you fall behind the AI in population right away, sure. So on harder handicaps, it's quite possible you'll get a pretty immediately visible benefit from it. If you're the one leading in population and city counts, however, you'll not get any benefit from it. It does not offer any nation a penalty because penalties are perceived as 'unfun'. So it's all positive and only for nations falling behind the leader in population and/or city count. This is very different to the technical function and purpose of TD but not so much in perception of the system when you are benefiting from it.
You failed to see my point. Is it your intention for this Option to work like TD when you have Met No Other civ?

All this does is boost the research for all players at game start but the one that has the best starting spot. You do understand that right? Or will you not understand me again and go off on another tangent?

If you don't care that it's Free research points with out any contact then Okay! Why do we need TD now? You effectively replaced it.

JosEPh
 
You failed to see my point. Is it your intention for this Option to work like TD when you have Met No Other civ?
Yes. It is intended for TD to be contingent on interactivity with other nations while WFL is only using other leading nations to set a pace for expansion success, whether you know them or not.

Tech Diffusion is a system to model the bleeding over of knowledge from one nation to another. Win for Losing is a game handicap method that seeks to help to replicate the fact that in realworld situations smaller nations do not necessarily fail to produce major breakthroughs or stay on the cutting edge of research, perhaps even benefiting from their smaller stature because the citizens all feel more like they play a direct role in contributing to the nation individually.

These are two different and compatible system structures with different purposes and addressing different handicap needs but ultimately their benefits are received in a similar manner. That said, WFL is intended more as a GAME handicap factor to keep smaller nations more competitive with larger ones, while TD is more of a logical absorption of knowledge from other nations.

All this does is boost the research for all players at game start but the one that has the best starting spot. You do understand that right? Or will you not understand me again and go off on another tangent?
If you define the best starting spot as the one that provides the most growth then you are correct. It can also mute the penalties of a harder gamespeed a bit - particularly at the beginning, but in the end, it's ultimately a way of dragging down the leading player, whoever that is... and in a way that makes the leading player not FEEL like he's being dragged down because it does so by boosting the others instead.

If you don't care that it's Free research points with out any contact then Okay! Why do we need TD now? You effectively replaced it.
TD helps players catch up to the tech leader when they have fallen behind in research. It stops working when you've caught up.
WFL gives a handicap to players who have fallen behind in size and population. It can make a smaller nation more powerful than a larger one by giving them this handicap to help them get ahead in technology, which can help them gain the military edge to capture land from the larger player or at least relieve them of the NEED to invade to catch up, which can be very supportive for non-warfare centric games.

With both in play, you have a very strong system of handicaps that should help most players stay competitive. For human players that have a hard time not getting out ahead and staying way ahead, this can make the game much more enjoyable.
 
Last edited:
Not sure Which suggestion you are referring to to disregard? As for some "rough initial adjustments" go for it.
I was referring to this suggestion:
Toffer90 said:
Since normal gamespeed is already adjusted to 250% I would suggest tuning it down to 100% and
use the Era <iTechCostModifier> to increase all tech costs for all eras by an additional 200%.

I'll see if I can look at tech cost modifiers tomorrow. It's getting late.
 
Back
Top Bottom