[MOD] Enhanced Equipment Docks (eEQ) [discontinued, forks available]

The place to discuss scripting and game modifications for X³: Terran Conflict and X³: Albion Prelude.

Moderators: Scripting / Modding Moderators, Moderators for English X Forum

Post Reply
Mad_CatMk2
Posts: 517
Joined: Sun, 22. Feb 09, 21:13
x4

Post by Mad_CatMk2 » Tue, 27. Oct 09, 05:45

hey Saetan, do you know how to work this for compatibility with Logan Abler's FDN mod?
I fly an OWP. What about you?

User avatar
Saetan
Posts: 2977
Joined: Wed, 1. Feb 06, 20:26
x3tc

Post by Saetan » Tue, 27. Oct 09, 09:37

At the moment that would be changes inside in the TDocks, the hq.xml and the scripts too. Changing the scripts is possible, but not comfortable and if you oversee something, that's bad.

Currently I'm rewriting my scripts for the next release, so the needed changes from different scripts will move into one language file. After that, gaining compatibility will be "easier", at least if it's the first install.

Mad_CatMk2
Posts: 517
Joined: Sun, 22. Feb 09, 21:13
x4

Post by Mad_CatMk2 » Tue, 27. Oct 09, 20:17

Ok, the wait is worth it heh.

Good luck on this script
I fly an OWP. What about you?

User avatar
Saetan
Posts: 2977
Joined: Wed, 1. Feb 06, 20:26
x3tc

Post by Saetan » Tue, 27. Oct 09, 20:31

If you want to test, this late afternoon I released a Release Candidate for test-purposes in the German topic. You just would have to merge the TDocks and the hq.xml.
After that the only need is too adapt the SubTypes in the language file, so they will fit the right line inside the TDocks.

Also, and that was the main reason for developing that version, thanks to Lucike, he found a way how to avoid the problem, that blueprints didn't get saved anymore in your already built PHQ if you buy them, after placing an eEQ.

If you are interested, you can try. If you do, I recommend doing backups of your savegames. If there are questions, just ask.

enhanced Equipment Docks (2.5-2.0 RC)

Mad_CatMk2
Posts: 517
Joined: Sun, 22. Feb 09, 21:13
x4

Post by Mad_CatMk2 » Wed, 28. Oct 09, 00:56

Thanks for the RC. How would I merge the Subtypes thing?
I fly an OWP. What about you?

User avatar
Saetan
Posts: 2977
Joined: Wed, 1. Feb 06, 20:26
x3tc

Post by Saetan » Wed, 28. Oct 09, 01:27

Important Note: This manual is quite old, the procedere is still the same but the files may differ in details. So don't copy the code inside the quotes anymore, as it's mentioned as possibility. Always copy the codes out of the original files.
Also in newer versions of the eEQ there got to be placeholders inserted into the TDocks, these placeholders can be overwritten by entries of other mods without causing problems for my mod.


I know, I said it gets easier in that version. But it's still quite a lot of work, especially if you are not used to do such things. Try not to be shocked ^^

Step 1:
You have to extract the types/TDocks and the types/hq.xml of both Mods out of the .cat/.dat. For that purpose I'm using the "X3 Editor 2".

Step 2:
Open the TDocks with a editor like notepad.
In the last ten lines of my TDocks you'll find the following:
1;0;0;0;0;SG_DOCK_HQ;9404;108;-1;-3;200;stations\trading_stations\argon_trading_station_scene;0;1;37;38;3500;ICON_TRG_ST_TRADING;15000;769231;25;1;5;769231;3333;0;0;SS_DOCK_A_eEQ2;
1;0;0;0;0;SG_DOCK_HQ;9408;108;-1;-3;200;stations\others\military_outpost_scene;42;1;201;38;7500;ICON_TRG_ST_TRADING;24000;2769231;25;1;5;2769231;33333;0;0;SS_DOCK_A_eEQ3;
1;0;0;0;0;SG_DOCK_HQ;9412;108;0.100000;3;200;stations\sadiablo\supply_base_scene;18;1;37;38;7500;ICON_TRG_ST_EQUIPDOCK;19500;3730769;25;1;5;3730769;100000;0;0;SS_DOCK_A_eEQ4;
1;0;0;0;0;SG_DOCK_HQ;9400;108;-1;-3;200;stations\station_scenes\others\argon_equipmentdock_scene;42;1;201;38;4000;ICON_TRG_ST_EQUIPDOCK;10500;961538;25;1;5;961538;10000;0;0;SS_DOCK_A_eEQ1;
1;0;0;0;0;SG_DOCK_HQ;9416;108;-1;-3;200;stations\sadiablo\freighter_base_scene;0;1;37;38;3500;ICON_TRG_ST_TRADING;15000;1000000;25;1;5;1000000;3333;0;0;SS_DOCK_A_eEQ5;
1;0;0;0;0;SG_DOCK_EQUIP;9402;108;-1;-3;200;stations\station_scenes\others\argon_equipmentdock_scene;42;1;201;38;4000;ICON_TRG_ST_EQUIPDOCK;10500;961538;25;1;5;961538;10000;0;0;SS_DOCK_A_eEQ1_DUMMY;
1;0;0;0;0;SG_DOCK_TRADE;9406;108;-1;-3;200;stations\trading_stations\argon_trading_station_scene;0;1;37;38;3500;ICON_TRG_ST_TRADING;15000;769231;25;1;5;769231;3333;0;0;SS_DOCK_A_eEQ2_DUMMY;
1;0;0;0;0;SG_DOCK_TRADE;9410;108;-1;-3;200;stations\others\military_outpost_scene;42;1;201;38;7500;ICON_TRG_ST_TRADING;24000;2769231;25;1;5;2769231;33333;0;0;SS_DOCK_A_eEQ3_DUMMY;
1;0;0;0;0;SG_DOCK_EQUIP;9414;108;0.100000;3;200;stations\sadiablo\supply_base_scene;18;1;37;38;7500;ICON_TRG_ST_EQUIPDOCK;19500;3730769;25;1;5;3730769;100000;0;0;SS_DOCK_A_eEQ4_DUMMY;
1;0;0;0;0;SG_DOCK_TRADE;9418;108;-1;-3;200;stations\sadiablo\freighter_base_scene;0;1;37;38;3500;ICON_TRG_ST_TRADING;15000;1000000;25;1;5;1000000;3333;0;0;SS_DOCK_A_eEQ5_DUMMY;
Copy & paste them to the end of the TDocks from the FDN (or any other mod using the TDocks too) and save it.

