How many bulbs need for the current tech ?

meifire

Chieftain
Joined
Nov 13, 2004
Messages
9
Hi everyone ! long time no see .
Maybe this is a OLD question , but how can I exactly know how many bulbs need for the current tech ?
 
Thanks . I have read that page before . But I am confused by this sav (civ dos 474.05 ).

In this sav , I am plying English for OCC , prince level . I have build library , university , and all wonders that can increase tech researching . The Trade advisor said London can build 342 bulbs per turn , and I have 36 techs already , so I just need only 361 bulbs for next tech ? Yes , the Trade advisor said I will get it in 2 turns . But in fact I get it in 3 turns , at least 684 bulbs !

Have this question be mentioned ?
 

Attachments

  • CIVIL1.SVE
    37 KB · Views: 154
  • CIVIL1.MAP
    12.7 KB · Views: 80
Thanks . I have read that page before . But I am confused by this sav (civ dos 474.05 ).

In this sav , I am plying English for OCC , prince level . I have build library , university , and all wonders that can increase tech researching . The Trade advisor said London can build 342 bulbs per turn , and I have 36 techs already , so I just need only 361 bulbs for next tech ? Yes , the Trade advisor said I will get it in 2 turns . But in fact I get it in 3 turns , at least 684 bulbs !

Have this question be mentioned ?

allow me to mention that it's extremely annoying when you put a space before dots, comma's and question marks.
 
allow me to mention that it's extremely annoying when you put a space before dots, comma's and question marks.

More annoying is to post and complain about someone's grammar and punctuation without even taking to time to respond to the actual question. Also there's no apostrophe in commas.






To the OP: Is it after 1AD? The amount of bulbs needed for a tech doubles at 1 AD which would explain your tech rate.
 
Ah Yeah ! thank you all ! I get it now .

My English is poor , I am sorry about that .
 
I was confused again .
In this sav , the year is 640 BC , I have build Colossus/library . I calculated my bulbs in every tech carefully . Until the Republic , the difficultychart on civfanatics homepage is right . Then I change the goverment to Republic , so I can produce 42 bulbs per turn . But when I researched the 18th tech , "Banking" , it took at least 5 turn/210 bulbs . Can Revenant help me again ?
 

Attachments

  • CIVIL0.MAP
    13.3 KB · Views: 150
  • CIVIL0.SVE
    37 KB · Views: 107
Using your save files as a base I assigned taxes to be 100 percent. Which made the light bulb production zero. I set the light bulb counter for the Aztec to decimal 179. I played until the end of turn no change. I Incremented the counter to 180 at end of turn nothing. Incremented the counter to 181 at end of turn and I got the advancement.

I admit this is a rather limited test but to get the advance I needed (10 X 18 = 180 plus 1) to get the advance.

I chose Mathematics as the next advance
190 light bulbs - no advance
191 light bulbs - advance took place

Astronomy
200 light bulbs - no advance
201 light bulbs - advance took place

Again very limited test results, but it seems that the calculated amount plus one is needed.
 
That "plus one" is constant and seems to be some sort of holdover from the bulb needed to bring up the advancement dialog for the first time.
 
Thank you Dack ! This is real good idea to test the bulbs need for a tech . Can you tell me which utility do you use to " set " the bulb counter ?
 
There may be more than just the "+1bulb" going on here. The question in post 3 was how did meifire fail to make a discovery in turn 2 when he had 684 bulbs - well over the 361 (including the +1) that he needed.
In my experience, if a city completes production of what it is building, it cannot make a discovery in the same turn no matter how many bulbs you have.
There are a few exceptions to this rule, but I think this is what kept meifire from making that discovery.
 
This shows how much time I’ve had for civilization this last month or so. I still had as a save file the test that I left off from in post 8. I have 201 light bulbs ready for the next advance. I selected Barracks as a city item to build and filled the production box.
At the end of the next Chiauhtia built a Barracks but no tech advance. I can only surmise that the programmer exited the City update/check/status code prematurely after finding the production box full.
As I was writing the above the thought came to mind did the light bulbs from the city get added to the light bulb counter?

I have modified the light bulb counter to 197. Also changed the tax rate to 90 percent. The new tax rate allows Chiauhtia to produce 4 light bulbs.

On the next End Of Turn one would expect Chiauhtia built a Barracks and the next advance. As Valen pointed out ”… if a city completes production of what it is building, it cannot make a discovery in the same turn no matter how many bulbs you have. There are a few exceptions to this rule…”
I was curious about this phenomenon. I ran the following test.

