[SCRIPT] Player Workshops V2.0 [28.07.2009]

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

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

Post Reply
Posts: 1230
Joined: Wed, 6. Nov 02, 21:31

[SCRIPT] Player Workshops V2.0 [28.07.2009]

Post by pelador » Wed, 22. Apr 09, 16:18

Player Workshops


Download as ZIP here: Image

Extract into X3TC games directory.

As Cycrow plugin: Image

You will require Cycrows Plugin Manager for the spk file.



ZIP: Image

SPK: Image



Player workshops allows a new trading command option with any player owned equipment dock, trading station, Hub and PHQ that allows you to apply maximum upgrades (Engine Tuning, Rudder Optimisation and Cargo bay extension) to ships. It also allows the downloading of software and additional equipment. (Note only applies vanilla tech).

The player still has to pay for the services like the other races and represents the equivalent cost in resources required to provide the details. This money is taken directly from the players account.

When a ship is docked in one of the above applicable stations a new ship trade command "Workshop" becomes available. The menus provided are fairly straight forward.

Clicking on an upgrade will install the maximum upgrade value at appropriate price based on current tunings/upgrades. In the case of a ship having a maximum cargo upgrade value greater than a 1000 units it will allow increments of up to a 1000 to be installed in one go. The equipment/software sub-menu allows you to install the individual equipment or at the bottom install all available options for that ship.

Price in both cases are indicated next to the items.

A new automatic equipping mode is applied in V2.0. After configuring the class packages in the configuration menu and selecting wether tunings and cargo are upgraded, the dock will automatically equip the ship based on class and settings. It does this every 25 seconds by checking the dock ships and is not triggered at actual docking time.

Regardless of what you set in the class packages and settings for tunnings it will try to install everything missing based on your settings. However if it cant install or afford a certain piece of equipment or tunings it will ignore it and move onto the next item. It does tunings first, then cargo then equipment upgrades. Both black market settings and take monies from the dock first applies to the auto process as before.

Note that the starting and stopping of the auto process is specific to each dock and therefore you have to start it running using the ship command, similarly to stop it for a specific dock.

NOTE: You have to run the configuration menu from the hotkey to initialise and set up the workshop:

Alternatively if you have the Community Plugin Configuration installed it will load the menu for use within it. This reduces the need to define a hotkey just for the Workshop configuration menu. (Note: optional I check in set-up wether its installed)



There is a user configuration menu provided that allows the player to set-up which items of equipment become available away from the suggested defaults of "common software". This can be accessed by a user definable hotkey. This needs to be run even if wanting to just use default settings.

The configuration menu will also allow you to access the "packages" sub-menu. Here you can specify up to 10 user definable lists of bulk packages in order to install quickly packages to different types of ships in the trade menu. The configuration is independant of the main inclusion list so you can freely specify which sets of equipment/software to include without encumberance to the main include list. Packages can only be installed if all of the items in the list can be installed to the ship using the workshop.

The menu also asks wether you want funds to be taken from the station account as a priority first to the players monies. Default is no or taken directly from the player account.

This set-up menu also allows you to specify wether on the equipment/software menu if you have an item installed to remove it from a ship at half price. Default is set to no.

This set-up will also allow you to specify wether the command can be used on ships. Such that player workshops can be used on M1 and TL Carriers. However the command will only function for the ship and it's docked ships if the carrier is in space and not docked at a station.

The config menu will also allow you to increase the base value of equipment/software if you prefer to add price as an extra balancer to their availabilty, this is optional. This is known as "black market" pricing (thanks to user draffutt for the concept) and you can add between 1 and 400 % increase to the value. So if you want to double the price you would make the black market value 100% to give a total of 200%. Note however the removal of equipment (if set for use) still removes at half average price and ignores black market settings, this is to avoid a potential free cash generator.

The configuration menu can be used to set auto configuration packages by class and wether to apply max tunings and cargo upgrades automatically.

It also allows the removal of the hotkey and variables used for uninstall. (Remember to save the game after use, before removing the software).

The menu also allows you to quickly move back to suggested defaults if you prefer them.


This was set-up as a scripted interface rather than adding wares so that it can be easily adapted to various docks without the need to introduce wares on them. Thus making installation/uninstall easier aswell as more compatible with other mod uses. It also means a top-up script or pseudo production process is not required to maintain capacities, which may have interfered with Hub, PHQ or other mod dock usage with regards to ware volumes.


Text file: 9550
Trade Command: 33



As Governed by Community rules:

This script is free to use as long as you say thankyou in your topic .
Last edited by pelador on Tue, 28. Jul 09, 18:14, edited 17 times in total.

Posts: 1230
Joined: Wed, 6. Nov 02, 21:31

Post by pelador » Wed, 22. Apr 09, 16:19

Version History