edit:
Also, in the first lines of the TDocks you'll find something similar to:
// Created with X3 Editor TC 0.0.24
47;58;
1;0;0;0;0;SG_DOCK_TRADE;3181;108;-1;-3;200;stations\trading_stations\argon_trading_station_scene;0;1;37;38;3500;ICON_TRG_ST_TRADING;15000;461000;25;1;5;461000;3333;0;0;SS_DOCK_A_TRADE;
1;0;0;0;0;SG_DOCK_TRADE;3381;108;-0.050000;-3;200;stations\trading_stations\split_trading_station_scene;0;3;37;38;3500;ICON_TRG_ST_TRADING;10000;450000;25;1;5;450000;3333;0;0;SS_DOCK_S_TRADE;
1;0;0;0;0;SG_DOCK_TRADE;3481;108;0.200000;3;200;stations\trading_stations\paranid_trading_station_scene;0;4;37;38;3500;ICON_TRG_ST_TRADING;12000;459000;25;1;5;459000;3333;0;0;SS_DOCK_P_TRADE;
[...]
The colored number depends on which mod the TDocks is from. It displays the number of entries in the TDocks. If you copied my entries into the TDocks of the other mod, you'll have to increase that number by ten. (5 for the eEQs, 5 for the eEQ-Dummies)
/edit

Step 3:
After that, you have to do the similar for the hq.xml. Just copy & paste the following lines out of my hq.xml into the other mods hq.xml between the section "<upgrades> ... </upgrades>". You must not post it into a section "<upgrade ...>...</upgrade>" which is inside the other section. Maybe you have to increase the indexes too.
<upgrade index="1" typename="SS_DOCK_A_eEQ1" storage="30000">
<!-- OTAS Equipment Dock: storage only -->
</upgrade>
<upgrade index="2" typename="SS_DOCK_A_eEQ2" storage="60000">
<!-- OTAS Trading Station: storage only -->
</upgrade>
<upgrade index="3" typename="SS_DOCK_A_eEQ3" storage="240000">
<!-- OTAS Commercial Port: storage only -->
</upgrade>
<upgrade index="4" typename="SS_DOCK_A_eEQ4" storage="120000">
<!-- OTAS Battleship Supply Base: storage & battleship repair only -->
<repair time="100" money="100" resources="100">
<factor class="hugeship" value="2" />
</repair>
</upgrade>
<upgrade index="5" typename="SS_DOCK_A_eEQ5" storage="90000">
<!-- OTAS Freigther Base: storage only -->
</upgrade>
After that, save it again.

Step 4:
Now you have to edit my language file (9400-L044.pck) with a editor like notepad too. The .pck must first be extracted with a programm like WinZip, WinRar or 7-zip.
<!-- Index of the eEQ-SubTypes: DON'T change them, except you know what you are doing !! -->
<t id="20000">51</t> <!-- OTAS Equipment Dock (SS_DOCK_A_eEQ1) -->
<t id="20001">48</t> <!-- OTAS Trading Station (SS_DOCK_A_eEQ2) -->
<t id="20002">49</t> <!-- OTAS Commercial Port (SS_DOCK_A_eEQ3) -->
<t id="20003">50</t> <!-- OTAS Capital Ship Supply Base (SS_DOCK_A_eEQ4) -->
<t id="20004">52</t> <!-- OTAS Freight Base (SS_DOCK_A_eEQ5) -->