The attached CIVIL1 - MAP & SVE in this instance at the end of turn the Barracks will be build. The bulbs will be added. But no advance occurred.

The attached CIVIL2 - MAP & SVE shows the same situation with the addition of another city. Note the second city does not produce any light bulbs. At the end of turn, Chiauhtia built a Barracks, and then the advance is made.

A second time with CIVIL2 this time open up Chapultepec and change what is being built from courthouse to barracks. This time at end of turn both cities will build a barracks but there will be no tech advance.
 

Attachments

  • CIVIL1.MAP
    13.3 KB · Views: 100
  • CIVIL1.SVE
    37 KB · Views: 140
  • CIVIL2.MAP
    13.3 KB · Views: 74
  • CIVIL2.SVE
    37 KB · Views: 102
So, from a game play perspective, the end result seems to be as follows?

"If you absolutely need the next tech advance by the end of the current turn, make sure that your last city does not produce a city improvement during that turn."

Very interesting...
 
I can only surmise that the programmer exited the City update/check/status code prematurely after finding the production box full.

This is still possible, but it implies pollution is handled in a separate routine. A city that completes production can still pollute a square. Pollution occurs after the discovery in a city.

It's also interesting to note exceptions. If a city completes a transport, it can still make a discovery. Weird!
 
Transports are unique, if I recall. Once upon a time, they caused unhappiness, just like other military units, then later they didn't. Not sure if it's relevant, tho...
 
Transports are also built "silently". You will never see the message "Berlin builds Transport" during a city check. When the transport is completed, the city display doesn't come up.
From what I have seen, it is the opening of the dity display that prevents science.
 
I am currently looking into the following request from hannurabi:

Darkpanda, can I request you something to research in exe? I would be interest to edit the procedure that determines how many bulbs is required for the next advance.

While reverse-engineering CIV.EXE, I stumbled upon the logic that is also presented in this chart, showing how many more bulbs (the increment)[/B]are required for the player or for the AI, depending on the difficulty level.

1. What we know

With difficulty valued from 0 (Chieftain) to 4 (Emperor), the increment is computed as follows:
  • for the AI: increment = 14 - difficultyLevel
  • for the Player: increment = 6 + 2*difficultyLevel

Later in the code, we find more logic that deals with the 2x factor after 0 AD:
Code:
...
factor2x = 1;
if( currentYear >= 0 ) factor2x = 2;

if( bulbs[civID]/factor2x >= increment*techCount[civID] ) {
    // ... discover advance, reset bulbs[civID] to 0

}

Note that this condition could as well be written: bulbs[civID] >= factor2x*increment*techCount[civID], which effectively means that the increment is twice higher after 0 AD.

Thus we can list expected increment values based on difficulty level and year:

|Chieftain (0)|Warlord (1)|Prince (2)|King (3)|Emperor (4)
AI increment (BC)|14|13|12|11|10
Player increment (BC)|6|8|10|12|14
AI increment (AD)|28|26|24|22|20
Player increment (AD)|12|16|20|24|28

But wait a second... between these 2 pieces of code, there is some more logic that is actually affecting the computation of bulbs!

2. First discovery

After initial calculation of the increment following the first formula above, and evaluating the condition, a mysterious value is added to the increment, which I have called additionalRequiredBulbs.

This value, additionalRequiredBulbs, is re-computed every 50 turns after 0 AD, as part of the main game loop, with the following formula:
Code:
additionalRequiredBulbs = maxTechCounter - gameTurn/9;
if(additionalRequiredBulbs<0) additionalRequiredBulbs=0;
if(additionalRequiredBulbs>6) additionalRequiredBulbs=6;

In the code above, maxTechCounter is the maximum number of techs discovered by any Civ so far.

Let's recall the equivalent between turns and years:
  • Turns 0 to 250 (4000 BC to 1000 AD): 1 turn = 20 years
  • Turns 250 to 300 (1000 AD to 1500 AD): 1 turn = 10 years
  • Turns 300 to 350 (1500 AD to 1750 AD): 1 turn = 5 years
  • Turns 350 to 400 (1750 BC to 1850 AD): 1 turn = 2 years
  • Turns 400 onwards (after 1850 AD): 1 turn = 1 year

We can ignore everything before 0 AD, which corresponds to turn 200.

At 0 AD, it is the first time that additionalRequiredBulbs is computed. At that time, turn/9 = 200/9 = 22. That means if any Civ has discovered 23 or more techs, then the increment will be modified, and will keep its value for the next 50 years.

If we imagine that the player knows the most, with 23 techs, the increment will increase by 1, but since we're at 0 AD (or after), it really means an additional 2 bulbs required per known techs. Since the player knows 23 techs already, that means at least 2*23 = 46 more bulbs will be necessary to discover the 24th tech !

