Page 1 of 2

[BONUS Plugin] Exchange Freight v1.1 04-8-05

Posted: Fri, 5. Aug 05, 03:00
by Burianek
Hi all,

A new plugin for you to enjoy.
Available in the bonus plugins package.
Scripter: Vassenego

From the readme:
readme wrote: What's the script for?

As the name suggests, the script allows you to exchange freight between ships owned by the player. The player no longer needs to be in either of the ships or even in the same sector to transfer freight from one ship to another.

Attention: Executing this order on a ship cancels all other orders. So you have to issue new orders to your ship afterwards.




What does it do?

As stated, it transfers freight from one player owned ship to any other player owned ship within transporter range. Therefore both ships have to be in space and in the same sector. Naturally at least one of the ships has to be equipped with a transporter device. If you are transferring shields, they will be installed on the targeted ship automatically if they are better than the currently installed shields. Weapons will not be automatically installed. They just get transferred into the cargo hold of the target ship and have to be installed manually via the ships menu, if desired.




What can't it do?

Because of limitations of the script editor, you cannot choose a docked ship as a target, so both ships have to be in space to make the transport work. If a ship is docked, the command is not available. It is not possible to transfer ship upgrades or extensions (like the transporter device itself, freight scanner, or anything else like this). If the player ship is one of the two ships involved in the exchange, then it is possible to transfer command extensions using this command.
The script editor doesn't know if the command was executed successfully, so you always get the "Command Accepted" message when the command is run, but this doesn't necessarily mean that the freight really got transferred. If the transport failed for any reason, you will get an error message written to the player log (see Error messages). If the script successfully transferred the freight, no message is written (there's already enough spam within the log book). Another limitation of the script is that it can't check if there is a third ship equipped with a transporter device in range, so at least one of the ships taking part in the transfer has to be equipped with a transporter device. Otherwise, the transport will fail and an error message will show up in your log.



What won't it do?

There are some fictional and logical limitations to the script.
As stated already, to transport the freight there has to be a transporter device installed in one of the ships involved.
The transfer will only be successful within the normal transporter range of the transporter device. The range is five km, and both ships must be within the same sector. If the ships are flying around when you try to transport cargo, it might occur that they leave transporter range, so it's best to stop them before you command them to exchange their cargo.
Only player owned ships can be targeted for transport.
Negative amounts of freight are not allowed. If you want to transfer a ware back, you must execute the command from the other ship.
You cannot transfer freight to the same ship.
To keep it simple (I'm not a good scripter, this is just the result of playing around to get familiar with the script editor ;-) ) the script will only transfer the exact amount of goods given during the command routine. If this is not possible for any reason (cargo limitations or not enough wares), no freight will be transferred and an error message will be created. This is true even if the transport of a smaller amount of wares would have been possible.
The script will not transfer any freight which is currently installed on the source ship (e.g shields and lasers). So you'll have to uninstall them first if you want to transport them. ATTENTION: Missiles are handled differently, they will always get transfered even if they are the currently selected missile. Keep this in mind, or else the source ship may suddenly have no more missiles installed.
Finally, even if it would be possible, the script will not tranfer wares to "non-ships" like Squash Mines, Navigation Relay Satellites, Advanced Satellites, Lasertowers, and Fighterdrones. (ATTENTION: In modifed universes, targets might exist which are not specifically excluded by the script routine and so freight might get transfered without the chance to transport it back. This could cause the loss of the freight. The script should be adjusted for these mods or used with caution.)



Error Messages

As said, every failed attempt to transfer freight creates an error message in the player log. Here is an overview of the possible messages and their meaning (though I hope they are self explanatory in most cases)

- "ships are the same." - The source ship is identical to the targeted ship.
- "ships are in different sectors." - The source ship is not in the same sector as the targeted ship. This might be caused by movement of both ships (docking somewhere or jumping away) or you might have accidentally switched to another sector in the galaxy map.
- "ships are not in transporter range of each other." - The ships are within the same sector, but the distance between them is bigger than 5km.
- "transporter device needed." - At least one of the ships must have a transporter device installed.
- "not enough freight to transfer." - The specified amount of goods is higher than the amount of this ware in the cargo hold. This may mean that you are trying to transfer installed equipment (e.g. shields or lasers). - See: 4. What won't it do?
- "not enough free cargo space." - The target ship has insufficient room in its cargo hold. This might mean that you are trying to transfer too much freight or it might mean that the target ship is not capable of carrying the freight's transport class.
- "negative amount." - The amount of freight you are trying to transfer is 0 or below, which is pretty senseless ;-) To transport freight from the target ship to the source ship, just execute the command from the other ship.
- "target is not a ship." - The target is not a real ship (like Navigation Satellites, Lasertowers, Squash Mines or Fighterdrones). ATTENTION: Modified universes may define other objects as player owned, which might not be recognized as invalid targets by the script. The command might then be executed and the freight may get lost.



How to use it

After installing the script, you will see on every player owned ship a new command "Transfer freight ..." in the "Special..." command category.
After selecting the command, choose the ware you want to transfer from the cargo hold of the executing ship. Then enter the amount of goods you want to transfer (only positive integers will work). Next, the galaxy map opens and you select the target ship to transfer the wares to. Hit enter to confirm your inputs or "Esc" to cancel the command. After you choose the target ship and confirm your selection by hitting enter you're brought back to the ship command menu. The freight Should be transferred. If not, an error message should be shown in your player log (see 5. Error Messages)



How to use it (fast)

Step -> What to do

1 -> Select command
2 -> Choose freight
3 -> Enter amount
4 -> Select target ship
5 -> done

Posted: Tue, 9. Aug 05, 20:09
by VincentTH
The problem with using this feature is that there is NO WAY to know when the 2 ships are within 5km of each other (unless you fly one of the ships yourself, which kinda defeat the purpose of having the script itself).

It would be much better that the 1 of the 2 ships for which the command was issued to, start with a "follow" order. For now, it must be done by hand first, before the exchange command can be issued.

My 2 cents.

Posted: Tue, 9. Aug 05, 21:12
by The Great Stonk
you can always order 1 ship to move to the position of the other...

Posted: Tue, 9. Aug 05, 22:31
by Carl Sumner
This is very good for ships that are flyable. However, I use a few "Storage Hulks" parked at various stations. Flying them out of the station is not a safe thing to do (no shields, minimal hull).

I suspect that the script language does not allow access to ships in stations, though. :wink:

Posted: Wed, 10. Aug 05, 00:21
by Burianek
VincentTH wrote: It would be much better that the 1 of the 2 ships for which the command was issued to, start with a "follow" order. For now, it must be done by hand first, before the exchange command can be issued.
My 2 cents.
You can issue the follow order yourself first right? And then effect the transfer?
Carl Sumner wrote:I suspect that the script language does not allow access to ships in stations, though.
Not in a user friendly manner, no.

Posted: Wed, 10. Aug 05, 08:11
by VincentTH
The problem with follow order is that if the target does not move, the ships that takes the order to follow would not move either.
And there are no guarantee that after the move (or move to position order) that they are within 5km of each other.

Posted: Wed, 10. Aug 05, 18:11
by moggy2
just out of curiosity, is there anyone who can tell me how this new script compares to Xai Corporation's Remote Transporter Device Software?

I haven't had a chance to play X2 since the new bonus pack was released.

Posted: Wed, 10. Aug 05, 23:42
by VincentTH
moggy2,

I tried it but give up, as it simply does not work for me. I have mentioned the reason for it above.

Posted: Thu, 11. Aug 05, 02:23
by Burianek
VincentTH wrote:moggy2,

I tried it but give up, as it simply does not work for me. I have mentioned the reason for it above.
Do you think widening the range out a bit would solve the problem?

You would agree that there should be some allowable physical range to be able to beam goods right? You don't think they should be allowed to be beamed across the universe?

Cheers.

Posted: Thu, 11. Aug 05, 03:16
by VincentTH
No, I don't think widening the range solve the problem, I would much prefer the 5km range.

The problem is that the user has no way to know how far the ships are from each other. The game only shows the distance between the ship you are flying and a target ship. The only way - other than flying one of the ship - I know of is to place one ship in the monitor (Shift-F1), activate the monitor/remote control (F3), then target the second ship remotely, to know for sure that the 2nd ship is in range. That procedure is, however, complicated, and requires a lot of key strokes.

The best way to solve this problem is for the script to issue some command(s) to make the ships move within 5km of each other prior to doing the freight exchange. The command "Ship A follows ship B" would not cut it, because if B is stationary, A would not move. Only a script (or the player fliying ship A) knows how to place ship A within 5km of ship B.

Posted: Thu, 11. Aug 05, 03:28
by moggy2
you can tell the distance by looking at the sector map. By default 1 square is 8km across, by zooming in(home key iirc) one square becomes 4km across and if the ships are within one square then you can transport.

The biggest problem I can see here is that the signed script cancels the ship's currect command whether you're in range or not. If you're not in range, you then have to start the ship up moving again before you can attempt another transportation. The Xai Corp script doesn't have that problem since it's on a auxiliary ship command slot instead of a special autopilot command.

Posted: Fri, 12. Aug 05, 01:03
by Burianek
This is certainly valuable feedback.

I'm against having the script move either of the ships. Issuing a move to position command on ship A and then highlighting ship B that you want to move to, should place them within 5 km shouldn't it?

I agree with moggy's suggestion. I'd think it'd be a good idea to run this script in one of the additional ship commands so that you can issue it while the ship is approaching and it won't cancel the move order.

If I catch Vassenego in the chat I'll talk to him about it.

Cheers.

Posted: Fri, 12. Aug 05, 03:23
by moggy2
If I may make another suggestion about the interface.

The command is almost instantaneous, I see no problem with displaying any messages generated imediately using the command

Code: Select all

send incoming message $msg to player: display it=[TRUE]
Infact it actually improves the users experience by not forcing them to quit the command window to open the pilots log to find out what actually went wrong.

Does the error message mention the range between the two ships when they're out of range? It would probably help if it did, if it doesn't already.

Posted: Fri, 12. Aug 05, 05:43
by Burianek
Another good point.
Keep the feedback coming. :)
Cheers.

