Note: LucasForums Archive Project
The content here was reconstructed by scraping the Wayback Machine in an effort to restore some of what was lost when LF went down. The LucasForums Archive Project claims no ownership over the content or assets that were archived on archive.org.

This project is meant for research purposes only.

Mini-Tutorial: Installing and Creating XML based mods

Page: 1 of 1
 Bob Lion54
02-22-2006, 2:24 PM
#1
Basically, I’ve been seeing a bunch of people with the same problem. I thought I would write a mini-tutorial about how to install and create basic mods. (This is only for xmls as for as I know)


A) Downloading a mod.

Download a mod. Read the readme. Most of the mods that have been made so far are simple changes to various xml files. Simply create a folder called “XML” in the game directory –“Program Files\LucasArts\Star Wars Empire at War\GameData\Data.”

Drop the modded xml files into the created “XML” folder (which should be “Program Files\LucasArts\Star Wars Empire at War\GameData\Data\XML”) and you’re done! Enjoy the mod!

B) Creating a mod. (Keep in mind, this is only for editing the xml files.)

As an example, I will increase the health of “Home One”.
1) Download a program that can extract meg files. The one I use can be found here - http://www.technical-difficulties.com/hacks/eaw/) (The site says its for the demo, but version 1.1 will work with the full game.) Unzip the file.

You will get two programs, megExtractor and megInserter. You will not need megInserter, however. (megInserter actually causes the mods to not work.)

2) Create a new folder somewhere on your hard drive outside the game directory. It doesn’t matter where, just make sure you remember where you created it. I made the folder “EAW files” under “Program Files\LucasArts.” Copy and paste megExtractor into this folder. Now return to “Program Files\LucasArts\Star Wars Empire at War\GameData\Data” and copy the file “config.meg” and paste it in the same folder where you pasted megExtractor. You should now have a folder with two files in it, megExtractor.exe and config.meg.

3) Run megExtractor and follow its instructions. It will create a new folder called “config.” Open this folder. Since for my example I will be editing Home One, I need to go to the file “DATA%XML%UNIQUEUNITS.” Copy the file and paste it somewhere outside the “config” folder. (You can just leave it in the “config” folder, but this way, you don’t have to extract the files later if you want to edit something else. I like to put it in a new folder that describes the changes. For my example, I would make a folder called “Home One more health” or some thing along those lines.)

4) Right-click “DATA%XML%UNIQUEUNITS” and select “open with notepad.” Four lines down, you will see “<UniqueUnit Name="Accuser_Star_Destroyer">” I like to copy the part “UniqueUnit Name” and use the “Ctrl+F” trick to easily search through the various units. Do this until you come to “<UniqueUnit Name="Home_One">.” Scroll down until you get to “<Tactical_Health>8000</Tactical_Health>” Change the number to whatever you want. You can increase it slightly, say to 8100, or you can make it virtually invincible by increasing it to something like 9999999 or whatever. (You can also decrease it if you want.) Whenever you are done editing whatever you want, click the “X” at the top right corner of the screen to close notepad. When prompted if you want to save the changes, select “yes.” (**NOTE** If you try to save your changes by clicking “save as…” or “Save” from the “File” menu, it will save it as a text document and will not be useable.)

5) Almost Done!!
You will now have a modded version of the file “DATA%XML%UNIQUEUNITS.” Change the file name to “UNIQUEUNITS.” In other words, for the game to read your modded xmls, you have to get rid of “DATA%XML%” from the file name. Either right-click and copy or right-click and cut the file.
If you have not already done so, create the folder “XML” under your game directory. (See Section:A for further details) Right-click and paste the file in the “XML” folder and your DONE!!

I hope this has helped someone!! Thanks for reading!!

Bob Lion54

EDIT: While notepad is fine as an XML editor, there are other programs available that have more options.

