This site is in archival mode. A replacement is being developed. In the meantime, please use the PBW2 Forums for community discussions. The replacement software for this site will use a unified account system with PBW2, and any newly created threads will carry over.
Posted: Thu Oct 30, 2014 12:03 am Post subject: Scripted Cargo Loading
Has anyone toyed with scripting a cargo load? I have been playing around with the **Load_All_Cargo function for CARGO_ITEM_TYPE_POPULATION and have experienced some really weird results. (I think that is the only cargo load function available)
My code checks a ship to see if it has component X and if so randomly selects a target planet with atmosphere X that has a population. The ship repositions using Sys_Set_S_O_Position and here the weirdness begins.
Weirdness 1) If you limit storage/cargo capacity, say 1kt, the complete population is destroyed otherwise with enough cargo space, say 100kt, you extract the population from the target planet.
Weirdness 2) Species X, given stealth embedded i.e. sight obscuration of 100+, does not detect ship while it sits in orbit having extracted the population. However, if you move the ship away from the target planet, you get a treaty offer meaning they have somehow overcome a sight obscuration off the charts and are now in peaceful communication.
Weirdness 3) If you transit a WP out of the system - no issue. Captured cargo is intact, and while I have not kept testing, I suspect you could navigate your way back to your home system with cargo of species X intact. Automating the repositioning of the ship using the script used to reach the target planet eliminates the cargo. As a result you return empty, Species X does not detect you, and the planet is left completely empty of a population.
While it offers some intriguing possibilities it failed to let me accomplish what I was after - simulating a slave raid as part of an enhancement to a pirate empire. Any insights would be helpful.
In the meantime I am going to try use of the jump or ftl drive options to see if that has an impact on the cargo. Back to top
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 can download files in this forum
All logos and trademarks used on this site, all comments and stories posted for reading, all files hosted for download, and all art work hosted for viewing are property of their respective owners; all the rest copyright 2003-2010 Nolan Kelly.
Syndicate news: - Syndicate forums:
Page Generation: 0.74 Seconds