Posted: Fri, 12. Aug 05, 10:21
by jlehtone
VincentTH wrote:The command "Ship A follows ship B" would not cut it, because if B is stationary, A would not move. Only a script (or the player fliying ship A) knows how to place ship A within 5km of ship B.
I have not experimented with the different formation options for wingmen, so I do not know what they do or how they have been implemented, but from their mere existence I make the assumption that there either is or should be functionality to bring ships into (closed) formation. So is it feasible and worth it to have navigational command: "Move Ship A into formation X with Ship B"? That should probably call "Ship A follows ship B" on completion.

Posted: Sun, 14. Aug 05, 04:02
by Birdman
I have tried this a few times and it seems to work quite well (just have to watch remaining capacity). Since this was meant for out of sector transporter use, I just have the one ship "move to position" of the other with the first stopped (usually having done a "move to position" itself. This results in almost zero to zero range (how many times have you had a remote TL go and offload wares at a remote location). The flying time is a few seconds at most.

I've transferred weapons (BPPCs, GPPCs) and shields (125Mw) to my Python from a Dolphin, also to my Raptor (even though the Dolphin could land) just to check it out.

As far as the 'follow command', I have used that to get another ship within transporter range many times. Ship B stationary, ship A moving in on it ( I've been in B (my Ray), performing other maintenance on my empire, and need more E-Cells after multiple jumps killing Xenon, so I have a Iguana come in for a quick fill-up.

Posted: Sun, 14. Aug 05, 06:13
by Burianek
I was pretty sure that at least the move to position commands were pretty accurate. It's good to hear that these will place two ships within range of eachother.

and jlehtone, when you issue a follow command, all of the follower ships will form up in the formation set in the command console of the lead ship. That's how that works.

Cheers.

Posted: Sun, 14. Aug 05, 18:50
by moggy2
another thought.

When you don't have a transporter device available the command still appears, but greyed out. It would be nice if it just dissappeared instead.

For me, I have a lot of other commands in the menus and I find it irritating having them clogged up by commands I can't use. Also, iirc only 16 out of the 32 command slots for a menu can be shown at one time.

btw this also goes for the pilot management commands. If I have no pilots I have no need for the commands.

Last thought. There isn't a position for a script interface consultant available is there? ;)

Posted: Sun, 14. Aug 05, 19:45
by jlehtone
Burianek wrote:when you issue a follow command, all of the follower ships will form up in the formation set in the command console of the lead ship. That's how that works.
Ahh, I should probably then invest on some ships and look outside. I did have a fully maxed Pegasos and Disco to follow my Nova, but for some reason they look more like spaceflys whirling around (particularly on SETA). Usually on closing the next gate they finally settle to some wing position. On next sector the same repeats. I wonder what formation I had on a Perseus when I asked the Hercules to follow. If only I had not pulled the hand-brake...

Posted: Sun, 14. Aug 05, 21:08
by Burianek
moggy2 wrote:another thought.

When you don't have a transporter device available the command still appears, but greyed out. It would be nice if it just dissappeared instead.
Agreed wholeheartedly.
Convention for the interface for any script should generally be (imho):
  • - required wares not present = command not displayed at all
    - required wares present but 'situation' ship is in isn't correct (wrong item targeted, no homebase set, etc.) = command displayed greyed out
    - required wares present and ship is in correct 'situation' = command is useable and active
Good feedback.
I'll try to get that into the next version if possible.
Cheers.