X Rebirth

X Rebirth

Station Push wares
Browser_ice 16 Aug, 2016 @ 5:56pm
Ship assigned to a CV vs your current script version
I think I know why a ship assigned to a CV will go sell elsewhere.

What is the first think your script do ?
It check if player has a ship that has cargo in it that isn't part of any trades. Then it searchs for a trade for any of its cargo merchandise and then makes that trade.

Now keep this in mind and think about how your script reacts in the following situation:
1) Ship-X is assigned to CV-X
2) CV-X is currently building an upgrade or the first station part.
3) because CV is busy building something, it has no trading offers
4) Ship-X should then stay nearby and await for when CV has a need

what happens is that 4) does not happen because your script has booked a trade elsewhere for it because it has cargo and not selling it.

Therefore the first thing your script should do is :

- is ship assigned to a CV
--- yes, then does ship have cargo
--------- yes, then leave it alone
--------- no, then is CV currently having any trade needs
----------------- yes, then look for any trade the CV is currently needing and go fetch it
----------------- no, then leave it alone
--- no, then proceed with the rest of the script

Now I don't knwo about other players, but when I assign a ship to a CV, its because of one of the following reasons:
1) I loaded up all the needed materials in that ship for the CV to use it when needed
2) or its because I want that ship to go look for trades the CV needs

Having said all this, it depends on what you think the playing community would want your script to do when they assign a ship to a CV. Does it bother them that when the CV would need something that its assigned ship is elsewhere ?

Its all about time to build. Having a loaded ship assigned to a CV will speed up the building because you don't have to wait for someone to agree to the trade and then travel to the CV.