<t id="20050">53</t> <!-- Dummy for OTAS Equipment Dock (SS_DOCK_A_eEQ1_DUMMY) -->
<t id="20051">54</t> <!-- Dummy for OTAS Trading Station (SS_DOCK_A_eEQ2_DUMMY) -->
<t id="20052">55</t> <!-- Dummy for OTAS Commercial Port (SS_DOCK_A_eEQ3_DUMMY) -->
<t id="20053">56</t> <!-- Dummy for OTAS Capital Ship Supply Base (SS_DOCK_A_eEQ4_DUMMY) -->
<t id="20054">57</t> <!-- Dummy for OTAS Freight Base (SS_DOCK_A_eEQ5_DUMMY) -->
Here you have to adapt the SubTypes (the numbers between the <t ...> and </t>, marked in color again). They have to fit the line in the TDocks. You can start to count them by hand (start counting with 0) or you can see the number of the line also if you open the TDocks with the "X3 Editor 2", but then you have to decrease it by one, as the X3 Editor 2 starts to count with 1 and not with 0.

edit:
PS: The highest subtype is the same as the number of entries in the TDocks (see Step 2), decreased by one.
/edit

Step 5:
Last, you have to repack your modified types/TDocks and types/hq.xml into a .cat/.dat. The TDocksWrecks is not needed there. You would have to modify it the same way as the TDocks, but if you "delete" it (out of my .cat/.dat via X3 Editor 2), there should just the debris be missing, if one of these stations gets destroyed.

Pack my language file again (gz-compression, file-extension pck) or simply copy it, saved as a .xml into your t-directory. But then you must delete the .pck-Version in there.

Then simply install the .cat/.dat's of the other mod, eEQ and your own modified ones as fake patches. But make sure, that your own cat/dat has a higher number than the ones of the other mod or the eEQ.

After that, you should be able to use both mods. No changes in my scripts are needed.
Last edited by Saetan on Sat, 16. Jul 11, 06:36, edited 11 times in total.

Mad_CatMk2
Posts: 517
Joined: Sun, 22. Feb 09, 21:13
x4

Post by Mad_CatMk2 » Wed, 28. Oct 09, 02:14

Whoa, quite a lot of editing, I'll have to look into that later (college is fun eh)

Thanks for the readme :D
I fly an OWP. What about you?

User avatar
Saetan
Posts: 2977
Joined: Wed, 1. Feb 06, 20:26
x3tc

Post by Saetan » Wed, 28. Oct 09, 08:33

Good Luck ;-)

Neaera
Posts: 33
Joined: Fri, 17. Oct 08, 15:57
x3tc

Post by Neaera » Sun, 1. Nov 09, 21:17

I've tried to do that, but I think I've failed.

Where do we find these new Equipement Docks?

I've found the FDN ones, but not yours.

User avatar
Saetan
Posts: 2977
Joined: Wed, 1. Feb 06, 20:26
x3tc

Post by Saetan » Sun, 1. Nov 09, 23:29

The eEQ's get sold at the OTAS Shipyard in Legend's Home.

User avatar
Saetan
Posts: 2977
Joined: Wed, 1. Feb 06, 20:26
x3tc

Post by Saetan » Wed, 4. Nov 09, 08:58

Mad_CatMk2 wrote:Whoa, quite a lot of editing, I'll have to look into that later (college is fun eh)
Neaera wrote:I've tried to do that, but I think I've failed.
Any response if it did work at last?

Neaera
Posts: 33
Joined: Fri, 17. Oct 08, 15:57
x3tc

Post by Neaera » Wed, 4. Nov 09, 09:41

My problem was the first line of the merged TDocks "47;57;" read by X3 Editor 2 like "Version 47, Count 57".
I've added 10 lines (5 eeQ, 5 Dummy) so, I've thought the "count" part was no longer valid, so I put 67 and, it worked, I've got them in the Shipyard OTAS.

And I will test tonight by buying them to see if they are "fonctionnal" or if I've screwed something else.


(Excuse my poor english)

User avatar
Saetan
Posts: 2977
Joined: Wed, 1. Feb 06, 20:26
x3tc

Post by Saetan » Wed, 4. Nov 09, 11:30

Neaera wrote:My problem was the first line of the merged TDocks "47;57;" read by X3 Editor 2 like "Version 47, Count 57".
I've added 10 lines (5 eeQ, 5 Dummy) so, I've thought the "count" part was no longer valid, so I put 67 and, it worked, I've got them in the Shipyard OTAS.
Sorry, forgot to say it in the description. Thanks! I'll add it.

Mad_CatMk2
Posts: 517
Joined: Sun, 22. Feb 09, 21:13
x4

Post by Mad_CatMk2 » Wed, 4. Nov 09, 20:33

Yeah, I haven't had much time to test this out...maybe later this week or next week hopefully.
I fly an OWP. What about you?

Neaera
Posts: 33
Joined: Fri, 17. Oct 08, 15:57
x3tc

Post by Neaera » Wed, 4. Nov 09, 23:52

A quick test, and it seems like the merging is a succes (And your equipement dock seems to work with Cycrow R&D).

By the way, great mod and the capital base is awesome.

*leaving for trying to get one without cheat*

Post Reply

Return to “X³: Terran Conflict / Albion Prelude - Scripts and Modding”