daily pastebin goal
0%
SHARE
TWEET

Untitled

a guest Sep 23rd, 2018 110 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function main()
  2. {
  3.     variable index:item TransferItem_CargoIndex
  4.     variable iterator TransferItem_CargoIndex_Iterator
  5.    
  6.     if !${Me.InStation}
  7.     {
  8.         echo ${Time}: You must be docked before running this script!
  9.         Script:End
  10.     }
  11.    
  12.     ;//NOTE: Uncomment the source location and comment out the other location.
  13.    
  14.     ;//Transfer From Ore Hold
  15.     ;MyShip:GetOreHoldCargo[TransferItem_CargoIndex]
  16.    
  17.     ;//Transfer From Fleet Hangar
  18.     MyShip:GetFleetHangarCargo[TransferItem_CargoIndex]
  19.        
  20.     TransferItem_CargoIndex:GetIterator[TransferItem_CargoIndex_Iterator]
  21.    
  22.     if ${TransferItem_CargoIndex_Iterator:First(exists)}
  23.     {              
  24.         do
  25.         {  
  26.             ;//This will only transfer asteroids because asteroid category ID is 25.
  27.             if ${TransferItem_CargoIndex_Iterator.Value.CategoryID} == 25
  28.             {
  29.                 echo ${Time}: ---------- Item #${TransferItem_CargoIndex_Iterator.Key} of ${TransferItem_CargoIndex.Used} [${TransferItem_CargoIndex_Iterator.Value}] ----------
  30.                 echo ID: ${TransferItem_CargoIndex_Iterator.Value.ID}
  31.                 echo Category: ${TransferItem_CargoIndex_Iterator.Value.Category}
  32.                 echo CategoryID: ${TransferItem_CargoIndex_Iterator.Value.CategoryID}
  33.                 echo Group: ${TransferItem_CargoIndex_Iterator.Value.Group}
  34.                 echo GroupID: ${TransferItem_CargoIndex_Iterator.Value.GroupID}
  35.                 echo Location: ${TransferItem_CargoIndex_Iterator.Value.Location}
  36.                 echo LocationID: ${TransferItem_CargoIndex_Iterator.Value.LocationID}
  37.                 echo Volume/Single Item: ${TransferItem_CargoIndex_Iterator.Value.Volume}
  38.                 echo Quantity: ${TransferItem_CargoIndex_Iterator.Value.Quantity}
  39.                 echo Volume/Stack: ${Math.Calc[${TransferItem_CargoIndex_Iterator.Value.Volume}*${TransferItem_CargoIndex_Iterator.Value.Quantity}]}
  40.                 echo -------------------------------------------------
  41.                
  42.                 ;//NOTE: Where do you want to move it to?
  43.                
  44.                 ;//OreHold
  45.                 ;ToLocation = MyShip
  46.                 ;ToDestination = OreHold
  47.                
  48.                 ;//Fleet Hangar
  49.                 ;ToLocation = MyShip
  50.                 ;ToDestination = FleetHangar
  51.                
  52.                 ;//Station Hangar
  53.                 ;ToLocation = MyStationHangar
  54.                 ;ToDestination = Hangar
  55.                
  56.                 ;//TransferItem_CargoIndex_Iterator.Value:MoveTo[ToLocation,ToDestination]
  57.                
  58.                 TransferItem_CargoIndex_Iterator.Value:MoveTo[MyStationHangar,Hangar]
  59.             }
  60.            
  61.             waitframe
  62.         }
  63.         while ${TransferItem_CargoIndex_Iterator:Next(exists)}         
  64.     }
  65. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top