A few XML editors:
Microsoft Visual Web Developer (http://msdn.microsoft.com/vstudio/express/vwd/) (Free)
Stylus Studio® 2006 XML (http://www.stylusstudio.com/xml_download.html) (30day trial)
XMLwriter XML Editor v2.6 (http://xmlwriter.net/g2_index.shtml?editingxml) (30day trial)
Altova XML Spy 2006 (http://www.altova.com/download_spy_enterprise.html) (30day trial)
 Cmdr. Cracken
02-22-2006, 2:42 PM
#2
This needs to be stikied immediatly.
 Bob Lion54
02-22-2006, 3:02 PM
#3
hehe. I'm glad you approve.

Let me know of anything is worded awkwardly or needs to be clarified. Its actually my first tutorial of any kind.
 dookie23
02-22-2006, 7:08 PM
#4
Hey ill give you credit, can I put this in my readme? Too lazy to type all that in my mod readme. :P
 Bob Lion54
02-23-2006, 12:01 AM
#5
Yea, you can use it if you want to.
 Jan Gaarni
02-23-2006, 11:37 AM
#6
Why isn't this stickied yet?

*stuck*

There.

Much better. :)
 Evil Jeremy
02-23-2006, 11:38 AM
#7
what is the file for the heros?
 Athanasios
02-23-2006, 12:15 PM
#8
Good work Lion.

Just for history (this mini-tutorial is 100% perfect afterall) new modders may use more advanced XML editting programs. Of course advanced doesn't mean complicated too. I use Microsoft Visual Web Developer (http://msdn.microsoft.com/vstudio/express/vwd/) that teams the code -very handy- and does plenty more things.

So, you may edit the tutorial with a small list to those XML editting tools. I'll send you a message with them as soon as i gather 3-4 of them.

Good work again ;)
 Bob Lion54
02-23-2006, 2:01 PM
#9
what is the file for the heros?
Ground heros are in "NAMEDHEROUNITS"
Space heros are in "UNIQUEUNITS"

To edit heros that can fight in space and on land (Han and Chewie, for example) you have to edit both files.

Good work Lion.

Just for history (this mini-tutorial is 100% perfect afterall) new modders may use more advanced XML editting programs. Of course advanced doesn't mean complicated too. I use Microsoft Visual Web Developer (http://msdn.microsoft.com/vstudio/express/vwd/) that teams the code -very handy- and does plenty more things.

So, you may edit the tutorial with a small list to those XML editting tools. I'll send you a message with them as soon as i gather 3-4 of them.

Good work again ;)
First, thanks for the complements!

Just send me the links to whatever other programs are good, and I'll edit my post. The more options, the better!

Why isn't this stickied yet?

*stuck*
.....
COOL! Thanks for my first sticky!
 Athanasios
02-23-2006, 4:53 PM
#10
No glory for me in this area mate ;) . Keep up the good work.
 Bob Lion54
02-24-2006, 8:02 AM
#11
^^^
Done! You might as well leave your post sinse there really is no reason to delete it. That, and it will look like I'm talking to myself! heh
 Admiral Sith
02-24-2006, 3:52 PM
#12
I personally like this XML Editor, http://www.mindfusion.org/product1.html).
 gswift
02-27-2006, 3:34 PM
#13
I use MS Visual Studio 2005 and Macromedia Dreamweaver. They're really nice, but not free.
 jmac7142
03-01-2006, 3:07 PM
#14
Just so you know, Visual Studio/C++/C#/VB 7+ can edit XML files as well, and there are a number of LUA plugins for it as well.
 wherryj
03-23-2006, 12:36 PM
#15
So I guess that if you place a file that is currently in the config.meg game file, placed into that "XML folder" the game will ignore THAT portion of the official config.meg and use the modded sections?

It's not that I believe you, but I guess that the game must have been programmed to deal with mods if it knows to ignore the existing file and go for the modded file. I would have figured that one would have to mod the actual config file.

Great info! I think that I'll try adding the hangar bays again now that I know that I don't actually mod the config file.
 Three60
03-23-2006, 12:39 PM
#16
If you can't add them, there are plenty of mods that do.
 KirtanLoor_PL
06-06-2006, 5:13 AM
#17
Hmm, anybody has the full list of the XML tags with the explanation;-)?
Some of them are quite easy to understand, as <Tactical_Health> or <Shield_Points>, but there are some as <Death_Explosions> or <Death_Clone> which I do not understand...
 Slipstreme
