Code: Select all
(block (behavior newBehavior allDests dockedAt allWrecks allLoot)
(setq behavior (objGetData gSource "behavior"))
(setq dockedAt (shpGetDockObj gSource))
; If we're docked at an object, dump any loot that we found
(if (and dockedAt
(objHasAttribute dockedAt "populated")
; Compose a list of all loot on board that the station
; might want to buy from us.
(setq allLoot (filter (objGetItems gSource "*~mf U") theItem
(objGetBuyPrice dockedAt theItem)
))
)
(block Nil
(enum allLoot theItem (objRemoveItem gSource theItem))
(enum allLoot theItem (objAddItem dockedAt theItem))
)
)
I know this because I sat on a fuel depot ( the easiest station to watch ) after I emptied it and waited for traffic carrying stocked items on board to show up:
nothing.
I have 8 ships carrying items to drop : 2 are fuel carrying freighters.
While I CAN get them to drop the fuel or items at a specific station by adding code to the station : the traffic code dos not actually work.
I believe the " problem" is in the transfer of the item......
What I would like to see here is it's place is a WORKING code that gets the ships to actually make the drop in future versions.
I am back to editing my traffic codes to try to get this done: it probably will look like it will never work ( which is how I can be sure it's almost there )
** edits: sorry if I do type or sound worse then usual: it's Alaska and I heat with wood: so Im not exactly warm and it is both distracting and annoying : plus i hit my finger on a differential and the bandaide is an odd feeling on my finger