I've noticed something while testing Discovery yesterday that might affect more than just the mod itself and might be a thorn in many other mod dev teams side when it comes to defining actual NPC patrols rather than pop zones, or in general dealing with vanilla systems that are littered with NPC patrols.

Well, we all probably know the way patrols work, in that when an NPC follows a patrol route, at the end of the route it will try to dock with the nearest object. From my observations NPCs do not just try to dock with actual ingame base objects, but rather look for a closest HPDockPoint*01 point and try to dock with that without any additional checks. This means that they might try to dock at a hostile base which results in a server crash. It also means that they will try to dock at player flown ships who still have HPDockPoint*01 defined as for example happened to me yesterday when testing a completely different thing on the dev server. In my example it also resulted in a server crash, because the server has no base defined for the Osiris I was flying at the time.

This might be one of the reasons of seemingly random crashes that the Discovery mod may suffer at times. Would it be possible to somehow hack Freelancer to force NPCs to perform checks on the base (whether it exists, whether it is friendly) before trying to dock with its HPDockPoint*01 ?

Are you sure that npcs tried to dock on you?Could you please test it again, 'cos I've never heared of this.

Make a simple test: make a patrol that consists of two legs, make sure there are no bases in the middle of a patrol, and stay there with your ship that has dockpoints for an hour and see if it repeats. also give your patrol very short relief_time(don't think this parameter works though)