EnglishGermanFrenchRussianItalianSpanish
Log inRegister
 
[Script][Mar/17/2009] Transfer Freight via Drones - working
Post new topic Reply to topic Goto page 1, 2, 3  Next
View previous topic :: View next topic
Author Message
Tim-O





Joined: 15 Dec 2005
Posts: 182 on topic

Thank you for registering your game
modified
PostPosted: Mon, 9. Mar 09, 15:26    Post subject: [Script][Mar/17/2009] Transfer Freight via Drones - working Reply with quote Print

Transfer Freight via Drones v beta.07



This script allows the working transfer of freight via drones.

I've discontinued the development of this script, but I've uploaded it to GitHub to make it easier for others to continue working on it. You can find the GitHub project here: https://github.com/merlinthered/plugin.freight.drone.transfer

The command is located in the trade commands and differs from the EGO script by its yellow color.

Usage is equal to the EGOSOFT script. However, the behaviour is a little different.


Description:
This command allows you to transfer freight to and from a station or ship over large distances. Intergalactic Trade Software Standards now make it possible for the drones to trade with foreign stations. Due to their size freight drones can only be used by big ships.

Requirements:
Ship of class big ship (except M8) - Using drones on a ship that is smaller than the drone makes no sense...
Trade Command Software Mk2
Freight Drone

Installation:
Copy the contents of the "t" folder into the X3 TC\t folder
Copy the contents of the "scripts" folder into the X3 TC\scripts folder
If ChemODur's string library is already installed, the t files of it can be overwritten with the ones contained in this package. They contain minor fixes for german letters.

Deinstallation:
Cancel all running transfers (collect the drones or give them another command)
Save
Quit X3 and remove the scripts' files from the "scripts" folder (see "Used Files")
Remove the language file from the "t" folder (see "Used Files")

Behaviour:
If more wares than a single drone can carry are selected more drones are used and the selected wares are distributed between them.
A drone loads as much selected ware as possible from the starting ship and moves to its destination. Then it unloads the wares. If the target doesn't have enough free cargo space the drone waits until more space is available. When it's empty it starts loading the wares to transport back from the destination. If the target doesn't have enough of them the drone waits until the stock is refilled! That's why the target's stock is not regarded when selecting the wares to transport back from the destination.
When the selected amount of wares has been loaded the drone starts back to it's starting ship. Then it starts unloading the wares and follows the starting ship within transporter range until everything has been unloaded. If there is not enough space in the starting ship's cargo bay the drone waits until more space is cleared. Then it flies to the ship to be collected. This now happens automatically. M2 owners now no longer have to collect the drones manually.

Screen Shots:
Usage of the script is practically identical to the original script by EGOSOFT. First select the target of the transfer. Then set up the list of wares to transport to and back from the target. "Start Transfer" starts the drones. The screen shots should be pretty self explanatory. If not, try the script or ask here.



Known Problems:
It's possible that the drones don't transport all wares that have been selected. This is due to the fact that while selecting the wares it is ignored that they have to be distibuted between multiple drones.
E.g. if you have three drones, they have a total cargo bay of 2400 units. If you want to transport 4 units of a ware with a volume of 600, selecting these is no problem in the UI, because 4*600 fits exactly into the 2400 cargo bay of the drones. However, only 3 of them can be transported, because a drone can hold only one of them at a time and the remaining one can not be split to be transported partly in different drones. If something like this happens, the script will not alert you that some of the selected wares could not be transported. A little thinking is needed here ;)
#This case has not yet been tested properly

Download as zip via GitHub
Mirror kindly provided by Mastersouleater

Used Files:

t\8222-L044.xml
t\8222-L049.xml
t\8910-L007.xml <-------String Library by ChemODur!! http://forum.egosoft.com/viewtopic.php?t=233377
t\8910-L044.xml <-------String Library by ChemODur!! http://forum.egosoft.com/viewtopic.php?t=233377
t\8910-L049.xml <-------String Library by ChemODur!! http://forum.egosoft.com/viewtopic.php?t=233377

scripts\lib.chem.strings.xml <-------String Library by ChemODur!! http://forum.egosoft.com/viewtopic.php?t=233377
scripts\plugin.freight.drone.delivery.xml
scripts\plugin.freight.drone.gui.xml
scripts\setup.freight.drone.move.xml
scripts\plugin.freight.drone.target.xml
scripts\plugin.freight.drone.transfer.xml
scripts\plugin.freight.drone.wares.xml
scripts\setup.freight.drone.transfer.xml

Used Resources:

Command Slot
COMMAND_TYPE_TRADE_22 (422) ->"COMMAND_DRONE_WARE_EXCHANGE"

Language Files
8222-L044.xml (page id=8222)
8222-L049.xml (page id=8222)
8910-L007.xml (page id=8910) <-------String Library by ChemODur!! http://forum.egosoft.com/viewtopic.php?t=233377
8910-L044.xml (page id=8910) <-------String Library by ChemODur!! http://forum.egosoft.com/viewtopic.php?t=233377
8910-L049.xml (page id=8910) <-------String Library by ChemODur!! http://forum.egosoft.com/viewtopic.php?t=233377