07-05-2006, 3:09 PM
#18
I just use Notepad

I've got SSD, SDs and Venators launching ARC-170s, V-Wings and TIE (Fighters, Avengers, Defenders, Bombers, Interceptors) agaisnt the Rebelions B-Wings, E-Wings, X-Wings, A-Wings, Y-Wings and Eta-2 Interceptors

Just a bunch of ships and models from other mods that I've... collected :D
 Darth Khasei
07-05-2006, 3:31 PM
#19
Hmm, anybody has the full list of the XML tags with the explanation;-)?
Some of them are quite easy to understand, as <Tactical_Health> or <Shield_Points>, but there are some as <Death_Explosions> or <Death_Clone> which I do not understand...

Not that I know of to date. The Death explosion is the explosion used when that part or ship explodes. The death clone is the model of the ship dying. Death clone is listed as another ship entry. It appears like a slight of hand trick as this model seems to quickly replace the regular one upon its destruction, not that human eyes actually sees it :)
 Teej2005
07-16-2006, 11:27 PM
#20
Ive owned this game since it first came out but I just recently started trying to use 'user-made' mods. For some reason though, I cannot see the new vehicles and space craft in the game. I can see their description, but the icons do not show up on the 'build' or 'fleet view' and of course do not show up during battle.

I am using the 'conflict in space' mod.

I am sure theres something minute that I am not doing correctly.
 Dreng
07-17-2006, 5:54 AM
#21
What do you have to type on the black screen?
 DarthMaulUK
07-17-2006, 6:04 AM
#22
If your mod isnt working, you might need to re-install it. Remember, it will write over your current game files (XML) so allow it do this. If you have patch 1.4, the game has now created a new Mod folder where all your mods should sit. Some mods come with an Icon which you must use as the game exe file to start it up (double click it) and the game will boot up using the new mod.

Dreng - please give more information on what you are trying to do

DMUK
 Teej2005
07-17-2006, 9:09 AM
#23
My main 'Mods' folder sits inside my main 'Data' folder... and my actual downloaded mod of "CIS" sits first level inside the main 'Mods' folder that came with the 1.4 update.

Here's where its located:
G:\Games\Lucas Arts\Star Wars Empire at War\GameData\Data\Mods\CIS

Inside the 'CIS' folder sits the mods 'Data' which holds Art, Text, and XML

Should I try to overwrite the default files?
This mod did come with its own .bat file which sits inside the main game directory. I do use it to start the game.
 Dreng
07-17-2006, 11:12 AM
#24
when i open megExtractor a window pop up and i dunno what to type in there
 Teej2005
07-17-2006, 11:54 AM
#25
http://i41.photobucket.com/albums/e294/Teej2005/missingsquadran.jpg)

see how I am missing some of the model's as well as one of the heroes?
 DarthMaulUK
07-17-2006, 12:58 PM
#26
What mod are you playing with? More information is needed. Or are you trying to make your own?

DMUK
 Teej2005
07-17-2006, 1:49 PM
#27
CIS V.3

Conflict in Space Mod. Here are the installation instructions which I followed. I mean, it cant be that hard but apparently there is something elementary that I am doing wrong or perhaps, though unlikely, maybe the mod itself is just missing the art files??

[INSTALLATION]

1) Method for EAW v1.04 and newer (recommended)
Unzip the archive and put "CIS" folder into your "Star Wars Empire at War" Mods directory (e.g. "C:\Program Files\LucasArts\Star Wars Empire at War\GameData\Mods\"). You may need to create this folder ("Mods") in "GameData" directory. Put "conflict_in_space.bat" file into "Star Wars Empire at War\GameData\" folder and double-click on it to start the game with the mod enabled. You can use provided icon to create a desktop shortcut (optional).

2) Method for all versions
Unzip the archive, find "Data" folder and copy it into "Star Wars Empire at War\GameData\" folder, overwrite existing files. It is recommended to backup your original "MasterTextFile_ENGLISH.DAT" file. Start the game with the default shortcut.

I downloaded it from:
http://empireatwar.filefront.com/file/Conflict_In_Space_New_Units_V3;66030)
 DarthMaulUK
