X3: Terran Conflict
0 of 0

File information

Last updated

Original upload

Created by

terodil

Uploaded by

dracolucis

Virus scan

Safe to use

Tags for this mod

About this mod

Provide the player with highly customisable options for maintaining ships, managing essential wares on board, and training marines.

Permissions and credits
Changelogs
shipServices
by terodil

Current version: 1.1

Use cases:
  • You want ships to be able to slowly repair their own hull over time, and/or carriers to be able to repair their docked fighters.
  • You think expert engineers should be able to reduce repair costs.
  • You want special ships, like the Aran or (via mods) the Mobile Repair Ship, to do their name justice and act as actual mobile repair bases.
  • You want to be able to train marines on your flagships.
  • You want to use excess generator energy to create energy cells on ships.
  • You want drone carriers to do their name justice and produce their own drones.
  • You want to pick and choose among these options and to make this as cheaty or as punishing as you want.

How do I use this mod?
Any ship that wants to use these services needs to have the 'Supply Command Software' upgrade installed (available from Argon Equipment docks and some Terran/ATF installations). The new functionality is then accessible via 'Special' -> 'Ship Services'. That will open the local menu.

Local Menu
In the local menu, you can enable or disable each protocol individually, as long as it's available for the given ship. As a general note, bigger ships have better performance than smaller ships, i.e. they can produce more energy cells per time, and they can repair faster. Obviously, they also take longer to repair.
  • Energy Cell generator: Once enabled, the ship's on-board generators will store excess energy in the form of Energy Cells in their cargo bay. You can either accept the default for the ship's class, or set an individual quantity up to which the generator should stock ECs. The generator is the only protocol that operates for free (apart from buying the Supply Software).
  • Self-repair: Once enabled, the ship will slowly repair its own hull over time. How long that takes and how much it costs depends on your choices in the global settings (see below), and the details will be shown here. Marines (if available, and if this mechanic is enabled) can reduce the cost. That will also be shown here.
  • Dock repair: Once enabled, the ship will slowly repair ships docked to it. Obviously, this requires the ship to be able to dock other ships. The options are the same as for the self-repair protocol.
  • Area-of-effect repair: Two ships, the Aran and the Mobile Repair Base (the latter being unobtainable in vanilla, but in the game files and made available by a few mods), really scream 'lost tactical opportunity'. If you enable this option, these lumbering behemoths will repair vessels parked in space in their vicinity, as long as no enemies are nearby. They are also particularly efficient and repair with twice the speed of an M1.
  • Marine training: M1s and TLs are large enough to host dedicated marine training facilities. Once enabled, your marines will slowly level up their skills while on board. Credit cost and the time required are, again, defined in the global settings.
  • Drone carrier support: The drone carriers with their drone haulers were unfinished in the game. I decided I wanted to give them a little more functionality. Now they can produce their own drones, should you wish to enable this. How much this costs and how fast they can do it depends on the global settings.
If you change any of the settings, be sure to hit 'apply and close'. Escaping the menu will quit without saving any changes.
You can also access the global menu from here.

Global Menu
In the global menu, you can tweak almost all aspects of this mod, as well as make changes across all your ships.
  • You can see a global summary of expenses for the different protocols here.
  • You can set a credit limit for ship services. While you don't have enough money in your account, they will suspend operations (bar the EC Generator, which is free) until more credits become available, at which point they will resume automatically.
  • You can set the general performance of the EC Generator by setting a benchmark value for an M1, the highest-performing ship class. All other ships derive their EC Generator performance from this value (see below).
  • You can set how long it takes an M1 to repair an M3, again, this is a benchmark value. If a lower-class ship repairs itself (or another), it will take longer. It will take even longer if it's not an M3 to be repaired, but an M6 or an M2, for example (see below).
  • You can set how much this service costs you. You can make this as cheaty or as punishing as you like by changing the multiplier which is given as percent of the (approximate) purchase price. 100 = a repair costs about as much as it would to buy the ship, 50 = it costs only half, 200 = it costs double.
  • You can set by how much, in percent, on-board marines highly skilled in engineering can reduce repair costs. The effective reduction scales by their skill, noname engineers will hardly save anything, while a near-full complement of five-star engineers will reach this value.
  • Large ships (M1, TL) can install training facilities for marines. This includes basic skill seminars as well as a holodeck for combat training. You can set both how long it would take to train a marine from 0 to 100 in all skills, and how much it would cost you.
  • Dedicated drone carriers (e.g., the Argon Griffon or the Teladi Cormorant) can produce fighter drones in sets of 10, 7 of which are Mk. 1 and 3 are Mk. 2. You can set cost and production performance here.
  • If you wish, you can globally suspend operations of specific modules, until you order them to resume again.
  • In Mass Operations, you can order all your ships to activate or deactivate certain modules at once. This can save a lot of time if you just bought a ton of traders that should generate EC, or if you decide that you don't want any of your ships to repair themselves any more.
  • You can also enable/disable a script that activates the desired modules automatically for all new ships (purchased or captured). This is an experimental feature, not really optimised and can slow down the game if you have a lot of ships, hence the red warning text regarding performance.
  • The advanced settings allow an experienced user to set certain options with potentially high performance impact. You really should not need to use any. The debugging feature also sits here (0 = default, none, 4 = full debug logging), if things should go wrong. You can also issue order 66 here, which stops all running scripts and frees all memory used by this mod.