Last edited by Tim-O on Sun, 9. Dec 12, 21:36; edited 13 times in total
Back to top
View user's profile Send private message
Tim-O





Joined: 15 Dec 2005
Posts: 182 on topic

Thank you for registering your game
modified
PostPosted: Mon, 9. Mar 09, 20:42    Post subject: Reply with quote Print

Changelog:

2009-03-17: v beta 07

- Executing the command no longer terminates any other commands on the ship.

- In the ware selection menu the current stock, transport class and volume of each ware is now displayed

- Used ChemODurs String Library for formatting.

2009-03-13: v beta 06

- Freight drones no longer load installed wares.

2009-03-13: v beta 05

- The script version is now displayed in the upper right corner of the main transfer window. (Yes, I'm bored...)

2009-03-11: v beta 04

- When the drone is sent to buy wares at a foreign station it now waits until the player has enough money instead of loading all the wares and only paying as much as the player can afford.


2009-03-09: v beta 03

Initial English Release



Last edited by Tim-O on Tue, 17. Mar 09, 17:30; edited 2 times in total
Back to top
View user's profile Send private message
semiliterate





Joined: 13 Dec 2008



PostPosted: Fri, 13. Mar 09, 14:28    Post subject: Reply with quote Print

no matter what number i give my Mammoth, it refuses to send a more than a single drone to my ore mine to fetch ore. it also, um, took 100 ore back and may have eaten the ore that should have been assigned to other drones.

Back to top
View user's profile Send private message
Tim-O





Joined: 15 Dec 2005
Posts: 182 on topic

Thank you for registering your game
PostPosted: Fri, 13. Mar 09, 16:19    Post subject: Reply with quote Print

This sounds exactly like the behaviour of the original egosoft script. I thought I had these problems fixed with my script. Are you really sure you used my script and not the Ego one? (My script should be the one with the yellow command text). If the problem really occurs with my script then please tell me more about what freight your Mammoth carries, what is in the cargo bay of the mine and how many drones you have on board.


2009-03-13: v beta 06 released

- Freight drones no longer load installed wares.

Back to top
View user's profile Send private message
semiliterate





Joined: 13 Dec 2008



PostPosted: Fri, 13. Mar 09, 17:47    Post subject: Reply with quote Print

um woops

the directory structure it was in threw me off and i ended up unzipping the scripts to the wrong place. it's here now!

Back to top
View user's profile Send private message
Tim-O





Joined: 15 Dec 2005
Posts: 182 on topic

Thank you for registering your game
PostPosted: Tue, 17. Mar 09, 17:30    Post subject: Reply with quote Print

2009-03-17: v beta 07

- Executing the command no longer terminates any other commands on the ship.

- In the ware selection menu the current stock, transport class and volume of each ware is now displayed

- Used ChemODurs String Library for formatting.

Back to top
View user's profile Send private message
semiliterate





Joined: 13 Dec 2008



PostPosted: Wed, 18. Mar 09, 00:01    Post subject: Reply with quote Print

not sure if it's something odd happening to my RAR, but the very bottom line (<t id=130...) was missing from the L044 file, causing all wares to show up with a readtext. i just stuck the line from the other language file in and it works fine.

Back to top
View user's profile Send private message
Tim-O





Joined: 15 Dec 2005
Posts: 182 on topic

Thank you for registering your game
PostPosted: Wed, 18. Mar 09, 12:42    Post subject: Reply with quote Print

I just downloaded the file from mediafire and extracted it. The 130 line is there in both language files. Try re-downloading to make sure everything is ok.

Back to top
View user's profile Send private message
semiliterate





Joined: 13 Dec 2008



PostPosted: Wed, 18. Mar 09, 13:53    Post subject: Reply with quote Print

my word i am stupid.

that was the original version.

okay now this one might actually be a real thing. okay, the freight drones wait for stock to reach proper levels - but what happens when they run out of energy? any chance of an auto-recall, refresh drone? i'm trying to get a freight drone to empty my flail missile complex, you see, and i have no idea what happens if i let it sit there til it runs out of energy.

Back to top
View user's profile Send private message
Tim-O





Joined: 15 Dec 2005
Posts: 182 on topic

Thank you for registering your game
PostPosted: Wed, 18. Mar 09, 20:03    Post subject: Reply with quote Print

If a freight drone runs out of energy, it blows up. There is no way to prevent this. I also think you can't check the current energy level by script. Honestly, I don't intend to make them much more intelligent than they are.
I could eliminate all the waiting and make the drone just take what is there and return. But then again: what happens if the drone can't unload its wares? Just let them in the cargo bay and live with the smaller space for the way back? Destroy them? I don't think that's an option.
In the end, they are just drones. If you want them to do their job, you have to do a little bit of thinking yourself. Make sure everything is there and there is enough cargo space free and you'll be fine. I think the added display of current stock and vol/tc helps a bit there.

By the way: Drones are not the real good way to keep a missile complex empty. Try this script:
http://forum.egosoft.com/viewtopic.php?t=239414 Wink
It lets you use freighters to extend the storage space of the complex. If you want to load your M7M with new missiles just undock one of the extension freighters and transfer the missiles from there to the missile frigate (via Drones if you want). That way you don't have to initiate another drone transfer every other minute.

Back to top
View user's profile Send private message
semiliterate





Joined: 13 Dec 2008



PostPosted: Wed, 18. Mar 09, 23:40    Post subject: Reply with quote Print

Tim-O wrote:
If a freight drone runs out of energy, it blows up. There is no way to prevent this. I also think you can't check the current energy level by script. Honestly, I don't intend to make them much more intelligent than they are.


you can fake it using the known total flight time. it's mainly so that there is an easy way to, well, get a drone to sit there and empty the fab til it's nearly out of energy. but yeah, fair point.

By the way: Drones are not the real good way to keep a missile complex empty. Try this script:
http://forum.egosoft.com/viewtopic.php?t=239414 ;)[/quote]

ah, see - for one thing, my game is already buggy which makes me wary of things saying beta, and for another, i also want the missiles on my TL because it's a resupply ship - it just seemed like a smarter freight drone transfer was in the remit of this script and would be more appropriate for my needs. apart from anything else, i'm down to about thirty thousand credits after building the complex...

but fair dos, i'll give it a try.

Back to top
View user's profile Send private message
Tim-O





Joined: 15 Dec 2005
Posts: 182 on topic

Thank you for registering your game
PostPosted: Thu, 19. Mar 09, 16:46    Post subject: Reply with quote Print

Before I had written the Storage Extension I also used to store my missiles on a TL. I set the TL as homebase for some fighters and gave them the order to buy the wares from the complex. I entered a ridiculously high number when asked for the number of repeats. The fighters then shuttled between the TL and the complex and took the missiles back with them if there were any.

Back to top
View user's profile Send private message
kdalts





Joined: 12 Dec 2008



PostPosted: Thu, 7. May 09, 13:41    Post subject: Reply with quote Print

Well I tried the script.

It send all my drones, collects wares, returns to destination - great. BUT - then the drones just sit back in the frieght bay despite being requested to colled 4,000 units.

So, better than the xtc version - at least the drones collect and return... just need them to fullfill the original order

Back to top
View user's profile Send private message
Tim-O





Joined: 15 Dec 2005
Posts: 182 on topic

Thank you for registering your game
PostPosted: Wed, 13. May 09, 10:35    Post subject: Reply with quote Print

You mean you want them to fly back and get the rest if they couldn't get it all the first time? I let that out because if they didn't get it the first time it is likely that it will take some time until the ware is available again. Drones don't have much power and I wanted to avoid drones exploding while waiting for their freight. Or did I get you wrong and you meant something different?

Back to top
View user's profile Send private message
BlackDemon





Joined: 13 Feb 2004
Posts: 753 on topic
Location: Argon Prime
Thank you for registering your game
PostPosted: Sat, 8. Aug 09, 01:38    Post subject: Reply with quote Print

I didn't see anyone thank you for this yet, so I just want to say thank you SO much for this script! I seriously mean it!

I was at the point of giving up playing when I had finally saved up and bought my first "capital" ship (a TL for starting up my economy properly) and then I bought a few TS's for cargo loading/unloading only to find out that THEY CAN'T FRIGGIN DOCK?!?!!

"what the hell?!... OK" I thought... "I'll just get some of those new cool looking Freight Drones, they sound like they'll do just the perfect job for my larger ships!"

So off I go and buy a load of Freight Drones, only to find out... THEY CAN ONLY TRANSFER FROM MY OWN STATIONS AND OTHER CAPITAL SHIPS?!?!?! *headdesk* Yes at this point, I was literally banging my head on the desk trying to figure out how the hell Egosoft could be so stupid, and how the hell I was going to make this game fun again faced with the prospect of having freaking stupid TS ships jumping around everywhere behind my capital ships just to bloody reload/refuel/rearm them - or have fleets of M3s for transferring cargo (yeah right! lol). All I wanted was to have my Freight Drones act like cargo runners for my large ship - including to/from NPC stations and what-not!

Then I found this... and all my prayers about how the Freight Drones SHOULD work have been answered! So once again, THANK YOU SO MUCH! This was so quick and easy to install, and works like a dream! I am forever in your debt of allowing me to continue with this game with no more frustrations regarding my capital ships! Big, big kudos to you Tim-O! Sorry for this wall of text, but man you needed to get some thanks for this! :¬D

Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic Reply to topic Goto page 1, 2, 3  Next
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum
Control Panel
Login Data
The time now is Fri, 24. Nov 17, 15:01

All times are GMT + 2 Hours


Board Security

Copyright © EGOSOFT 1989-2017
Powered by phpBB © 2001, 2005 phpBB Group
Template created by Avatar & BurnIt!
Debug: page generation = 0.80810 seconds, sql queries = 29