And if any Civ knows 28 techs, the increment will increase by 12 (2*6), leading to an incredible 336 additional bulbs required for that Civ to discover its 29th tech !

Honestly, I never cared to hold a detail accounting on bulbs and techs when playing Civ, but these numbers look quite astonishing to me, and I wonder if anyone would care to put them to the test... I'd like to highlight I discovered this in version 474.01, and this may have been altered in subsequent versions.

Similar logic applies every 50 years after this:
  • After 1000 AD, turn 250, the base increment will be increased if any Civ has more than 250/9 = 27 techs
  • After 1500 AD, turn 300, the base increment will be increased if any Civ has more than 300/9 = 33 techs
  • After 1750 AD, turn 350, the base increment will be increased if any Civ has more than 350/9 = 38 techs
  • After 1850 AD, turn 400, the base increment will be increased if any Civ has more than 400/9 = 44 techs

3. Second discovery

After adding additionalRequiredBulbs to the increment, CIV makes an extra step just for the player, that may completely override the increment:
Code:
if( 11 - techCount[playerCivID] > increment ) {
    increment = 11 - techCount[playerCivID];
}

This one is summed up as follows: the fewer techs the player has (below 11 techs), the more bulbs he will require for the next tech. Somehow this seeks to mitigate the conditions at game start, I suppose, but I really don't find it straightforward.

That's it for now, I'll come with more details, if any come up.
 
So, Mize referred this thread not so long ago. For some reason, I did not read it before or I forgot about its existence. So.

1) darkpanda made a mistake about "every 50 turns". This condition is for replay data and this IF/ELSE already ended at the moment. "Special bulb multiplier" re-calculates every turn (after 1 A.D.). "every 50 turns" condition is CORRECT. Meaning of this rule is simple: tech development should be more "natural" and "not too fast". Also this rule is another reason why you should force science _before_ A.D.. Besides "x2 bulbs" rule.

2) on chieftain, if tech was discovered by some civ before, you get +100% bulbs from every city. This effect is not taken into account on F5 screen. Btw, chieftain difficulty has many special rules, sometimes it can feel almost like different game altogether. Did you know that AI actually disbands their units around your cities after peace treaty signed on chieftain difficulty?

3) with SETI you get +50% bulbs from every city (with previous chieftain effect it will be +150% total). But in F5 screen required bulbs are reduced instead (-1/3): result is more or less the same.

4) yes, there's special rule for some very first advances. Actual numbers according to this rule: on chieftain, 11 bulbs for 1st tech (1+10), 19 for 2nd (+8), 25 for 3rd (+6), 29 for 4th (+4) and 31 for 5th tech (+2 bulbs). 5 tech total with special formula. After that, normal bulb formula is used (+6 bulbs for every tech). On warlord: 11 bulbs for 1st tech, 19 for 2nd (+8) and 25 for 3rd (+6). 3 tech total with special formula. After that, normal formula is used (+8 bulbs per tech). On prince: 11 bulbs for 1st tech (1 tech total with special formula), after that normal formula is used (+10 bulbs per tech). For king and higher, special formula is not used at all. On king: 13 bulbs for 1st tech, after that +12 bulbs per tech. On emperor: 15 bulbs for 1st tech, after that +14 bulbs per tech.
For computer player formula is just +14-difficulty bulbs per tech.

5) after 1 A.D., bulbs needed for discovery is doubled for all players, and their current bulbs are doubled too. So number of turns for discovery is doubled on F5 screen after 1 A.D.. This rule applies after multiplier in (1).

6) your starting advances, of course, are not counted in your tech counter. That's why Pollution Bug can happens on slightly different Future Tech, btw.

7) on chieftain difficulty, there's 1/2 chance, that AI will not discover new tech, if tech which it selected is not discovered by human player yet.

8) AI civ changes production in all its cities after new discovery
 
Last edited:
tupi, thanks a lot for these notes! Really helpful to correct the big picture of the Civ1. But for the Chieftan it was just a true discovery for me...Never thought that it is so different. I would just recall another special thing of Chieftan: you may choose to research any possible advance when choose new research. At higher difficulties you skip some advances according to the law 0-1-2. This law is so redundant one hand...but one other hand it adds so special flavour to the game. And if you note that it was done in 1991 then it was really brilliant move by Sid! Viva la Civ1! BtW, still cannot beat "standard" OCC Emperor, also TwoCC and ThreeCC looks fun too (King just chages timing and other things so much).
 
Top Bottom