A (rather technical) note on the performance of ship services
The higher the ship class, the better its performance in general, and the higher the effort required to repair it. If you are interested in the details, carry on reading; otherwise, you can skip the rest of this section without missing anything.

This is implemented via a matrix of multipliers that affect the time required to complete an operation. The first multiplier depends on the ship doing the job, the 'subject'. If you go by the defaults that come with this mod, a M1 has a subject multiplier of 100, whereas a M3 has a subject multiplier of 1000, i.e. the M3 would take 10 times as long to repair itself than it would take the M1 to repair the same M3 (if docked).

The second multiplier depends on the ship having the job done to it, the 'object'. If you go by the defaults, a M3 has an object multiplier of 100, whereas an M2 has an object multiplier of 5000, i.e. if an Aran had both to repair, the M2 would take 50 times as long to get repaired than the M3.

Combined with the reference value given in the global options ('how long does it take an M1 to repair an M3'), you get a matrix of repair times that you can fit entirely to your liking. The multipliers can be changed in the t-file, if you want, I couldn't be bothered making an in-game menu for them... yet. Or maybe forever.

t-file IDdefaultdescription
*  101000How much longer it takes a small ship compared to an M1 to repair an M3 (usually, self only), in percent
*  11 500How much longer it takes a medium ship (M6, TM) compared to an M1 to repair an M3, in percent
*  12 250How much longer it takes a larger `carrier` (M7, M2, TL) compared to an M1 to repair an M3, in percent
*  13 100Reference scalar (should really be 100), how long it should take an M1 to repair an M3, in percent
*  14  50How much longer it takes a Mobile Repair Base / Aran compared to an M1 to repair an M3, in percent
*  15 100Reference scalar (should really be 100), how long it should take to repair a small ship, in percent
*  16 500How much longer, in percent, a medium ship takes compared to an M3 to be repaired
*  172500How much longer, in percent, an M7 takes... etc.
*  185000How much longer, in percent, a large ship (M1, M2, TL) takes... etc.


Why this mod? There's already <X>.
I am exceedingly grateful for the inspiration by Logain Abler (esp. his capital ship ec generator and the drone carrier scripts) and by tatakau and Dr. Bullwinkle (for the marine repair and training scripts), but I wanted to offer a one-stop solution with less frills, more adaptability, and better management options. (It's also a watered down version of my replicator script which implemented actual ware production and ware consumption on ships, which, while nice to watch, wasn't sufficiently practical to release due to cargo space issues.)

This is a cheat!
Yes and no. You can make it into a cheat by setting the global options in a certain way, or you can make it exceedingly punishing (and not actually worth using) by setting them in a different way. My objective was to give you the options and the tools to play the game the way you want. The default is what I like to play with, slightly in my favour but, IMO, still reasonable; pick, choose and adjust the way you like.

How large is the impact on PC performance?
Low, although ultimately that depends on how many of your ships have one or more of the protocols running. In my tests with hundreds of ships I have been fine, but if you really run into performance issues, you can always reduce the number of ships using any of the protocols (e.g., just use a carrier with the dock repair option instead of the self-repair option on every individual fighter, which really doesn't make much sense anyway).

Note that the auto-enable protocol function available in the global options can potentially put a significant strain on performance, which is why it's switched off by default. You can use it, but if you run into issues, this is the first switch I'd disable, especially since the functionality is readily available with the mass operation options at a far lower impact (though no longer automatic).

How do I install this mod?
There are two folders in the zip file. Extract both ('t' and 'scripts') and copy them into the base game directory (in the case of X3TC) or into the addon folder under the base game directory (in the case of X3AP).
You need to have tagged your game as ***modified*** (a lot of other mods do this already), otherwise check the web for instructions (keyword 'Thereshallbewings').

How do I update a previous installation?
Same process as during installation; overwrite when asked.

How can I activate or deactivate specific services?
When installed, nothing actually happens until you start a protocol on one of your ships. You can disable the protocols the same way, or by using the mass operations in the global menu.

How can I deinstall this mod?
This script can be safely removed from your savegame if you take the following steps:
  • Via the global administration menu, issue order 66 (under 'advanced options'). This will stop all running scripts and free all memory, but may need a little time to finish.
  • Wait around 1.5 minutes (at the default interval of 30s, correspondingly longer if you increased it) to be sure everything is truly gone.
  • Save the game, and quit the game.
  • Delete the files you copied during installation.
  • Start the game, and load your savegame. Done.

Halp! I discovered a bug!
Congratulations! You can keep it! ... no, in seriousness, I'm sorry that it happened, and I'd be grateful if you could report it here or on the egosoft forums so I can fix it. To help me analyse the situation, it would be ideal if you could set the debug level to 4 (global menu -> advanced options) and keep the game running for a minute or two, then find the log07770.txt file in your documents folder (usually users\yourusername\documents\Egosoft\X3AP) and copy its content either into your post or store it somewhere online where I can access it.

Compatibility
Usable with X3TC and AP, regardless of version.
I tried not to step on anybody's toes and consulted the reference lists to find free slots. I use pageID 7770 and command slot 554, if another script uses those too, there will be issues. Problems might also arise if you have mods altering the game on a fundamental level, e.g. how marine skills work.