Eric Walch wrote:Yes, it is hardcoded that only the main-station and ships with role "police" and "hunter" accept distress messages.
Your link implies it works for all stations...so you're saying it's even more limited than that?
[EDIT!]
In an attempt to have more trader NPC ships to work with, I hacked up Deep Space Pirates OXP to spit out a new arriving trader around the witchpoint beacon at whatever its timer intervals are. (I think around 15 seconds.) This was the code I added to DSP:
Code: Select all
if (!system.isInterstellarSpace && !player.ship.docked && System.countShipsWithPrimaryRole("pirate")<99 && System.countShipsWithPrimaryRole("trader")<999)
System.legacy_addShipsAt("trader", 1, "wpu", [Math.random()*0.05-0.025, Math.random()*0.05-0.025, Math.random()*0.05-0.025]);
Much to my surprise, my modified route1traderAI.plist didn't work as expected. The new arrivals seemed to keep using route1traderAI.plist and never switched to the other possible ais, such as scavengerAI.plist. EXTREMELY rarely, I'd get one of the other AI types...especially route2sunskimAI.plist even though it was the least likely possibility in my list.
Best I can tell, this method of adding ships doesn't trigger this code:
"EXITED_WITCHSPACE" = ("setStateTo: CHOOSE_NEW_CAREER");
...Which is making testing of my AI mod rather hard. I managed to further hack up route1traderAI.plist to ALWAYS do "CHOOSE_NEW_CAREER" without the "EXITED_WITCHSPACE" check.
After that, these script-added traders started acting as expected. I discovered that at 16x gamespeed I got plenty of new traders to see how they reacted...but the game was lagging pretty badly because many were Anacondas and Boas which added lots of escort ships. I "fixed" that for testing purposes...by editing my escortAI.plist to blow themselves up on arrival.
Now I can try to work out some reasonable ratios so the old behavior is still the most common...with a couple of rare alternatives for variety. I would've added more AI types, but as this thread as proven...I've been stymied by unexpected behavior and game limitations.
And I'm still learning, stumbling, and blindly trying stuff...so hopefully things can only get better.
