You must be logged in to post messages.
Please login or register

Grey Havens (World Builder & Game Mods)
Moderated by Sir Hugh, Blatant

Hop to:    
Welcome! You are not logged in. Please Login or Register.171 replies, Sticky
Battle for Middle Earth II Heaven » Forums » Grey Havens (World Builder & Game Mods) » Want to Learn INI?
Topic Subject:Want to Learn INI?
« Previous Page  1 ··· 5 6 7  Next Page »
(id: Ancalagon_4554)
posted 01-29-07 08:07 PM EDT (US)         
Ask your questions here: I'll be happy to answer them. This is like the question thread, except that it's solely for INI, and the answers will be in tutorials, which are longer. Ask me an INI question. I may start by giving a mini-tutorial.

Also, please specify in your questions if this is for a mod or a mod map.

Thanks to Kester for the sticky!


Wait, so what is this topic about?
This is about modifying BFME2, or at least some aspects.

What do you mean?
Well, basically, this topic is about coding for the game: anything related to that.

Sounds hard...
Well, it is, but once you know what to look for, and how everything's related, it gets easier.

What is ini?
The game keeps its data in files called BIG files. Basically, they compress the data within it. We're looking at the INI.big file, which contains hundreds of files. Every file in that big file ends in INI, which is the format the game uses. There are some files that end in INC, but we won't have to worry about that.
What can ini do?
Well, it can do a lot. It can add new powers to units, cause buildings to spawn specific units, and most of the things used in the game. However, ini is by no means a magical language in which everything is possible.
What's an ini file?
It's an initialization file, to be exact. It tells the game all of the information about a specific object, its modules, etc.

What's an object? And how do I get started?
I'm making tutorials right now. If you ever have a specific question, ask it on this topic. I'll be happy to help.

About Coding

In the next few weeks or so, I'll be putting up tutorials as people need them, but I'll start with object-oriented programming as it relates to BFME2.

The game's code is basically a collection of objects. Some objects do some things, and some do others. Some are buildings, and some are units. Let's start with Boromir.Object GondorBoromirBasically, all this does is tell the game that there is an object named GondorBoromir. There is nothing special about this object, except that we can call it GondorBoromir.

The following code in the game code tells the game the parameters, or the characteristics of the object. The game's code starts out with putting down the art parameters. The art parameters tell the game how Boromir is supposed to look. This is hard to code for a newbie, so let's skip it for now.

Next, you'll see all sorts of random attributes; here are some important ones:BuildCost
ShroudClearingRange = SHROUD_CLEAR_HERO
DisplayName = OBJECT:GondorBoromir
RecruitText = CONTROLBAR:GondorBoromirRecruit
ReviveText= CONTROLBAR:GondorBoromirRevive
Hotkey= CONTROLBAR:GondorBoromirHotkey
CrushableLevel = 2 ;What am I?: 0 = for infantry, 1 = for trees, 2 = general vehicles

CommandSet = BoromirCommandSet
CommandPoints = 50
These are very important.
The BuildCost is how much the unit costs.
The BuildTime is how much time (in seconds) that it takes to build him.
WeaponSet is the type of weapon that Boromir uses, and under what conditions.
The armorset is the same, except for armor.
The VisionRange is how far Boromir can "see" units. If it's under attack stance and it has a large vision, it will attack units very far away.

Alex_3737's Tutorials

[This message has been edited by Ancalagon_4554 (edited 06-05-2007 @ 02:08 PM).]

posted 02-01-09 10:49 PM EDT (US)     151 / 171       
OK... here's what happens:

When I try to edit "data\ini\", I get a message from Notepad:
Cannot find the C:\Users\myname\DOWNLO~1\FINALB~1\ file
and: Do you want to create a new file?

(Yes or No I just get an empty notepad file.....)

And when I move that window out of the way, the field of the window for FinalBIG[INI.big] displays:

This file is currently locked

Then, when I close the notepad window, that field reverts to an opened but not-editable[SYSTEM]

.....SO, I'm guessing this is a vile VISTA snafu. All I really wanted to do was to be able to set all CreateAHero stats to 20 -- argh!/*sigh*

Any ideas?

The Best Guest
posted 02-02-09 07:22 PM EDT (US)     152 / 171       
usually create a hero is pretty hardcoded dont know if thats the problem but ask around about that lil tid bit

