European Barracks multiplier?

Discussion in 'Modding' started by Fulcrum, Mar 12, 2017.

  1. Fulcrum

    Fulcrum Active Member

    Does anyone have an idea on where to find the price multiplier for the European barracks?
     
  2. Ftoomsh

    Ftoomsh Well-Known Member

    It's in the unit.script file. Search for the string csid+'bar' or even just 'bar'. Or if you want to find the start of all the buildings code search for // BUILDINGS

    Then find the SetObjBuildingExtProperties statement for the barracks.

    The procedure which defines this is;

    procedure SetObjBuildingExtProperties(var objprop : TObjProp; var objbase : TObjBase; maxhp, buildtime, costpercent : Integer; bcapture : Boolean; score, usage : Integer; food, wood, stone, gold, iron, coal : Integer);

    This tells you what the parameters of SetObjBuildingExtProperties are. You will see costpercent there. If you put 200 that will double the cost each time. If you put 300 that would treble the cost each time. You can put any integer value you like from 101 to I-don't-know-what but a very big number would likely go out of bounds. If you put 1000 then the cost would rise ten times each time. I doubt you'd ever need a bigger number than that.

    Values like say 102 tend to be used to inflate unit costs. Mercenary units have inflation costs like 102 which really means 2% more cost each unit on infinite production.
     
  3. Fulcrum

    Fulcrum Active Member

    Thanks man, will look it up later today. You say 300% but from 100 300 100 they get to 1000 3000 100. Are you sure its this parameter? I did try to reverse understand it by looking for a 10x multiplier but no luck. Will try your method for sure and report.
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice