PDA

View Full Version : [Guide] How to combine mods.



MaxGhost
08-26-2009, 02:06 PM
How to combine mods
by MaxGhost

I decided to make this guide because of the problem the modding community of HoN faces, and because of my combination mod solution slowly coming to an end.

There are a few programs and tools you will need to be able to do this. Also, I'm not saying these are the best tools to do the job, but these are of my personal preference.

This guide requires you to have intermediate knowledge of how computer files and folders work and it requires you to have some common sense.

You will need file extensions turned on in your folder options turned on for you to be able to do some things during this guide. If you don't know how, Google it (http://lmgtfy.com/?q=turn+on+file+extensions+folder+options).

Note: This guide is for Windows operating systems for the first two steps. Notepad++ and 7-Zip are both cross platform applications, so for those using linux, they can easily use the linux versions of the programs.

1. Download and install the following programs:

i. Notepad++ Installer (.exe) (http://sourceforge.net/projects/notepad-plus/files/notepad%2B%2B%20releases%20binary/npp%205.4.5%20bin/npp.5.4.5.Installer.exe/download)
ii. Compare plug-in for Notepad++ (.dll) (http://sourceforge.net/projects/npp-plugins/files/ComparePlugin/Compare_1_5_5_UNI_dll.zip)
iiia. 7-Zip file archiver (.exe) (http://downloads.sourceforge.net/sevenzip/7z465.exe) (32-bit)
iiib. 7-Zip file archiver (.exe) (http://downloads.sourceforge.net/sevenzip/7z465-x64.msi) (64-bit)

2. Install the plug-in for Notepad++.

Navigate to the following folder: C:\Program Files\Notepad++\plugins

Place the downloaded ComparePlugin.dll into this folder and it should be installed.

3. Get the mods you want to combine.

Visit The Modification Repository (http://forums.heroesofnewerth.com/showthread.php?t=7391) and download the mods you want to combine together.

Once you've done that, I suggest you put all the mods (.s2z files) into one folder that you can easily reach (desktop mabye).

4. Open and extract the mod files.

Next, we'll need to open the mod files with 7-Zip. The easiest way is the right-click on them and under the new 7-Zip menu, choose "Open Archive". This will bring up an explorer-style 7-Zip panel. Now, you've opened the mod. After opening the mod, we'll need to extract it to another folder, so click the extract button. Make a new folder inside of your folder you just made in step 3, and give it the name of the number of the mod. For example, if the mod is "resources009.s2z", call the folder "009". It should look like this:

http://img43.imageshack.us/img43/9272/guide7z1.png

5. Open mod files with Notepad++.

First, open Notepad++ (shouldn't be too difficult). Then, navigate into the extracted mod's folder. Using the same example, open the "ui" folder inside of the "009" folder. You should have some .interface files and possibly some .package files in it. Some mods even include other folders too. If the mod has the game.interface file in it, you'll want to open that with Notepad++ by right-clicking on it, then clicking Edit with Notepad++ (If you don't have that option, do Open with and find notepad++.exe). Now, Notepad++ should open up and you should have the game.interface file opened in one of the tabs. It should look like this:

http://img510.imageshack.us/img510/5851/guidenotepad1.png

6. Find and open the original game .interface or .package file.

Next, we will want to open (but not extract) the resource0.s2z file, which contains the game's original .interface and .package files. First, navigate to: C:\Program Files\Heroes of Newerth\game and like in step 4, open resource0.s2z with 7-Zip. Now, go into the ui folder in 7-Zip, and find the game.interface file. There should be around 70 interface files, in there, but we only want game.interface for our example. You can extract this file into another folder into the folder you created in step 3, and I suggest that you name the folder "original" or something similar. Now, like in step 5, open the original game.interface file you just extracted.

Before you do anything else, I suggest that you save a copy of the game.interface file with "Save As..." in Notepad++ to a new "ui" folder inside of a new folder would call "Combo", or something else if you prefer.

7. Compare the two files.

Now that we have two game.interface files open we're ready to start bringing changes over into our original file (which we're saving in a new "Combo" folder). In Notepad++, click plug-in at the top, then go into the Compare menu, then click "Compare". Here's a picture of the menu:

http://img262.imageshack.us/img262/5245/guidenotepad2.png

Now that we've done that, we should have a new window in notepad++ on the right that should look like this:

http://img182.imageshack.us/img182/4440/guidenotepad3.png

As you can see above, all the blue and violet lines and blocks on the right window are differences between the two files we have open. I opened an older version of mod 009 just to show what you might see when you compare files. In my example, the file on the left is the original game.interface file, and the one on the right is mod 009's game.interface file.

8. Making the necessary changes.

Since our original file is on the left, we must make the changes in that one. Now, use the scroll bar, and scroll slowly, and look for highlighted lines in the files, that show a part that has been modified. Here's an example:

http://img17.imageshack.us/img17/3346/guidenotepad4.png

In this picture above, you see a big block of PINK highlighted code. This means it's been ADDED into the mod. You can also tell it was added by the '+' symbols to the left of the code. So now, you'll want to copy and paste this large block of code into the left side.

Also, if the code is blue, and there are minus ( - ) symbols to the left of it, it's been removed from the code. If it's purple, it means there's something missing from those lines, and if it's blue with a >>> symbol to the left of it, it means there was a change somewhere in that line.

So now, your job is to make all the changes.

9. Repeat steps 4 to 8 for other mods.

For step 8, just make the changes to the same game.interface file you made changes to the first time, and keep saving it in the same "\combo\ui" folder.

10. Import all the other mod files from inside the mod's .s2z

If you remember in step 5, I mentioned there might be other files and folders inside of some mod's s2z files. Namely some .tga pictures, .package files, other .interface files, etc. You'll want to extract the contents of those mods into your "\combo\ui" folder. DO NOT EXTRACT THE GAME.INTERFACE FILE WITH THEM OR IT WILL OVERWRITE ALL YOUR WORK. You should not be overwriting any files at all during this step. Once that's done, you can move on to the next step.

11. Turn your mod into a .s2z mod file.

Now, navigate to your "Combo" folder. Right-click it, and in the 7-Zip menu, select "Add to 'ui.zip'". (Note that if your combo uses files outside of the ui folder, you will have to select all the files in your combo folder and then zipping.) This will create a new file next to your ui folder, and you will want to rename it to "resources013.s2z" (or any other mod number of a mod you combined with during this guide). You can now place the mod in your \Heroes of Newerth\game folder, and enjoy!


**To-do list.
- Revise the text
- Add more pictures
- Add protips

Eccentrikit
08-26-2009, 02:45 PM
Nice guide, now for me to find out how to actually make a mod >.<

Minimized
08-26-2009, 02:51 PM
Omg so awesome my eyes are bleeding.

MaxGhost
08-26-2009, 02:53 PM
Omg so awesome my eyes are bleeding.
:eek:


Nice guide, now for me to find out how to actually make a mod >.<
http://forums.heroesofnewerth.com/showthread.php?t=12217

Eccentrikit
08-26-2009, 03:05 PM
:eek:


http://forums.heroesofnewerth.com/showthread.php?t=12217

I read that, but doesn't really help much... I am pretty stupid >.<

picklefish
08-26-2009, 03:15 PM
Hah, nice maxghost. I dobut many people want to spend the time doing this though. :( Most people will just wait for a program to do it for them or full mod overs.

MaxGhost
08-26-2009, 03:52 PM
Hah, nice maxghost. I dobut many people want to spend the time doing this though. :( Most people will just wait for a program to do it for them or full mod overs.
I got tons of requests on my combo thread... hopefully this'll drop the number abit... To me it only takes around 10-15 minutes to make a combo, cause I'm used to it.

Xzarr
08-26-2009, 04:13 PM
Linux users can use Meld (http://meld.sourceforge.net/) as a GUI alternative to notepad++, or you can just use diff :>

WLT
08-26-2009, 05:09 PM
thank you i love till know i was editing with simple notepad O_O

ArmedMonkey
08-29-2009, 02:00 AM
so is it a .7z archive, or a regular .zip?

MaxGhost
08-29-2009, 07:06 AM
so is it a .7z archive, or a regular .zip?
Uncompressed zip. So in other words, if you do Right-click -> Send to -> "Compressed (zipped) folder", and rename from there, that will also work.

Zejety
09-01-2009, 02:00 PM
Very helpful guide. Thank you very much.
BTW: The newest notepad++ download appears to have the plugin pre-installed.

MaxGhost
09-01-2009, 03:48 PM
Very helpful guide. Thank you very much.
BTW: The newest notepad++ download appears to have the plugin pre-installed.
Hmm. good to know.

NiGHTsC
09-03-2009, 12:01 AM
Is there a command to reload UI without restart HoN?
something like "ReloadUI()"


Thank you.

MaxGhost
09-03-2009, 01:00 AM
Yes. Do CTRL+F8 and type in 'reloadinterfaces', but if you only want to reload the game interface, you can do 'reloadinterface game'. 'game' can be any interface name, like main for example.

Phrosen
09-03-2009, 04:28 AM
Nice tutorial.
I will try this when I get home. =)

Could someone combine and upload different mods, for those who still don't get it. (I might be one of those. :P)

NiGHTsC
09-03-2009, 10:34 AM
Yes. Do CTRL+F8 and type in 'reloadinterfaces', but if you only want to reload the game interface, you can do 'reloadinterface game'. 'game' can be any interface name, like main for example.
Cool, thanx alot!

NiGHTsC
09-03-2009, 03:22 PM
Just combine 3 mods and it took 10x faster than I thought, a mod even had only one line to paste.

MaxGhost was right, it does takes only few mins cause it took me less than 5mins to combine 3 mods.
I just open A's game.interface then the other 2, search what B/C mods have but A does not and paste all the extra codes in B/C mods into A, that's it.


You can download my combination in MaxGhost's Combination request topic
http://forums.heroesofnewerth.com/showthread.php?p=238513#post238513
-012 - Improved Buff/Debuff Indicators by Vadi
-013 - Target UI + Teammate Info by Barter
-018 - Bard's Unitframes by Bard


PS. Guess we need an interface website to host all mods/addons soon ;)

KyleN88
09-07-2009, 10:58 PM
Im having problems with turning it into a sz2 file... it just looks like a zip file to me..

NiGHTsC
09-07-2009, 11:08 PM
then rename the ".zip" to ".s2z"
Be sure to have "hide extension name" unchecked

KyleN88
09-07-2009, 11:17 PM
Its not .zip... i renamed it to resources013.s2z it just looks like a zip file.. ( it looks like the zip icon the 3 books. )

NiGHTsC
09-07-2009, 11:25 PM
same thing, just make sure the extension is ".s2z" and not ".zip".
and you shouldn't be able to open it if it is a ".s2z" file.

KyleN88
09-07-2009, 11:31 PM
Edit: FIXED THANKS A TON NIGHTSC

MaxGhost
09-07-2009, 11:43 PM
same thing, just make sure the extension is ".s2z" and not ".zip".
and you shouldn't be able to open it if it is a ".s2z" file.
You CAN open s2z's directly with 7-zip, actually.

GM8
09-08-2009, 04:29 AM
rcs merge could solve most of these things automatically...
Probably should write a program for it...

NiGHTsC
09-08-2009, 11:55 AM
You CAN open s2z's directly with 7-zip, actually.
If you associate it with 7-zip manually, yes of course, same goes to WinRAR ;)

Jager
09-17-2009, 08:55 PM
Nice guide thank you! I think the lines with something cahnged in(with the >>> next to) are colour coded green not blue though.

MaxGhost
09-17-2009, 10:09 PM
Nice guide thank you! I think the lines with something cahnged in(with the >>> next to) are colour coded green not blue though.
Yeah it's a pale green... but what difference does it really make? :P

shackwove
09-18-2009, 03:47 PM
You may want to add that you have to select ALL the files in your "combo" folder and add them to a zip (your tut says the ui folder). It wasn't too clear and might be troublesome for someone with limitated computer knowledge. Other then that i really like the tutorial and just got done combining about 8-9 mods :)

MaxGhost
09-18-2009, 03:54 PM
You may want to add that you have to select ALL the files in your "combo" folder and add them to a zip (your tut says the ui folder). It wasn't too clear and might be troublesome for someone with limitated computer knowledge. Other then that i really like the tutorial and just got done combining about 8-9 mods :)
Good point.

knallfrosch
09-18-2009, 08:27 PM
Okay either i just enabled "Hide interface" or my editing ****ed everything ... shi^t.

shackwove
09-18-2009, 08:32 PM
that's precisely why i made sure to backup the resources0 file first :D

MaxGhost
09-18-2009, 08:44 PM
that's precisely why i made sure to backup the resources0 file first :D
You shouldn't even be editing anything in resources0 at all... if you are, you're doing it wrong.

shackwove
09-18-2009, 08:57 PM
lol nvm, at first i thought to myself that i'd add the stuff directly into that file (which would work i think). I guess i still had that in mind when i posted the above... hope i won't confuse anybody

knallfrosch
09-18-2009, 08:57 PM
Hmm doesnt crash interface anymore, but...
i combined 10 + 12 but the buff/debuff icons are smaller than in 12 alone.
Though i can't find anything related in the code.

shackwove
09-18-2009, 08:59 PM
the 12 only changes 5 values in the code, 100 to 150 (twice) 100 to 200 (twice) and 14,4 to 16,4

it should be highlited in green when you compare two files

MaxGhost
09-18-2009, 09:23 PM
the 12 only changes 5 values in the code, 100 to 150 (twice) 100 to 200 (twice) and 14,4 to 16,4

it should be highlited in green when you compare two files
Plus it adds two lines (twice) of custom code for the countdown time in seconds left to show

Johnny
09-20-2009, 06:45 PM
Plox make a combo mod VOIP slider & Quick CMDs & ToggleButton =]
Save my small brain this labour.

MaxGhost
09-20-2009, 07:19 PM
Plox make a combo mod VOIP slider & Quick CMDs & ToggleButton =]
Save my small brain this labour.
This is NOT a combination request thread. The guide is really simple. Do it yourself.

Fuga
09-21-2009, 11:42 AM
no wait im blind

Squick
09-21-2009, 10:03 PM
kind of hard 2 do all steps without a mistake....i have a question is it posible 2 combine white/red colours with missing buttons ? coz i copyed both files and they don't stack, either i have Bardui with missing buttons either white/red coulours.... :( and i want both

MaxGhost
09-21-2009, 11:42 PM
kind of hard 2 do all steps without a mistake....i have a question is it posible 2 combine white/red colours with missing buttons ? coz i copyed both files and they don't stack, either i have Bardui with missing buttons either white/red coulours.... :( and i want both
Do you mean the colorblind mod or something else?

Fuga
09-22-2009, 10:31 AM
i copied from both to one gameinterface, saved it all right, right extension etc. end result was no interface till i deleted the file. :(
literally no interface at all.

SL1nkY
09-22-2009, 11:30 AM
OK I've been trying all afternoon, but this just won't work for me. I tried combining two mods, when i start up a game.. nothing, it's as if they're not even there. So then i tried extracting a mod and compressing it again without changing anything, giving it the same name as before... and still nothing (but the originals work)
It's really frustrating, as I'm pretty sure I'm doing everything correctly (and I'm a fairly decent programmer)

Any help???

I'm using windows7 btw

*edit: nevermind, found a workaround, i put the uncompressed "ui" folder in the game folder and it works :?

MaxGhost
09-22-2009, 03:32 PM
i copied from both to one gameinterface, saved it all right, right extension etc. end result was no interface till i deleted the file. :(
literally no interface at all.
You made a syntax error... try going into Language menu at the top, and find XML. If you missed something (like a quote, parentheses, semicolon, etc.) some of your code will be colored incorrectly.


OK I've been trying all afternoon, but this just won't work for me. I tried combining two mods, when i start up a game.. nothing, it's as if they're not even there. So then i tried extracting a mod and compressing it again without changing anything, giving it the same name as before... and still nothing (but the originals work)
It's really frustrating, as I'm pretty sure I'm doing everything correctly (and I'm a fairly decent programmer)

Any help???

I'm using windows7 btw

*edit: nevermind, found a workaround, i put the uncompressed "ui" folder in the game folder and it works :?
Yeah you have to have the files in the exact same paths as they are in the resources0.s2z file. It depends which file is in which folder when you make a mod. For example if you have something in the 'heroes' folder, and you edit something, your new .s2z must have a 'heroes' folder in it and then your modded stuff inside of that folder.

SL1nkY
09-22-2009, 03:44 PM
Yeah you have to have the files in the exact same paths as they are in the resources0.s2z file. It depends which file is in which folder when you make a mod. For example if you have something in the 'heroes' folder, and you edit something, your new .s2z must have a 'heroes' folder in it and then your modded stuff inside of that folder.
I get that, but this is what i don't understand: Currently in my "game" folder I got the "ui" folder with all the combined mods and it works, NOT as a .s2z file.
when i convert to .s2z it doesn't wanna work and i copied the stucture exactly.
No complaints though, the folder thing works 100%

MaxGhost
09-22-2009, 03:50 PM
I get that, but this is what i don't understand: Currently in my "game" folder I got the "ui" folder with all the combined mods and it works, NOT as a .s2z file.
when i convert to .s2z it doesn't wanna work and i copied the stucture exactly.
No complaints though, the folder thing works 100%
in the s2z, you MUST have a ui folder in it, and all the mods inside of that, depending on which mods you use.

DTS
09-23-2009, 12:49 PM
Here is "home made" video how 2 combine mods:
http://www.youtube.com/watch?v=7Y9R7RKmO1M
enjoy!

Notausgang
09-23-2009, 01:01 PM
Ooo, everyone using Notepad++ :-o

Avi1231
09-23-2009, 02:41 PM
I'm having some trouble combining mods 40,42,47. Combining the game.interface from 40,47 and the cc_panel.interface from 42,47. I can't see the CC panel currently because of a chat server outage, but when I load a practice game I can't even see the "Bard UI" button in the top-right as I could before, and I hadn't tried it out by itself, but the auto skill levelling mod isn't working either. Anyone got any ideas?

DTS
09-23-2009, 03:56 PM
Well. If u sure u doing all right - be also sure u've delete all other resoursesxxx.s2z from game holder. except resourses0 of course. and also... be sure u zip it as ZIP archive. Here you go. Should work fine (but i didn't test it) LINK (http://www.mediafire.com/?tfldzgenu1w)

Avi1231
09-24-2009, 12:07 AM
Thanks DTS! By the way, are you actually from the DotA clan DTS?

DTS, it's working great. I have no idea what I did wrong, but when I'm comparing the files you did and the ones I did I really don't see much different. The only files you had to do comparisons on were the cc_panel.interface and the game.interface files right?

Would you mind taking a quick look at the one I did (linked below).
http://www.mediafire.com/download.php?zrwtmz1mv32

One last question I have (for everyone) is, do you have to go in and recombine the mods together when one is updated? That seems to make sense but I'd almost be willing to just not even bother using more than one if I have to screw with this everytime a new version comes out.

DTS
09-24-2009, 04:57 AM
Avi1231,
If you look inside - files have different size. Make sure u compressing it like ZIP and not like 7z.

And another idea - naming rule. Prob they can't be named like xxx-xxx-xxx. Only resoursesxxx

Avi1231
09-24-2009, 06:01 AM
Yeah, I made sure to compress them as zip instead of 7z and the naming wasn't an issue. I renamed your version to something like the one I used and it works fine still. By the way, I think I found what was messing it up. Well, it appears to be one of two things. First, there are some spaces after a line around 3/4th of the way through the cc_panel file where the two packages are loaded and when I added those spaces into my version it fixed it. Second, the "bard" folder you have in your "ui" folder has the button images and such yet I don't have that in my resources047.s2z file for the Bard UI mod. Where should I get these? I can of course use what you have for now, but if they ever change I'll have to redo them.

Thanks again for your help DTS!

DTS
09-24-2009, 06:12 AM
Read Bard UI topic.. there was report bout "No Button" Trouble.

Easy fix. Just extract and add this (http://dvlp.me/gaj7) bard folder into the UI folder of the mod.
http://forums.heroesofnewerth.com/showpost.php?p=336314&postcount=115

Avi1231
09-24-2009, 06:45 AM
Got it. Thanks DTS. By the way, never answered my question: are you part of the DotA clan DTS?

DTS
09-24-2009, 07:27 AM
nope. Came from WOW...

JellyFishJay
09-28-2009, 08:47 AM
Do i have to call it Resources015? am i able to call it by it's name such as 'HealthBar' so i know whats what in my folder (:

I really don't like messy folders ^-^

<3 thankyou.

RockeyRex
09-28-2009, 10:14 AM
For it to load it has to have the resources start to it but after that it doesn't have to be numbers. For example you can name the file resources_MyMod.s2z.

MaxGhost
09-28-2009, 03:44 PM
For it to load it has to have the resources start to it but after that it doesn't have to be numbers. For example you can name the file resources_MyMod.s2z.
Yup. Numbers were just the chosen organization method, and Warchamp7's repository led mods in that direction.

IcyPhoenix
10-27-2009, 04:14 AM
Any way of doing this on Mac Os X ?
I downloaded 3 apps, eZ 7z which extracted just like the 7-zip archiver.
I downloaded text wrangler which is like Notepad, but it has no compare function.

any ideas ?

IcyPhoenix
10-27-2009, 04:21 AM
just found an app called edit rocket, it can compare files same as notepad++ on a mac, let me try this now