V1.0 22.04.2009 beta
V1.1 22.04.2009 Correction to include boost extension.
V1.2 22.04.2009 Bug fix for transport ability with equipment
V1.3 23.04.2009 Now includes Ore Collector and optional choice to have workshops on carriers (M1s and TLs)
V1.4 26.04.2009 User definable packages now included.
V1.5 26.04.2009 Bugfix correction. Removal of setup menu on game load.
V1.6 27.04.2009 Added optional Black Market settings.
V1.7 06.05.2009 Added optional choice for monies to be taken from stations as priority and add Community Plugin configuration useage.
V1.8 11.05.2009 Bugfix correction. Cargo upgrades for ship > 1000 units.
V2.0 28.07.2009 Added Auto equipping process
Last edited by pelador on Tue, 28. Jul 09, 18:15, edited 9 times in total.

Posts: 267
Joined: Tue, 9. Dec 03, 20:51

Post by Aquitaine » Wed, 22. Apr 09, 16:35

Wonderful! I was just about to post about this to see if anyone had done anything like it. :)

Posts: 1230
Joined: Wed, 6. Nov 02, 21:31

Post by pelador » Wed, 22. Apr 09, 16:48

V1.1 Upgrade

Correction to include "Boost Extension", 1000 apologies for forgetting it. :oops:

For anyone who quickly grabbed V1.0 simply set the options to use defaults on the config menu, this will reset the variables for use. Then re-adjust them how you like. Sorry.

Posts: 1230
Joined: Wed, 6. Nov 02, 21:31

Post by pelador » Wed, 22. Apr 09, 17:21

V1.2 Bug fix:

Ensures correct transport class for upgrades.

Simply update software. No user changes required.

I'm having a bad afternoon. Glad its beta. No excuses really, apologies.

User avatar
Posts: 3066
Joined: Fri, 14. Oct 05, 21:04

Post by ezra-r » Wed, 22. Apr 09, 17:25

sounds like a great idea, ill give it a try ;)

Posts: 1230
Joined: Wed, 6. Nov 02, 21:31

Post by pelador » Wed, 22. Apr 09, 17:30

Yeah, sorry for the couple of minor hiccups, things I forget to add whilst alpha testing.

A case of "more haste less speed".

It should be relatively stable otherwise, honest :wink:

Logain Abler
Posts: 2253
Joined: Mon, 31. Oct 05, 09:44

Post by Logain Abler » Wed, 22. Apr 09, 17:46

Great script, works a treat :)

On my "must have loaded" list.


Posts: 1230
Joined: Wed, 6. Nov 02, 21:31

Post by pelador » Wed, 22. Apr 09, 17:58

V1.2 Minor edit, to ensure transport class abilities for bulk update process.

I have to apologise again, I got myself in such a tizzy having forgot the above that I was rushing to correct details.

Please consider it part of the beta exercise. I'm going to find a dark corner and stand there with a cone shaped hat with a "D" on it.

Posts: 1230
Joined: Wed, 6. Nov 02, 21:31

Post by pelador » Thu, 23. Apr 09, 07:48

V1.3 Upgrade available

Ore collector now included.

Optional choice in config menu to allow workshops to be available from carriers: M1s and TLs. Default to no. This command only becomes available when the carrier is in space and not docked.

With this new version you will need to restore defaults in the config menu and then re-apply your changes.

Posts: 18
Joined: Sat, 25. Oct 08, 02:47

Post by SilverStar95 » Thu, 23. Apr 09, 08:00

I'll watch this one until it seems to reach a stable state. And perhaps until you set up some way of detecting custom wares/upgrades to be included, as well. :)

Posts: 1230
Joined: Wed, 6. Nov 02, 21:31

Post by pelador » Thu, 23. Apr 09, 08:17

SilverStar95 wrote:I'll watch this one until it seems to reach a stable state. And perhaps until you set up some way of detecting custom wares/upgrades to be included, as well. :)
The only problem with that is the wares themselves are hardcoded as to which are identified as upgrades. Its not something I beleive you can change in TwareT definitions. So as much as I can identify those using scripting techniques that are equipment, not all tech may be equipment dependant on the mod.

However where other developments are using wares I could potentially include them as they see fit, if there is a way to recognise if their particular development is installed. This means they will have to be using standard vanilla custom entries for their use (possibly EMP if I can limit the particular entry values to specific id's). Otherwise I will have to download every mod and merge them to be able to recognise them, and in the case of some mods end up with a huge list of unwanted wares on the list which wouldnt be user freindly.

Also, and perhaps more importantly, given that various developers may have positioned the sale of their custom tech as a balancing factor or race orientation for flavourfull additions, I dont want to simply usurp their design choices by simply including them. It has to be in collaboration.

Posts: 69
Joined: Wed, 26. Mar 03, 07:13

Post by Kakarot » Thu, 23. Apr 09, 16:41

just what i wanted for my Eq dock :)

Thank you.

Posts: 45
Joined: Wed, 28. Jan 09, 13:23

Post by Tipp-Ex » Fri, 24. Apr 09, 13:51

I'll second that! Always thought it was odd player owned eq docks weren't half as useful as NPC ones. Good job and thanks :thumb_up:
Blackadder - what begins with 'come here' and ends with 'ouch'?

Baldrick - I dunno.

Blackadder - come here....

Posts: 718
Joined: Sat, 8. Nov 08, 03:51

Post by Troubleshooter11 » Fri, 24. Apr 09, 18:53

Sweet! Just what i needed. Nice job :D

Post Reply

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