|
Thread: Basic ToTE modding help? | |
|
phoenixreborn
![phoenixreborn](images/avatars/PhoenixReborn-2009.jpg)
![](images/rta.gif) ![](images/rta.gif) ![](images/rta.gif)
![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif)
Promising
Legendary Hero
Unicorn
|
posted October 18, 2007 03:00 PM |
|
|
Basic ToTE modding help?
Hello modders.
In 1.5 and 2.1 I was able to change starting resources and some other values simply by changing the numbers in the data.pak file (or dataa1 for hof).
For 3.0 trying to change the data.pak file crashes winrar. I noticed that the pak file appears to be locked, but when I click it asks for a password. Can anyone tell me the correct method?
|
|
Maurice
![Maurice](images/avatars/Maurice-2016.png)
![](images/moderator.gif)
Hero of Order
Part of the furniture
|
posted October 18, 2007 07:36 PM |
|
|
Using WinRAR, I extracted the contents of the data.pak file. One thing I noticed about the files is that they all have their file attributes set to "Read Only". Could that be the blocking issue?
If so, the work-around is simple: extract the files, make them editable, make the changes you want, make them read-only again and then zip them up again. Could it be that simple?
|
|
phoenixreborn
![phoenixreborn](images/avatars/PhoenixReborn-2009.jpg)
![](images/rta.gif) ![](images/rta.gif) ![](images/rta.gif)
![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif)
Promising
Legendary Hero
Unicorn
|
posted October 18, 2007 07:55 PM |
|
|
I was aware that they were read-only, but the way I was changing them before didn't really change it.
Now that I have unchecked read-only it allows me to save the changes.
Unfortunately I can't figure out the zip it back up part. When I try to put the changed defaultstats.xdb file back into the data.pak I still get a crash.
If I archive the file I have a data.rar, or a defaultstats.rar (or .zip)...
Were you able to effect in game changes Maurice?
edit: for some reason there is a userMODs folder, any info on that?
|
|
Maurice
![Maurice](images/avatars/Maurice-2016.png)
![](images/moderator.gif)
Hero of Order
Part of the furniture
|
posted October 18, 2007 08:42 PM |
|
Edited by Maurice at 20:43, 18 Oct 2007.
|
No, I have only extracted the files so far, and looked into it (I was mainly interested in the scripts and maps). Also, I haven't used WinRAR before, so I have no clue how that works. I was merely tossing out an idea .
Were the files in the data.pak file of the original game (and HoF) not marked as read-only?
By the way, when you have a data.rar file, just change the extension to pak, so you get a data.pak file. That should work (considering that in order to check it as a zip file, I named it data.zip ).
|
|
VokialBG
![VokialBG](images/avatars/VokialBG-2007.gif)
![](images/rta.gif) ![](images/rta.gif) ![](images/rta.gif) ![](images/rta.gif) ![](images/rta.gif)
![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif)
Honorable
Legendary Hero
First in line
|
posted October 18, 2007 08:49 PM |
|
Edited by VokialBG at 20:50, 18 Oct 2007.
|
I get the same errors, some said that they don't have problems... and just edit like in HoF.
And yes most of the files were read only. but you get them out, unchech the read-only and edit them then you can add them again. in TotE you simply can't do this. So how you guys mod this? I can't to even a single change!
____________
|
|
Maurice
![Maurice](images/avatars/Maurice-2016.png)
![](images/moderator.gif)
Hero of Order
Part of the furniture
|
posted October 18, 2007 10:57 PM |
|
Edited by Maurice at 23:01, 18 Oct 2007.
|
Ok, I just extracted a campaign mission and packaged the thing up again. One important thing to note here is that I needed to archive the whole lot as a ZIP file (not RAR!) and besides, I have to use zero compression (in WinRAR, use the "Store" option). Otherwise the editor simply wouldn't read the file. I think something similar applies to the data.pak as a whole.
When you add files to an existing archive, can you still set the compression for it? If so, you might want to look into setting it properly.
Edit: I think you can ... so choose the "Store" compression option under WinRAR (which is no compression at all).
|
|
sfidanza
![sfidanza](images/avatars/h5-ra-art-Findan.jpg)
![](images/rta.gif) ![](images/rta.gif) ![](images/rta.gif)
![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif)
Promising
Supreme Hero
|
posted October 19, 2007 02:43 AM |
|
|
It seems some of you are having difficult times modding. Let's try to solve that. ![](images/smilies/smile.gif)
First of all, PhoenixReborn, what do you mean with
"When I try to put the changed defaultstats.xdb file back into the data.pak I still get a crash."?
Do you edit the file and put it back on data.pak, thus replacing the original?!! What weird modding is this!!
You should just repack the edited file in a mod, that's all. Leave the data.pak as is. It works: no lock, no bug, no crash. ![](images/smilies/smile.gif)
The files in data.pak have always been read-only. Remove the read-only attribute and edit. It's indeed that simple.
To create a mod (as Maurice just said), it HAS TO BE a ZIP file. A rar file won't work. Once you have my_mod.zip, you can rename it to my_mod.h5u and place it in the new UserMODs/ folder. Yes, that's how it works. ![](images/smilies/wink.gif)
Alternatively, you can rename it to my_mod.h5m, and place it into Maps/. It works the same. I elaborated a little more on that in the GotP thread.
About maps and zip compression: I usually use the normal compression, and the maps are always recognized. The problem with the editor (which indeed doesn't want to open some maps) is another issue: for example, it doesn't want to open a campaign map (in the Scenario/ folder), but just rename Scenario/ to SingleMissions/ inside the archive and voilą! ![](images/smilies/smile.gif)
Actually, I think it only agrees to open maps when their inside path is either SingleMissions/ or Multiplayer/.
Does this solve all your (modding) problems? If not, detail what's happening, and we'll try again. ![](images/smilies/smile.gif)
|
|
phoenixreborn
![phoenixreborn](images/avatars/PhoenixReborn-2009.jpg)
![](images/rta.gif) ![](images/rta.gif) ![](images/rta.gif)
![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif)
Promising
Legendary Hero
Unicorn
|
posted October 19, 2007 04:26 AM |
|
|
Alright, I shall explain what I have done and you can tell me what I'm doing wrong.
1. I extracted from the data.pak the file
data/gamemechanics/rpgstats/defaultstats.xdb
2. I unchecked read only in the properties of defaultstats.xdb
3. I made my changes (changed startinghuman resources for normal difficulty) and saved defaultstats.xdb
4. I right clicked the defaultstats.xdb file, selected add to archive (compression store, type zip) and titled it resources.h5u inside the winrar program.
I was sure it was going to work because the icon changed to look like a .pak file. Renaming it to .h5m also made the icon look like a map file. It was 205 kb the size of the defaultstats.xdb file.
Unfortunately when I put the files into the userMODs folder, or the map folder, nothing changes in the game.
What step am I missing?
I appreciate the efforts to help me.
edit: For 2.1 I had two copies of the data.pak. I had one that I went into the pak and changed the resource numbers etc. and saved and I had one unmodified. If I was playing online I put the unmodified one into the data folder, if I was playing sp I would put the mod one in. The important thing is I could work right inside the big data.pak and it didn't crash my winrar.
|
|
Maurice
![Maurice](images/avatars/Maurice-2016.png)
![](images/moderator.gif)
Hero of Order
Part of the furniture
|
posted October 19, 2007 09:39 AM |
|
|
Quote: About maps and zip compression: I usually use the normal compression, and the maps are always recognized.
When I used normal compression, the editor failed to load the map. When I used store compression (i.e. no compression at all), the editor loaded it just fine.
One thing I noticed though, was that in store format, the map I extracted from the campaigns was about 2.8 Mb in size. Once I opened it in the editor, however, it got reduced to 275 Kb or so - a reduction by a factor of 10 in size. Did WinRAR just use excessive amounts of HD space to create the zip file, or does the editor automatically compress the file, even when no changes are made to it?
Odd behaviour, I'll keep an eye on that with other attempts.
One thing I'm curious about, not sure, but something I suspect: when the game starts, it loads up ALL .pak, .h5m, .h5u, etc ... files as long as they're in the right folders, regardless of actual file names? Of course, the internal file format has to be correct for its type, but it loads them then?
And which file takes precedence? Phoenix is trying to mod a file that occurs in the data.pak file; once you create a mod file from it that you offer to the game outside of the data.pak file, which one will overrule the other?
|
|
Maurice
![Maurice](images/avatars/Maurice-2016.png)
![](images/moderator.gif)
Hero of Order
Part of the furniture
|
posted October 19, 2007 09:41 AM |
|
|
Quote: The important thing is I could work right inside the big data.pak and it didn't crash my winrar.
Could it be a size issue? I believe the original data.pak file is around 1Gb. The one from TotE is 1.3Gb. Could it be that WinRAR has a size limitation for the thing you're trying to do?
|
|
CrazyPill
![CrazyPill](images/blank.gif)
![](images/rta.gif) ![](images/rta.gif)
![](images/star.gif)
Hired Hero
|
posted October 19, 2007 11:32 AM |
|
|
Quote: 4. I right clicked the defaultstats.xdb file, selected add to archive (compression store, type zip) and titled it resources.h5u inside the winrar program.
I think problem is in this step. You have to rightclick on the gamemechanics folder.
|
|
Homer171
![Homer171](images/avatars/Homer171-2015.png)
![](images/rta.gif) ![](images/rta.gif) ![](images/rta.gif)
![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif)
Promising
Supreme Hero
|
posted October 19, 2007 01:49 PM |
|
|
How can i run old Mods on 3.0?
New Pak files works just fine but if i try to add old Death Knight Mod in the game and it does not work. I haven't found any difference in paths although that might be the problem if any. The fact that Dead Knights don't have alternative shouldn't be the problem when it should still change Wraiths and Wights. Could be that the Mod haven't been working on last patches but what i need to change to make it work again?
____________
Don't be too proud of this technological terror you've constructed. The ability to destroy a planet is insignificant next to the power of the Force.
|
|
phoenixreborn
![phoenixreborn](images/avatars/PhoenixReborn-2009.jpg)
![](images/rta.gif) ![](images/rta.gif) ![](images/rta.gif)
![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif)
Promising
Legendary Hero
Unicorn
|
posted October 19, 2007 02:52 PM |
|
|
Quote:
I think problem is in this step. You have to rightclick on the gamemechanics folder.
That was it, it worked!
Once again, thanks to everyone for the help.
|
|
sfidanza
![sfidanza](images/avatars/h5-ra-art-Findan.jpg)
![](images/rta.gif) ![](images/rta.gif) ![](images/rta.gif)
![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif) ![](images/star.gif)
Promising
Supreme Hero
|
posted October 19, 2007 07:15 PM |
|
|
@PhoenixReborn: glad we could find it. ![](images/smilies/smile.gif)
By the way, I feel better about your modding method. ![](images/smilies/wink.gif)
Quote: When I used normal compression, the editor failed to load the map. When I used store compression (i.e. no compression at all), the editor loaded it just fine.
When the editor opens a map, he first unpacks it in Editor\H5MMods\. Check if it manages to do that before blocking. If it does, then it's not the unzipping causing the problem.
Of course, if you zip the same map with both methods and one works and not the other, there's obviously something. On the other hand, my editor opens maps I packaged with normal compression, so it's not that simple I guess. You can send me test files if you have some.
The 10 to 1 ratio is indeed what I get between normal compression and store. Which seems to indicate that the editor itself compresses the maps.
Quote: One thing I'm curious about, not sure, but something I suspect: when the game starts, it loads up ALL .pak, .h5m, .h5u, etc ... files as long as they're in the right folders, regardless of actual file names? Of course, the internal file format has to be correct for its type, but it loads them then?
And which file takes precedence? Phoenix is trying to mod a file that occurs in the data.pak file; once you create a mod file from it that you offer to the game outside of the data.pak file, which one will overrule the other?
Yes, as far as I know, it loads all files (actually it may load only one file when there are several versions, to be more effective, but at least it takes all into account). The file that takes precedence is the one with the latest modified date. That's why older mods don't work, until you update the modified date (of the files inside the archive, not the archive itself). The name of the mod/map... has no importance.
@Homer171: this modified date thing is exactly why your mod doesn't work. If you're talking about Arstahd's DarkKnight mod, then I've updated it on AoH: just re-download and you should be fine.
|
|
Maurice
![Maurice](images/avatars/Maurice-2016.png)
![](images/moderator.gif)
Hero of Order
Part of the furniture
|
posted October 19, 2007 08:56 PM |
|
|
I'll check the Editor/H5MMods directory next time I try it. Wonder what's up . At least it's nice that the editor compresses it automatically, even when you're not making any changes - just loading is enough.
The date thingy is also good to know. Now I don't have any older mods installed, but it's quite important when using those .
|
|
|
|