This is Not A Sig it is a Follow up to a Post
Revora Forums for all your modding needs
TBG (He is ever so slightly more awesome than everyone else for voting now isn't he?)-FOO
BSL Clan
"mods are actually fun girls!"-Jax
posted 02-10-09 05:17 PM EDT (US)     153 / 171       
extract the file, then edit it and then readd it in the archive, then it'll work.

But, how do you give a hero more than 5 powers?
The Best Guest
posted 02-10-09 05:45 PM EDT (US)     154 / 171       
Make a switching commandset then you can have more then 5

This is Not A Sig it is a Follow up to a Post
Revora Forums for all your modding needs
TBG (He is ever so slightly more awesome than everyone else for voting now isn't he?)-FOO
BSL Clan
"mods are actually fun girls!"-Jax
posted 02-10-09 07:12 PM EDT (US)     155 / 171       
Yeah but won't EA kill you if you make a hero with all-20 stats?
posted 02-10-09 07:51 PM EDT (US)     156 / 171       
CaH's still have the infinite self-heal glitch, and EA didn't seem to care much :P
posted 02-11-09 08:37 AM EDT (US)     157 / 171       
Still? Even in RotWK? I thought they fixed that...
posted 03-25-09 07:20 AM EDT (US)     158 / 171       
how do i put HeroEffectDuration = till hit something( if it's possible )
posted 03-25-09 02:32 PM EDT (US)     159 / 171       
Sadly it's not possible.

To all: If you have a question you should start a new topic. It's easier than to read it here.
posted 07-03-09 10:40 AM EDT (US)     160 / 171       

I just downloaded a new map and I don't know where to copy it in which folder, and I don't see any map folders in BFME-II file to paste the map in.. hope there's someone around to help and sorry if I'm posting this on the wrong place

thanks so much
posted 07-03-09 10:46 AM EDT (US)     161 / 171       
Yes, this is the wrong place to ask (create a new topic for your questions)

Your question has been asked many times, here is the answer
posted 07-03-09 11:25 AM EDT (US)     162 / 171       
Thanks ;>
posted 01-19-10 08:04 PM EDT (US)     163 / 171       
Can't find the .ini file where you can change the order and faction of spellbook powers, does anyone else know where it is?
posted 02-20-10 09:24 PM EDT (US)     164 / 171       
Ok, I just want to know if there's something as simple as someone creating an ini file for the 6 powered heroes, attributes, etc. Can someone edit there own file, (save a backup of course) then just post the file on the website?
posted 04-04-10 07:41 AM EDT (US)     165 / 171       
I wanted to modify armor, so I copied this:

Armor CAHArmorWizard
Armor = Default 50
(All other Armor = ...)

I rewrited it, but it didn't affected the game, nor made an error. Nothing happened. What to do for it to take affect?

[This message has been edited by belzebubkas (edited 04-04-2010 @ 07:43 AM).]

posted 12-18-10 03:21 PM EDT (US)     166 / 171       
Hi there,
can someone explain me step by step how to modify gimli's damage, armor, and health i got to Gimli.ini, object RohanGimli but i dont have idea what to do.
Please help!
posted 08-08-11 05:23 AM EDT (US)     167 / 171       
hi guys im new to bfme modding but im good at modding overall. however i dont seem to be able to do much. i tried getting aragorn to mount and gve him KNIGHT RANGER TOGGLE so he can mount. it doesnt work. if i need to bind a horse cann someone teach me how to bind the witchkings horse?

also i tried to get faramir to be able to use silverthorn arrows. i replaced wounding arrow with silverthorn upgrade on faramir, dunedain and ithilien ranghers. i added the research to my archery range too and i can research it but when i go to the units (faramir, dunedain and ithilien ranghers) it says the upgrade is not available. so i added this to te horde of ithilien rangers

WorldMapArmoryUpgradesAllowed = Upgrade_GondorBasicTraining Upgrade_GondorFireArrows Upgrade_ElvenSilverthornArrows
will that make it work? please answer soon,

posted 09-03-11 12:03 PM EDT (US)     168 / 171       
I always used scripts until recently and had no trouble with it! BUT!! there is no script to deactivate the invisibility (for stealth there is one) of an elven create a hero! I'm really desperate an would be grateful to you if you told me how to remove invisibility with .INI (not ini.Big if there is a difference)

I'd like to deacivate invisiblility for all units on the map! It's a map that i'm making! ( my second )

posted 12-26-11 09:56 PM EDT (US)     169 / 171       
Okay, where do I find the data for the balrog? I want to change the timer to -1 so it won't go away.
posted 06-24-17 08:24 AM EDT (US)     170 / 171       
help i really wanted to modify the command points for bfme 2 to have a massive battle with my friends,i've edited the command point through the ini.big files using notepad but the game crashed afterwards. Can anyone teach me the step by step on how to do it cuz i can't seem to find anything online
posted 07-22-17 09:51 AM EDT (US)     171 / 171       

Curious..How do you mod the skirmish/solo play so you can have all Good Sciences, and not just Elves or Men. I'd like to be able to maker it where if you choose one of the "good" or "evil" player templates, you could have all of the "good" or "evil" sciences that were in the campaign. I tried messing with the playertemplate in the ini.big file but it wouldn't work.

« Previous Page  1 ··· 5 6 7  Next Page »
You must be logged in to post messages.
Please login or register

Hop to:    

Battle for Middle Earth II Heaven | HeavenGames