Page 1 of 11

[MOD] Station Engineers

Posted: Sun, 1. Feb 15, 13:42
by w.evans
´╗┐This tiny mod alters only two parameters to make it possible to assign Engineers to Stations. They should then act in exactly the same way as NPC Engineers in NPC Stations -- repair hull up to 100%, repair surface elements, and use Construction URVs to hasten repairs. Speed of repair will depend on the Engineer's Engineering skill, and the number of Construction URVs available.

Just checked, and it looks like the vanilla scripts are set to repair Stations to 100% by default.

edit: Huh. Didn't realize that you can't ask a CV to redeploy.

_____
What's New?

5.Jul.2015 - v0.05 is up.

Compatibility update. Now compatible with Linux and Mac versions. (v0.04 didn't work. This one should.)

Thanks to CulunTse for verifying and testing the linux update.

_____
As of v0.03, this is the mod in its entirety:

Code: Select all

<?xml version="1.0" encoding="utf-8"?>
<diff>
	<replace sel="//cue[@name='OnBoardComm']/actions/do_elseif[@value='not player.platform']/add_player_choice[@text='{1002,3008}']/@choiceparam">[0, 0, 'zone', player.primaryship.zone, null, null, 'selectplayerobject', ['cEngineer_worksomewhere_objectselected', null, null, true, false, false, false, true]]</replace>

	<replace sel="//cue[@name='OnBoardComm']/actions/do_if[@value='@player.platform.container.isplayerowned and @player.platform.container.isclass.ship']/@value">@player.platform.container.isplayerowned</replace>
</diff>
in md\NPC_Engineer.xml

_____
The file is available here:

http://www.nexusmods.com/xrebirth/mods/442/?

_____
Compatibility:

This mod is current as of X:R 4.00
Compatible with X:R 3.61

Compatible with Windows, Linux, and Mac versions of X Rebirth.

Fairly early in this little mod's development, eMYNOCK very graciously contributed code that was used in this mod. That code has since been published in eMYNOCK's two mods:

Player Shipyards and Enhancements
and Give us more Cloth please!

This mod is therefore incompatible with eMYNOCK's two mods. However, since eMYNOCK's mods are superior, I suggest that anyone interested in one of the two above mods drop this one and use that instead.

Also incompatible with:

mihaib's Repack Construction Vessel
Vim Razz' Human Resources

_____
Check out my other mods for X Rebirth:
MarineRebalance,
BetterAutoAim,
SmalltalkHack,
Epic Capital Ship Shields,
Engineer Drone Fix,
Slightly More Useful Plot Station,
DockAllDrones,
Miscellaneous OOZ Combat Tweaks,
Miscellaneous IZ Combat Tweaks,
DifficultyHack

Posted: Sun, 1. Feb 15, 14:04
by Sparky Sparkycorp
Epic 8)

Smallest, lovely mod ever? Hehe

Posted: Sun, 1. Feb 15, 14:12
by w.evans
Enjoy! (Hope it works.) *Fingers crossed*

Posted: Sun, 1. Feb 15, 14:20
by YorrickVander
Nice one :) You have any plans to add ware useage to the engineers? I did some experiments with limiting npc faction budgets a while back which would tie in well with that for actual economic warfare. I'll pm you the very early test scripts if you're interested as I barely have time to bug fix my current stuff atm without a new large project.

Posted: Sun, 1. Feb 15, 14:36
by Sparky Sparkycorp
Ware usage would lilely have Scoob dancing in front of his monitor :)

Is the general idea for that sort of think to automate/semi-automate it via buy orders?

Posted: Sun, 1. Feb 15, 14:41
by w.evans
Not at the moment, but doable. Mod won't be so tiny then, though.

Alter the NPC engineers to use wares as well?

Posted: Sun, 1. Feb 15, 14:43
by alexalsp
Great mod and idea. Is it possible to improve the mod , what would the engineer repaired the station up to 100 %. That would be great.

Posted: Sun, 1. Feb 15, 14:46
by w.evans
@alexalsp, yup. Just checked the vanilla engineer script and it looks like it'll repair to 100% by default.

Code: Select all

      <do_if value="this.defensible.isclass.station">
        <set_value name="$hulldamagelimit" exact="100" comment="below what percentage hull is a component considered damaged"/>
      </do_if>

Posted: Sun, 1. Feb 15, 15:02
by alexalsp
w.evans wrote:@alexalsp, yup. Just checked the vanilla engineer script and it looks like it'll repair to 100% by default.

Code: Select all

      <do_if value="this.defensible.isclass.station">
        <set_value name="$hulldamagelimit" exact="100" comment="below what percentage hull is a component considered damaged"/>
      </do_if>
Thank you. 'll check.

Posted: Sun, 1. Feb 15, 15:44
by w.evans
YorrickVander wrote:I'll pm you the very early test scripts if you're interested as I barely have time to bug fix my current stuff atm without a new large project.
Would love to see your test scripts. No guarantees on implementing them though. I'll have to understand them first, and I don't know if I can!

Posted: Sun, 1. Feb 15, 15:49
by w.evans
Also, would anyone happen to know where the ware usage of Architects are to be found? Looked in NPC_Architect.xml (architects don't seem to have an aiscript), and the only relevant things I could find there are blocks for making ware lists for drones and ammunition, and to turn those ware lists to order lists, and order lists to buy orders.

Posted: Sun, 1. Feb 15, 16:09
by euclid
To my best knowledge the architect only deals with ammo & drones. He also handles the wares required for repairs & extension but this is done seperately.

So I'm not sure why someone would have the engineer handling wares.

Cheers Euclid

Posted: Sun, 1. Feb 15, 16:15
by w.evans
Hi euclid,

didn't notice that you're a mod before now. Congratulations?

It's to make the engineer use wares to repair stations, the way that architects use wares to repair stations in vanilla.

Posted: Sun, 1. Feb 15, 16:27
by euclid
w.evans wrote:Hi euclid,

didn't notice that you're a mod before now. Congratulations?
Heheh, cheers, they kind of forced me into that. Let's see how it goes ;-)
w.evans wrote: It's to make the engineer use wares to repair stations, the way that architects use wares to repair stations in vanilla.
The engineer will repair a station to 100% and that includes destroyed subsystems. So there is no need for him to acquiring wares for that.

However, if you want to alter that then it'll be a major "hack" because you need the corresponding repair list from the architect and hence the associated UI part. Also the wares buy offer is usually issued at the CV so you need to change that to the station.

In short: this would require quite some script & "hack" work. Not sure it's worth it.

Cheers Euclid

Posted: Sun, 1. Feb 15, 16:30
by w.evans
Thinking about it, would provide a nice additional resource sink if all stations required wares to repair, though, if it works. Although it could also cripple the economy with NPC stations requiring wares which the economy is unable to provide.