38,000 entities.... XD

    Koloss_Meshuggah

    Resident Wall Flower
    Joined
    Jul 13, 2013
    Messages
    63
    Reaction score
    19
    • Purchased!
    • Legacy Citizen 2
    • Legacy Citizen
    Lately I've been having serious performance problems in my single player world. I went to server database folder and found 38,640 entities created by the NPC factions (this is not counting my own entities and derelict/pirate stations). I have 5 NPC factions in my world, 2 of them are custom. They've been quite busy.

    I'm already fixing the problem, they are deleting from my recycle bin as I write this and I am going to switch off NPC factions before I start up Starmade again. I guess I'm just here to complain how unusable NPC factions are at this point. They are just something else to stay clear away from, like planets.

    We are so close to fun content that will put our builds to some use, so damn close. All Schema has to do is put a cap on spawn population and decrease the number of ships a faction will send into battle....that seems minor enough to me. With that done I could interact with NPCs and stay entertained for months until the next big update drops.

    I don't even know where to leave this, in suggestions or support, it's not really a bug but yet it kinda is.
     
    Joined
    Aug 1, 2015
    Messages
    472
    Reaction score
    84
    • Purchased!
    This is something that needs to be fixed,the server i'm on tried bringing in custom factions and it locked up the server with all the faction interactions on startup.
     

    Koloss_Meshuggah

    Resident Wall Flower
    Joined
    Jul 13, 2013
    Messages
    63
    Reaction score
    19
    • Purchased!
    • Legacy Citizen 2
    • Legacy Citizen
    This is something that needs to be fixed,the server i'm on tried bringing in custom factions and it locked up the server with all the faction interactions on startup.
    I'm glad I'm not the only one. No ones been talking about factions and it's kinda weird.
     
    Joined
    Aug 1, 2015
    Messages
    472
    Reaction score
    84
    • Purchased!
    And I was looking forward to the rp possibilities with the new factions,it would be nice to have a reason to explore.
     
    Joined
    Oct 12, 2015
    Messages
    321
    Reaction score
    257
    • Legacy Citizen 4
    • Community Content - Bronze 2
    • Purchased!
    It's quite unfortunate. On Light Vs Dark I was very much looking forward to utilizing the custom NPCs to enrich the game play by adding some solid PvE elements that could potentially draw players into cooperative play, while funneling opposing players into similar places to create a rich PvE/PvP experience.

    Sadly, the current NPC behaviors, especially with Scavenger (not to be confused with the faction) fleets (The NPC behavior that would have produced the most interactions outside of NPC territory, an essential element). To clarify, scavenging ships will appear on nav as "Faction Attack Ships" despite behing controlled by scavenging fleet configs and using ships designated in the catalog as Scavenger. Scavenger fleets will dispatch from the NPC faction's territory and arrive in the sector of a player doing something, often fighting pirates or something like that. The overheating of a core is often enough to get scavenger fleets dispatched to an area. When the scavanger ships arrive is where the problems start. Since they have no programming in place for retreat conditions based on fleet health or even a simple timer, NPC ships will continuously pile up in peoples home sectors until things begin to lag horribly. I would get calls from players constantly asking for admin cleanups because they would just endlessly clown-car home base sectors. To make things worse, NPC factions will drop AI control of entire fleets after a period of time, leaving ships that will just sit there uselessly, with player attempts to clean them up resulting in a NPC wardec and even more NPC ships being stuffed into a home sector. What should be a feature that could make game play really really fun, is turned into a pile of crap by not having built in behaviors that frankly should have been an ABSOLUTE REQUIREMENT before any thought of releasing the feature came to mind. To summarize NPC fleets need: 1. Retreat conditions based on fleet health. 2. Retreat conditions based on a timer if that doesn't work. 3. NPC factions need to maintain continuous control over all fleets outside their territory and not abandon all AI control of vessels like thet currently do. This is mainly having to do with the scavenging fleets.

    All fleets, player and NPC, still drop turrets and have been doing this for quite some time.

    The simulation that spawns assets for the NPCs to use is not very well set up for out of the box use, it's required lots of time wasted on tweaking it to what is it is now, which is a sorely disappointing version of what I originally envisioned them as.

    The fixes to current features must be prioritized or it will become harder and harder to get new players interested.
     
    Last edited:

    Koloss_Meshuggah

    Resident Wall Flower
    Joined
    Jul 13, 2013
    Messages
    63
    Reaction score
    19
    • Purchased!
    • Legacy Citizen 2
    • Legacy Citizen
    Starmade swarm meme.jpeg


    Also, there is no system to remove entities from the server, and factions don't have unloaded battles (yet), so even if the spawn rate was decreased the server would still eventual fill up until it couldn't run anymore.

    NPC factions were supposed to be the greatest update in the history of Staremade. After the update dropped it just got silently forgotten about, and now we are talking about uprooting the whole power system which could take who knows how long.​
     

    Attachments

    Joined
    Jan 28, 2015
    Messages
    492
    Reaction score
    149
    • Community Content - Bronze 1
    • Purchased!
    • Legacy Citizen 3
    Do not forget about the despawn command. This has always been mandatory to keep the regular pirates in check. You might also be able to use it on the NPC ships if they have a common prefix.

    For the Pirate Guild you would use:

    despawn_all
    • DESCRIPTION: WARNING: this will delete the entites that start with the given pattern from the database! It can not be undone!!
    • PARAMETERS: ShipNameStart(String), Mode(used/unused/all)(String), ShipOnly(True/False)
    • EXAMPLE: /despawn_all MOB_ unused true

    Since all Pirate ships use the MOB prefix the command will remove all Pirate ships to make room for new ships to spawn.

    You need to look for prefix common in the various NPC factions. Or maybe use the command multiple times on each NPC faction.


    Do NOT TEST this on your Server!


    The Despawn command is very powerful and has no undo option! Test this on a single player map created just to test this.

    A new command to wipe all current NPC fleets would be very welcome. Servers then just have to set this command to run every few hours. It would give you a crude but effective fix just like the Pirates.
     
    Joined
    Jul 10, 2013
    Messages
    626
    Reaction score
    486
    • Community Content - Bronze 2
    • Purchased!
    • Legacy Citizen 7
    Do not forget about the despawn command. This has always been mandatory to keep the regular pirates in check. You might also be able to use it on the NPC ships if they have a common prefix.

    For the Pirate Guild you would use:

    despawn_all
    • DESCRIPTION: WARNING: this will delete the entites that start with the given pattern from the database! It can not be undone!!
    • PARAMETERS: ShipNameStart(String), Mode(used/unused/all)(String), ShipOnly(True/False)
    • EXAMPLE: /despawn_all MOB_ unused true

    Since all Pirate ships use the MOB prefix the command will remove all Pirate ships to make room for new ships to spawn.

    You need to look for prefix common in the various NPC factions. Or maybe use the command multiple times on each NPC faction.


    Do NOT TEST this on your Server!


    The Despawn command is very powerful and has no undo option! Test this on a single player map created just to test this.

    A new command to wipe all current NPC fleets would be very welcome. Servers then just have to set this command to run every few hours. It would give you a crude but effective fix just like the Pirates.
    A fix yes, but temporary and depending on admin/human control.
     
    Joined
    Oct 12, 2015
    Messages
    321
    Reaction score
    257
    • Legacy Citizen 4
    • Community Content - Bronze 2
    • Purchased!
    One could even write a script to periodically run such a command to keep the extra NPCs thinned out, but the fact that the game does not regulate this on it's own is a huge problem that needs to be corrected.
     
    Joined
    Jan 28, 2015
    Messages
    492
    Reaction score
    149
    • Community Content - Bronze 1
    • Purchased!
    • Legacy Citizen 3
    Been toying a bit with /despawn_all but i am not getting good results.

    One common prefix seems to be GFLTSHP_ or FLTSHP_

    Most have numbers like B100-10 but /despawn_all does not accept wild cards.

    So /despawn_all B***-** unused true does not work.

    /despawn_all FLTSHP_ unused true

    Removes the Used Active ships near me and not everything else on the map.

    Worse because the NPC are under fleet command. I am getting tons of sql exceptions. Maybe related maybe not speculating here.

    The game does not like it when you despawn them. It all looks like it is woven together. Unlike the Pirates that are stand alone waves.
     
    Joined
    Oct 12, 2015
    Messages
    321
    Reaction score
    257
    • Legacy Citizen 4
    • Community Content - Bronze 2
    • Purchased!
    One could go into the world folder and attempt to remove them after shutdown, then bring it back up. Though I'd exercise extreme caution. Though, going back to my original point, one should not have to do such potentially dangerous things to simply regulate a server.
     

    Lancake

    Head of Testing
    Joined
    Aug 20, 2013
    Messages
    794
    Reaction score
    560
    • Schine
    • Tester
    Lately I've been having serious performance problems in my single player world. I went to server database folder and found 38,640 entities created by the NPC factions (this is not counting my own entities and derelict/pirate stations). I have 5 NPC factions in my world, 2 of them are custom. They've been quite busy.

    I'm already fixing the problem, they are deleting from my recycle bin as I write this and I am going to switch off NPC factions before I start up Starmade again. I guess I'm just here to complain how unusable NPC factions are at this point. They are just something else to stay clear away from, like planets.

    We are so close to fun content that will put our builds to some use, so damn close. All Schema has to do is put a cap on spawn population and decrease the number of ships a faction will send into battle....that seems minor enough to me. With that done I could interact with NPCs and stay entertained for months until the next big update drops.

    I don't even know where to leave this, in suggestions or support, it's not really a bug but yet it kinda is.
    Were most of those 38 640 entities from the 3 default NPC factions or from your 2 custom factions? Wouldn't mind all of your NPC logs either and some of your normal logs too. If most of those ships are from your custom NPC's, I would like the NPC config you used for it too.

    Some here have mentioned that NPC ships pile up at places, any idea if those are specific fleets? (Defense, miners, ...)?

    EDIT: This thread should be moved to Game Support
     

    Koloss_Meshuggah

    Resident Wall Flower
    Joined
    Jul 13, 2013
    Messages
    63
    Reaction score
    19
    • Purchased!
    • Legacy Citizen 2
    • Legacy Citizen
    Were most of those 38 640 entities from the 3 default NPC factions or from your 2 custom factions? Wouldn't mind all of your NPC logs either and some of your normal logs too. If most of those ships are from your custom NPC's, I would like the NPC config you used for it too.

    Some here have mentioned that NPC ships pile up at places, any idea if those are specific fleets? (Defense, miners, ...)?

    EDIT: This thread should be moved to Game Support


    I don't know how to tell what faction they are, most of them have GFLTSH in their name.
    There are alot of NPC logs, are you sure you want them all ? I sent the most recent ones.

    For me, attack fleets piled up at my base when I declared war, and again when I tried to fight some in empty space. The worse it ever got was when I went to Scav territory and the defense fleets were fighting pirates. Also, when I enter an NPC's territory, mining fleets flock to me and sort of wander around like friendly butterflies. They don't even mine if asteroids are near by.
     

    Attachments

    Erth Paradine

    Server Admln & Bug Reporter
    Joined
    Feb 15, 2016
    Messages
    239
    Reaction score
    58
    We've seen issues with the NPC factions as well. Everything from ballooning the factions.fac file ( ⚓ T1529 Server hangs on faction updates ), to causing whole-server lag at every tick ( ⚓ T2076 Extreme Lag Spikes when NPC Factions are Trading, also unable to trade with NPC Factions from player end ), to extreme Lag Spikes when NPC Factions endlessly and continuously process peace treaties ( Login to Phabricator )

    It's quite unfortunate, that NPC factions were dumped on us like this, as its basically turning into nothing more than an occasional auto-spawn trick that must be nuked every so-often (e.g. /despawn_all ), neutered by setting <TimeBetweenTurnsMS> (in file customNPCConfig/npcConfigDefault.xml ) to a really high value...and simply grinning and bearing through the seemingly continuous lag spikes as the game engine runs an already apparently very buggy/laggy factions.fac parsing and peace treaty processing routine.
     

    StormWing0

    Leads the Storm
    Joined
    Jun 26, 2015
    Messages
    2,126
    Reaction score
    316
    • Community Content - Bronze 1
    Ya I've noticed this as well. This is one of those things that needs to be fixed badly.
     

    Erth Paradine

    Server Admln & Bug Reporter
    Joined
    Feb 15, 2016
    Messages
    239
    Reaction score
    58
    Hmm...seems so pointless to leave NPCs enabled, if we're going to nuke 118,448 entities :cautious:

    Code:
    ~$ find server-database/world0/ -name '*FLTSHP_*' |wc -l
    118448
    ~$
     

    StormWing0

    Leads the Storm
    Joined
    Jun 26, 2015
    Messages
    2,126
    Reaction score
    316
    • Community Content - Bronze 1
    Maybe they should add a way to enable or disable them outright? :) If I remember right setting their spawning to 0 should help.