07-17-2006, 2:38 PM
#28
Theres a good chance the mod is missing the art files. Its no big deal really, so long as it works.

DMUK
 Teej2005
07-17-2006, 2:42 PM
#29
Well... my main purpose was for the extra ships like the B-Wing. They dont show up in battle, they dont show up visually in production. I can hear them like ghosts in my mind when they say "B-wing squadron at your service".

Also, could it be because I dont install to default path on my C drive? I use a different drive for my game installs.
 Thraka
08-29-2006, 9:37 PM
#30
I created a tool that will take the files in this format: DATA%SCRIPTS%AI%BUILDCANTINAPLAN.LUA and create sub directory structure with this file name:
[CurrentDirectory]\data\scripts\ai\buildcantinaplan.lua

It also has a mode to then parse the data sub directory and move the files back to this:
[CurrentDirectory]\DATA%SCRIPTS%AI%BUILDCANTINAPLAN.LUA

Is this of interest to anyone?
 CIAop
10-16-2006, 10:13 AM
#31
anyone know which XML file controls the laser graphics?
 wherryj
11-17-2006, 4:04 PM
#32
Does anyone know if the mods that worked for EaW work exactly the same way for EaW:FoC? I had a mod that successfully made fighters spawn from Mon Cal cruisers for EaW, but it doesn't work when I reapply the same coding to the XML files for FoC.

I was able to make visible changes to things like pop caps, so at least some of the mods are the same. Did they change the coding or did I just make a mistake somewhere?
 wherryj
11-17-2006, 4:05 PM
#33
(Oh, before people ask, I added the spawn_fighters to space behavior, added the units underneath for specifics, added the hard point and modified the hard points in the other XML file. I used the same structure/wording as for EaW.)
 Slocket
11-17-2006, 10:01 PM
#34
There are significant changes. Some basic mods will work such as the Free Camera, but a proper one needs to be made so that the bigger maps distances visuals will show in game.

So basically, 90% + mods will not work.
 wherryj
11-20-2006, 1:01 PM
#35
There are significant changes. Some basic mods will work such as the Free Camera, but a proper one needs to be made so that the bigger maps distances visuals will show in game.

So basically, 90% + mods will not work.

Thanks. Actually, I finally tracked down my problem. Adding the extra random letter while typing a hardpoint doesn't help. For mods like adding fighter bays, the old EaW versions will work.

I do find it strange that you need rebel_X-Wing, but all other units will work as just the unit, however.
 Dactillion33
11-26-2006, 4:40 PM
#36
i followd ur instructions for installing a mod but it still didnt work and i removed the downloaded files and tried to run my game and it would not start

do i need to open the mod and extract something to make it work

and how can i get my game to work again, the box will come up and after i hit play the game will appear for a second then dissapear

i dont have FOC and i have the Collectors Addition
 Thrawn3.14
12-08-2006, 10:29 AM
#37
is there something different you need to do for FOC?

I tried everything you said, but it gives the error "Expect Strange Errors: There is a syntax error in..."

What do I need to do?
 Slocket
12-10-2006, 12:45 AM
#38
Some of the FoC XML files do that to me too if you make any changes to them. They have some real syntax errors in them.

I found out using a hex editor to edit the file works, while using wordpad causes thse odd files to puke.

Try out Rouge_Squadron and see what I mean. You will notice the mispelled word...try to fix normally with Wordpad (or make any other change) it will puke. So I used a Hex editor and that took, and worked in game.

I made a post about that bug somewhere, after the small fix..the Rouge Squadron Hero is a heck alot better now that it is being read proper.

There is also a buglet of the same nature to the 'Gallofree Transport' not showing up in GC mode. I posted the fixed file in the Mod section.

These are not openly stated as being fixed in the patch...we will see.
 Thrawn3.14
12-10-2006, 11:40 AM
#39
Some of the FoC XML files do that to me too if you make any changes to them. They have some real syntax errors in them.

I found out using a hex editor to edit the file works, while using wordpad causes thse odd files to puke.

Try out Rouge_Squadron and see what I mean. You will notice the mispelled word...try to fix normally with Wordpad (or make any other change) it will puke. So I used a Hex editor and that took, and worked in game.

