The 3rd Age

The Peloponnesian Wars

The Peloponnesian Wars

The Peloponnesian Wars (or TPW) aims to bring BFME2 into Greece, 5th Century BCE.

Button for The 3rd AgeButton for The Dwarf HoldsButton for The Elven AllianceButton for Helm's Deep Last HopeButton for GothmogtheOrcButton for BFME+Button for The Four AgesButton for HDR HeadquartersButton for Middle Earth CenterButton for Project Perfect Mod

Become an affiliate!

   

Quick Lists

Top Rated Popular New Updated Last Comments Users

Register and log in to move these advertisements down

Editing War of the Ring files

Tutorial for Battle for Middle-earth II: Rise of the Witch-king ROTWK

Avatar of SquallBK

SquallBK

Category: Code
Level: Intermediate
Created: Monday May 28, 2007 - 8:05
Updated: Saturday June 27, 2009 - 18:31
Views: 8684
Summary: editing the amount of units able to be built in a lw barracks, cost of lw structures, and more

Rating

Staff says

3.3

Members say

5.0

Average

3.8/5.0

4 votes

Page 1 2 3 4
This will take you through several different things to do with the Living World. None of this is really necessary, but just some things to customize your mod or just some personal customizations, if you wish to make them.

the list of files we will be editing in this tutorial are-

livingworldbuildings.ini
livingworldbuildableunits.inc
livingworldregions.inc

So, lets begin with livingworldbuildings.ini. This is located in the main INI directory. In this, you can edit several things, like the amount of resources you get from a farm, the amount of turns it takes to build a building, what heroes can be built in what fortresses, and more.

Lets say you wanted the amount of resources from a farm to be increased. Just locate these lines of code-
              
Code

;--------------- Farm ----------------

LivingWorldBuilding LWB_GondorFarm
    AvailableTo = PlayerMen
    
    BattleThingTemplate = GondorFarm

    BuildingIcon = LWBIcon_GondorFarm
    TurnsToBuild = 1
    StrategicResourceCost = WOTR_FARM_COST
    
    ConstructButtonImage = BCFarm
    ConstructButtonTitle = CONTROLBAR:LW_Structure_GondorFarm
    ConstructButtonHelp = CONTROLBAR:LW_ToolTipBuild_GondorFarm

    DisplayNameTag = CONTROLBAR:LW_Structure_GondorFarm
    DisplayDescriptionTag = CONTROLBAR:LW_ToolTip_GondorFarm

    Type = Resource                    ; Where to put this building in the end-of-game score/stats screen

    BuildingNugget IncreaseCommandPoints    NuggetTag_WorldCP
        Type = WORLD
        Amount = +30
    End
    
    BuildingNugget IncreaseTreasury NuggetTag_GiveLoot
        TreasureAmount = 100
    END


this is the code for the MEN Farm. If you want to edit a different farm for a faction, just locate the same basic code. So, you want to increase the amount of resources from a farm? Lets say you want to change it to 300, right now it is 100. This code determines the amount of resources from 1 farm-
              
Code

    BuildingNugget IncreaseTreasury NuggetTag_GiveLoot
        TreasureAmount = 100
    END


just change the TreasureAmount to 300.

-----------

Now, what if you want to add a hero from another faction to a different faction? Lets just use Legolas as an example. Just find this code in the elven fortress in livingworld-
              
Code

        ArmyToSpawn
            PlayerArmy = LegolasArmy
            Icon = ElfArmyIcon
            IconSize = Small
            PalantirMovie = Palantir_150
            BuildTime = 1 ; 3
            ConstructButtonImage = HILegolas_wotr
            ConstructButtonTitle = CONTROLBAR:LW_Hero_Legolas
            ConstructButtonHelp = CONTROLBAR:LW_ToolTipBuild_Legolas
        End


just take that same code, and put it in the fortress of which you want legolas to be on. So if you want him to be on MOTW, put that code in the MOTW living world fortress where the other hero codes are.

Now, when you add a hero such as Eomer, or Aragorn to elves (if you do) you will notice that when they come out of the fortress they are army leaders, like they would be in Motw. To fix this, if you wish to do so, is very simple.

              
Code

        ArmyToSpawn
            PlayerArmy = EomerArmy
            HeroTemplateName = RohanEomer; remove this line
            Icon = HeroEomerIcon; change 'HeroEomerIcon' to 'ElfArmyIcon', if in fact, you are adding eomer to the elves. if not, just simply use 'DwarfArmyIcon' or otherwise
            IconSize = Small
            PalantirMovie = Palantir_150
            BuildTime = 1 ; 2
            ConstructButtonImage = HIEomer_wotr
            ConstructButtonTitle = CONTROLBAR:LW_Hero_Eomer
            ConstructButtonHelp = CONTROLBAR:LW_ToolTipBuild_Eomer
        End



----------

So, do you want to decrease the amount of turns taken to build a building? Lets use a fortress as an example. Any fortress takes 2 turns in WOTR to build. To decrease it to one turn just change this line-
              
Code

    BuildingIcon = LWBIcon_ElvenFortress
    TurnsToBuild = 2 ; 2
    StrategicResourceCost = 1000


In the TurnsToBuild line, just change the one closest to '=' to 1. anything to the right of a semicolen is usually ignored in the INI.

----------

So, now to try out the build costs. For any living world building just find this line in the code-
[code]
    StrategicResourceCost = 1000

just change that to whatever you want it to be.

Ok, so now move onto the next page and you can learn about the livingworldbuildableunits.inc

Comments

Display order: Newest first

Delta Omega - Tuesday August 18, 2009 - 12:42

By the way has any one noticed that the code for
amon sul (ruins) should be:

RestrictBuildings
Buildings = Fortress
NumberAllowed = 1
End

not:
RestrictBuildings
Buildings = Fortress
NumberAllowed = 0
End

since it is infact not a world map fortress, you should be able to build a fortress in amon sul (ruins).
[Ea was going to put in amon sul as a world map fortress, as can be seen by offical EA screenshots, guess they forgot to fix the fortress coding!].

SquallBK - Monday February 18, 2008 - 17:41

Although it has been quite a long time, I have made a small update to this article by giving information on the first page about turning army leaders into regular armies, like when you are bringing one hero to another faction who is an army leader, this can cause quite a build up of army leaders in one faction, so I explained how to turn army leaders into normal armies. It was a very simple task but it was just recently that I took the time to figure it out lol.

Solinx (Team Chamber Member) - Tuesday May 29, 2007 - 6:32

Interesting article :)

Back when I was actively modding BFME 2, this area, the WotR mode, was hardly looked at. Nice to see there is starting to be some interest in it. :)

Solinx

Go to top

 

"One site to rule them all, one site to find them,
one site to host them all, and on the network bind them."

 
12:35:52