Pleb wrote:I've now done pretty much as Gimi has said - the percentages are exactly what Gimi has stated in previous post, and the patrols and stations in system only appear on witchpoint-sun route. There is the chance (as stated in Gimi's post) that an extra patrol may spawn on one of the other routes (only in station systems). Also, when a patrol is finished, they will either jump to another system or sun-skim.
One way to handle it - a fair bit more complicated than just using percentage chances, but potentially giving much better results: don't add any random patrols at all. Instead, set the AI up to plan multi-system journeys from the base out to its destination (and potentially return) - have a look at the courier AI for one which gets multisystem trips, and the bounty hunter leader AI for "out, do mission, return" priorities.
Then, set up particular missions for the launched groups to carry out: launch from their base, jump across several systems to their destination, do the job, go home. You can work out from their route (and some rough guesses about in-system times) what their arrival and departure times in each system will be, and use that to work out when the player arrives in a system if there's a
HIMSN group there or not. If there is, you add it; if it will be arriving soon, the repopulator function can have them jump in appropriately.
Now, it's not just a randomly-generated patrol that flies around a bit and then jumps out, it's the
HIMSN 31st Squadron, on it's way from Xeer to Teraed, where they'll meet up with a freighter group carrying vital supplies for the war effort against the Thargoids and escort them back to Xeer. And, if you're patient enough - and stay far enough back that they don't get suspicious - you as the player can watch them do all of this. Or maybe you leave them alone, but see them jumping back into Xeer later with several ships missing and only two surviving freighters. Depending on how many such missions you simulate at once, that then gives a greater or lesser chance of their appearance, and also a much increased chance of seeing one near their base compared with at the other side of the map.
As far as where they go to fight Thargoids: in 1.79 the Thargoids have changed tactics slightly - they can appear on any spacelane (when entering a system, they use their superior witchspace technology to appear well clear of the potentially patrolled witchpoint) and in other places too - and are much more likely to appear in "bottleneck" systems, especially those poorly defended by the local forces, than other systems. I'm not sure that there is in general much tactical benefit to jumping to interstellar space to shoot Thargoids - though it might be a pastime of the more heavily-armed bounty hunters - but it might be worth it if a hard-to-defend target was about to make a jump between two systems: jump a military force into interstellar space ahead of it, have them distract the Thargoids for 15-30 minutes until the more critical target is past, then leave.
Pleb wrote:This is only because the OXP cim wrote does not contain a world-script
It does - in
Config/script.js
- but I think you'd be better reimplementing rather than trying to integrate it, since it was just a proof of concept. Take any bits you need, though.