I made a post about that bug somewhere, after the small fix..the Rouge Squadron Hero is a heck alot better now that it is being read proper.

There is also a buglet of the same nature to the 'Gallofree Transport' not showing up in GC mode. I posted the fixed file in the Mod section.

These are not openly stated as being fixed in the patch...we will see.

Ok, so it wasn't my fault... that's good. Is there somewhere I can download a Hex editor?
 Darth Badguy
01-08-2007, 11:54 AM
#40
I like this tutorial... Good job!
 Dactillion33
02-11-2007, 11:11 AM
#41
can someone please tell me how to install mods and get them to work

i still dont have FOC
 Splatah King
02-27-2007, 8:18 PM
#42
Could you have more than one type of ship in a squadron. For Example: 3 X-Wings and 2 B-Wings by changing the code of that squadron or am I dreaming.
 colonel-tempest
03-12-2007, 1:23 PM
#43
the tutorial works for foc as well thanks!
:vsd:
 Relenzo2
05-29-2007, 7:52 AM
#44
I have Teej's problem. Anyone know how I get these mysterious art files where they need to be?
 chrisbolling2
07-09-2007, 12:31 PM
#45
Could you have more than one type of ship in a squadron. For Example: 3 X-Wings and 2 B-Wings by changing the code of that squadron or am I dreaming.

It can be done. Look below at this code for the Y-wing Squadron, I have the units line seperated from the rest. Just add in what ever units you want.

<Squadron Name="Y-Wing_Squadron">
<Text_ID>TEXT_Y_WING_SQUADRON</Text_ID>
<Encyclopedia_Good_Against> Star_Destroyer Victory_Destroyer Acclamator_Assault_Ship </Encyclopedia_Good_Against>
<Encyclopedia_Vulnerable_To> TIE_Fighter Tartan_Patrol_Cruiser Pirate_Fighter </Encyclopedia_Vulnerable_To>
<GUI_Row> 1 </GUI_Row>
<Is_Dummy>Yes</Is_Dummy>
<Formation_Priority>2</Formation_Priority>
<Is_Escort>Nos</Is_Escort>
<Is_Bomber>yes</Is_Bomber>
<Autoresolve_Health>200</Autoresolve_Health>
<Damage>15</Damage>
<Affiliation>Rebel</Affiliation>
<Political_Control>0</Political_Control>
<Build_Cost_Credits>210</Build_Cost_Credits>
<Build_Time_Seconds>20</Build_Time_Seconds>
<Build_Tab_Space_Units>Yes</Build_Tab_Space_Units>
<Build_Initially_Locked>Yes</Build_Initially_Locked>
<Build_Can_Be_Unlocked_By_Slicer>Yes</Build_Can_Be_Unlocked_By_Slicer>
<Slice_Cost_Credits>400</Slice_Cost_Credits>
<Tech_Level>0</Tech_Level>
<Required_Timeline />
<Required_Star_Base_Level>2</Required_Star_Base_Level>
<Required_Special_Structures />
<Behavior>DUMMY_SPACE_FIGHTER_SQUADRON</Behavior>

<Squadron_Units>Y-Wing, Y-Wing, Y-Wing</Squadron_Units>

<Squadron_Offsets>60.0,0.0,0.0</Squadron_Offsets>
<Squadron_Offsets>0.0,30.0,0.0</Squadron_Offsets>
<Squadron_Offsets>0.0,-30.0,0.0</Squadron_Offsets>
<Icon_Name>i_button_y_wing.tga</Icon_Name>
<GUI_Model_Name>RV_ywing.ALO</GUI_Model_Name>
<GUI_Distance>120</GUI_Distance>
<GUI_Offset>0 0 0</GUI_Offset>
<GUI_Velocity>45</GUI_Velocity>
 Admiral DuDe
01-31-2008, 11:53 AM
#46
Hi... Im trying to start myself in creating units aswell as improving some ... but im just a amature... but like really one ... I'm just wondering how can I get some more turrets on ships ... for example ... a ship has only 10 and give it more than 100 turrets.. if thats possible (i think phoenix rising did it ).

Anyways can you help me in any way?
Page: 1 of 1