Announcement

Collapse
No announcement yet.

The game mechanics, formulas and constants

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #16
    Thx guys.

    Originally posted by Martin Gühmann
    In the Great Library you should find that there are wonders and buildings that reduce crime. You can find the stuff in the text files, too. And of course in the source code.
    I mean the formulas - I suppose they are neither in GL nor in .txt files - so the source code is the only source? My question is if there are similar posts like Locotus' formula about use of food from squares (there is a link in my first post here) but about different scopes (like crime).

    Originally posted by Martin Gühmann
    You need to construct buildings that increases happiness like shrines and theaters.
    I thought happiness improvements icrease happiness rather than allow to get over some limit...
    What constant determines the limit? I know RIOT_LEVEL, TooManyCitiesThreshold, MartialLawThreshold but they don't cause this limit probably ...

    But why maxing out happiness, as long as it is over the 73 the riot limit you are ok.
    I minimized rations and maximized workday, but I maximized the wages. I lose something in gold and science but gain in lower crime.
    It looks this works well especially at the start when cities are small and the production comes from the city base (the central square) rather than citizens.
    But I can guess that a low crime is not worth of building improvements.

    The values that the game uses are calculated on BeginTurn event. The values that you see in the manager are just projections.
    Values are calculated for each city but the manager shows only a sum of numbers from individual cities?
    Civ2 "Great Library Index": direct download, Apolyton attachment

    Comment


    • #17
      Originally posted by Immortal Wombat
      Big numbers = good
      Small numbers = reseach more
      We have clearly different approaches to TBS games
      Civ2 "Great Library Index": direct download, Apolyton attachment

      Comment


      • #18
        Originally posted by SlowThinker
        I mean the formulas - I suppose they are neither in GL nor in .txt files - so the source code is the only source? My question is if there are similar posts like Locotus' formula about use of food from squares (there is a link in my first post here) but about different scopes (like crime).
        You was quite good to figure out the amount of crime if there are no buildings or wonders that reduce crime. So for instance a building reduces crime let's say by 10% and there is a wonder that reduces crime by 30%, you shouldn't have any problems to put it into your formula. Of course if you waant to know it exactly you have to take a look into the source code.

        Originally posted by SlowThinker
        I thought happiness improvements icrease happiness rather than allow to get over some limit...
        What constant determines the limit? I know RIOT_LEVEL, TooManyCitiesThreshold, MartialLawThreshold but they don't cause this limit probably ...
        Limit? There is no limit, the city has a base happiness and then all the modifers that add and reduce happiness come into play.

        Originally posted by SlowThinker
        I minimized rations and maximized workday, but I maximized the wages. I lose something in gold and science but gain in lower crime.
        It looks this works well especially at the start when cities are small and the production comes from the city base (the central square) rather than citizens.
        But I can guess that a low crime is not worth of building improvements.
        Actually our startegy is it to exploit our people, at least in the standart game this seems to be the right strategy.

        Originally posted by SlowThinker
        Values are calculated for each city but the manager shows only a sum of numbers from individual cities?
        Then you didn't find every manager.

        By the way Ben's way of thinking about these numbers is a very practical way. The bigger the better.

        -Martin
        Civ2 military advisor: "No complaints, Sir!"

        Comment


        • #19
          Originally posted by Martin Gühmann
          Actually our startegy is it to exploit our people, at least in the standart game this seems to be the right strategy.
          I think hes talking about right at the start. I increase wages to maximum because you lose hardly any science (if any at all), but lower crime for faster settlers.
          Call to Power 2: Apolyton Edition - download the latest version (12th June 2011)
          CtP2 AE Wiki & Modding Reference
          One way to compile the CtP2 Source Code.

          Comment


          • #20
            Originally posted by Maquiladora
            I think hes talking about right at the start. I increase wages to maximum because you lose hardly any science (if any at all), but lower crime for faster settlers.
            Well can be, you don't pay for buildings and you can't set you science tax to 100%. But scinece is taken from what is left afterwards you have paid the people and the buildings, so actual it should decrease science unless, the wages aren't so high, either. However I played around with my optimization code and I inserted one piece that should correct a bug, but I saw this increasing wages to the maximum and my algorithm was right at least it did what it was supposed to do, but so far I didn't investigate it so deeply if I didn't oversee something.

            -Martin
            Civ2 military advisor: "No complaints, Sir!"

            Comment


            • #21
              Originally posted by Martin Gühmann
              Of course if you waant to know it exactly you have to take a look into the source code.
              I hoped somebody did the work for me already.

              By the way Ben's way of thinking about these numbers is a very practical way. The bigger the better.
              My problem is I am hesitant, and it may happen that there are two numbers to be upped...

              Well can be, you don't pay for buildings and you can't set you science tax to 100%. But scinece is taken from what is left afterwards you have paid the people and the buildings, so actual it should decrease science unless, the wages aren't so high, either.
              You want to say that science is very important (in comparison to gold)? But IMO the growth (production + food) is more important. With wages set to maximum you lose some science but get much of growth.

              However I played around with my optimization code and I inserted one piece that should correct a bug...
              Optimization code? What's that?
              Civ2 "Great Library Index": direct download, Apolyton attachment

              Comment


              • #22
                Originally posted by Martin Gühmann
                Limit? There is no limit, the city has a base happiness and then all the modifers that add and reduce happiness come into play.
                I mean a limit of the Empire Happiness.

                This is an example of my starting game (Tyrany):

                1st picture:
                Rations, Workday and Wages are set to expected values. The Empire Happines (next EH) is 76.
                (I supposed it would be rather 75 because of
                BASE_CONTENTMENT 75 # starting happiness
                but maybe it is BASE_CONTENTMENT + 1 ?)
                If I drag any slider to higher exploitation then the EH drops to 75, 74, 73 etc. (it corresponds to NegativeRationsCoef=1, NegativeWorkdayCoef=1, PositiveWagesCoef=1)

                2nd picture:
                If I drag any slider to lower exploitation then the EH increases to 78 (by +2), although the PositiveXXXCoeficients are again 1.

                3rd picture:
                If I drag any slider to lower exploitation again then the EH doesn't increase anymore, it stays 78. This is the limit I mentioned.

                With 2 cities the "base happiness" drops from 76 to 75 and it works a similar way: first +2 to 77, then no more increment.

                With 8 cities the "base happiness" drops from 75 to 74 and the limit of EH is 76.
                Attached Files
                Civ2 "Great Library Index": direct download, Apolyton attachment

                Comment


                • #23
                  Originally posted by SlowThinker

                  I mean a limit of the Empire Happiness.

                  This is an example of my starting game (Tyrany):

                  1st picture:
                  Rations, Workday and Wages are set to expected values. The Empire Happines (next EH) is 76.
                  (I supposed it would be rather 75 because of
                  BASE_CONTENTMENT 75 # starting happiness
                  but maybe it is BASE_CONTENTMENT + 1 ?)
                  If I drag any slider to higher exploitation then the EH drops to 75, 74, 73 etc. (it corresponds to NegativeRationsCoef=1, NegativeWorkdayCoef=1, PositiveWagesCoef=1)

                  2nd picture:
                  If I drag any slider to lower exploitation then the EH increases to 78 (by +2), although the PositiveXXXCoeficients are again 1.

                  3rd picture:
                  If I drag any slider to lower exploitation again then the EH doesn't increase anymore, it stays 78. This is the limit I mentioned.

                  With 2 cities the "base happiness" drops from 76 to 75 and it works a similar way: first +2 to 77, then no more increment.

                  With 8 cities the "base happiness" drops from 75 to 74 and the limit of EH is 76.
                  And now what's your problem? Of course if you raise the exploitation your happiness drops, and if you lower explotation it increases. And of course with the sliders you have only a limited effect, but you can build happiness improvements happiness wonders, for instance the Ramajana gives you +3 happiness in each of your cities, and you can engage entertainers. Each entertainer gives you a +2 happiness. So if you have size 60 cities you can turn in each city 30 workers into entertainers, that gives you a happiness bonus of +60 and then you average happiness will also increase by +60 if you do it in all of your cities. But of course doing this doesn't give you any gain, espeacilly if you build some crime reducing buildings.

                  -Martin
                  Civ2 military advisor: "No complaints, Sir!"

                  Comment


                  • #24
                    Originally posted by SlowThinker
                    You want to say that science is very important (in comparison to gold)? But IMO the growth (production + food) is more important. With wages set to maximum you lose some science but get much of growth.
                    I agree. You dont actually have to start decreasing wages until commerce (from the land), and a government with high science tax, becomes more effective than using scientists specialists.

                    Anyway what youre mentioning has all been identified and fixed in one mod or another, which will make its way to the sourcecode eventually too.

                    Things like increasing negative happiness for slider movement and increasing the need for gold, both of which are done in Ages of Man.

                    Science costs are also extremely high in AoM, so a one notch decrease in wages could mean 20 turns to next advance, even early in the game. You can grow and build a lot but youll be 100 or 200 turns behind in science if you neglect it too long.
                    Call to Power 2: Apolyton Edition - download the latest version (12th June 2011)
                    CtP2 AE Wiki & Modding Reference
                    One way to compile the CtP2 Source Code.

                    Comment


                    • #25
                      I think they delibrately made it almost impossible(maybe actualy impossible) to work out the finer details of CTP.
                      And as it turns out i never had a problem with playing the game - just dive in, try some stuff and have fun or retry it if it doesn't work as you hoped.

                      Its this 'fog of watthehellishappening' that i like in the CTP games

                      Still if your brain is upto it, i'm sure any info you could give us in your quest for the answer to life the universe and everything in CTP would be well recieved

                      Compared to civ where you can count your sheaths of wheat etc, CTP is weird and unfathomable.

                      [ie i dont have a clue what any of the numbers underneath the game actually do]. phew.
                      'The very basis of the liberal idea – the belief of individual freedom is what causes the chaos' - William Kristol, son of the founder of neo-conservitivism, talking about neo-con ideology and its agenda for you.info here. prove me wrong.

                      Bush's Republican=Neo-con for all intent and purpose. be afraid.

                      Comment


                      • #26
                        Originally posted by Martin Gühmann
                        And now what's your problem?
                        My problem is I almost understand how the happiness works...
                        There is Empire Happiness (EH) that is shown on the empire manager and depends on sliders of Rations, Workday and Wages. EH serves as a base happiness for cities: increases and decreases are shown for each city under the Status tab.
                        Am I right?

                        ...but what I don't understand is how exactly is defined the EH:
                        It looks there is some limit but I don't know how it is derived. i.e. which constant affects it. Why just city sizes 2 and 8 lower this limit? Does this limit depend on other things (government)?
                        Why the hell the EH increases by +2 although the PositiveXXXCoeficients are 1?

                        So if you have size 60 cities you can turn in each city 30 workers into entertainers, that gives you a happiness bonus of +60 and then you average happiness will also increase by +60 if you do it in all of your cities. But of course doing this doesn't give you any gain, espeacilly if you build some crime reducing buildings.
                        When going through the .txt files I was curious what is this:
                        VERY_HAPPY_THRESHOLD 85 # threshold at which a city is considered "very happy"
                        Does it cause any effect?
                        Last edited by SlowThinker; August 17, 2005, 16:47.
                        Civ2 "Great Library Index": direct download, Apolyton attachment

                        Comment


                        • #27
                          Originally posted by child of Thor
                          Its this 'fog of watthehellishappening' that i like in the CTP games
                          I couldn't like a game if I didn't know what happens.

                          Compared to civ where you can count your sheaths of wheat etc, CTP is weird and unfathomable.
                          It is not so bad.
                          Sheats of wheat (food production) can be derived from growth, values of gold and science in the city window are net values, so it looks only the city production is hidden (and I dislike this fact).
                          Cumulated food is represented by population, cumulated gold and science is published too, but cumulated shields are unclear again. So I made a spreadsheet that computes shields from the rushbuy cost. It is attached in the next post.

                          Rushbuys

                          I used the spreadsheet for understanding how the rushbuy cost is derived. It looks the values XXXRushModifier in govern.txt (UnitRushModifier, BuildingRushModifier, WonderRushModifier, EndGameRushModifier) are valid only for 0 shields remaining (and so are only theoretical). If you have no shield cumulated then the cost is doubled.

                          An example:
                          You want to rushbuy a settler (it costs 740 shields) under Monarchy, the UnitRushModifier for monarchy is 4. So for example
                          if you need to buy full cost (740) you pay 4*740*2 gold
                          if you need to buy 3/4 of cost (555) you pay 4*555*1.75 gold
                          if you need to buy 1/2 of cost (370) you pay 4*370*1.5 gold
                          if you need to buy 1/10 of cost (74) you pay 4*74*1.1 gold

                          The formula:
                          RushbuyCost = (RemainingShieldCost / FullShieldCost +1) * XXXRushModifier * RemainingShieldCost

                          (I tested it with Settlers only)

                          Edit: In the city where you rushbuy you lose production of that turn. (therefore you may want to switch to 100% Public Works. Unfortunately it means an aditional micromanagement )
                          Last edited by SlowThinker; August 17, 2005, 17:03.
                          Civ2 "Great Library Index": direct download, Apolyton attachment

                          Comment


                          • #28
                            the spreadsheet that computes shields from the rushbuy cost
                            Attached Files
                            Civ2 "Great Library Index": direct download, Apolyton attachment

                            Comment


                            • #29
                              i admire your tenacity. But don't be too surprised if all the equations give the answer 42
                              'The very basis of the liberal idea – the belief of individual freedom is what causes the chaos' - William Kristol, son of the founder of neo-conservitivism, talking about neo-con ideology and its agenda for you.info here. prove me wrong.

                              Bush's Republican=Neo-con for all intent and purpose. be afraid.

                              Comment


                              • #30
                                Originally posted by SlowThinker

                                I couldn't like a game if I didn't know what happens.
                                so you must be quite frustrated with real life scnr

                                and yes, you're right about the rushbuying (though i never calculated it).

                                so before the time i'm able to produce pw directly via the infrastructure "building" i normally switch between two settings 0% pw and maximum pw setting which doesn't force me to disband units for one turn whilst rushbuying as many things i can (which sometimes is only that single wonder)

                                Comment

                                Working...
                                X