Space Engineers

Space Engineers

42 ratings
Clean Freak
2
   
Award
Favorite
Favorited
Unfavorite
Type: Mod
Mod category: NPC, Other
File Size
Posted
Updated
415.587 KB
May 4, 2020 @ 2:36pm
May 11, 2024 @ 8:00pm
5 Change Notes ( view )

Subscribe to download
Clean Freak

Description
This mod deletes garbage in the world. However, there is always the chance it may delete something you wanted to keep. While it does completely ignore player grids and all stations (player or NPC owned), that doesn't mean you didn't want to keep that NPC ship coasting 12k off your base. So... Backup your save!

If you find any bugs, send me logs!

You can always find me in the EEM Discord (yeah, I'm that guy): https://discord.gg/PNtpMyw

User configurations for all settings can be found in the save game folder (you need to launch your save with this mod active at least once for it to be generated). Follow the rules in the .ini!

Change log:

Mod Version 1.3 [Released 11 May 2024]
  • Added a new setting which provides a verbose debug log for... debugging purposes. It's off by default. Turn it on i fyou want to help me debug your issue, or if you're just curious why ships are vanishing.
  • Rewrote the player detection algo so it is less confused sometimes.

Mod Version 1.2 [Released 19 Apr 2024]
  • Added a new setting to allow bypassing the grid movement check when determining if a grid is valid for deletion or not.
  • Uploaded to Mod.IO

- 1.1 Added a null check for players in the respawn screen.

- 1.0 brings with it a host of new settings, different settings per spawn type (encounter, cargo ship) and the user config file.
____________________________________________________________________________________________

Ever wonder why enemy NPC ships stopped spawning when they were so plentiful before?

Space Engineers forces a hard cap on the NPC PCU limit that's not changeable by the average Joe. You either need to edit the sandbox or use another mod of mine to push the limit higher. However, that doesn't really solve much since as more pirates spawn, more of their PCU gets devoured, and the lag just builds and builds.

This mod aims to get rid of the garbage floating in your skies and wrangle that ever annoying stalled ship, floating debris, or old wreck you just don't want to deal with.

The rules are... complex, yet simple, yet completely configurable you!

RULES:
- Player owned grids are EXEMPT from cleanup (must have majority ownership)
- NPC Stations are EXEMPT from cleanup
- Subgrids are ignored from cleanup; only the main grid will be counted

- Debris cleanup
Affects any small collection of blocks (6 or less) greater than 1km from any player
Affected grids base rules given above
If the player owns any blocks on the grid it will be ignored
Ownership requires a block with computers in it; armor won't do
Requires 3 strikes before removal

- Standard cleanup
Affects any grids greater than 10km from any player
Affected grids base rules given above
If the player owns any blocks on the grid it will be ignored
Requires 3 strikes before removal

- Aggressive cleanup
Affects any grids greater than 5km from any player
Affected grids base rules given above
If the player owns any blocks on the grid it will be ignored
Requires 6 strikes before removal

- Super Aggressive cleanup
Affects any grids greater than 10km from any player
Affected grids base rules given above
If the player owns any blocks on the grid it will STILL BE COUNTED!
Well, it won't be counted if a player owns the majority of the blocks, just some of the blocks
Requires 12 strikes before removal

After 6 minutes a timer starts that evaluates all grids in the game that do not meet the above criteria. If a ship is stationary or moving in an unchanging linear path AND not near a player (see above for distance), it will get a strike against it. Every minute thereafter it will be evaluated again for the same criteria. Once the total allowed strikes are given, the grid is deleted. If at any point a player gets near the grid or the grid moves in any way, the strikes will reset.

Lots of rules!

When I add the configuration options, all of the rules will be configurable. Including one specific for servers that will shut down cleanup while no one is online. Right now this is set to false, so this will run on a server when no players are active.
71 Comments
Thraxus  [author] Jun 20 @ 1:57pm 
See if the config file generated, then look at the log file.
Joker2105 Jun 20 @ 1:38pm 
Hi.. how can i check that the mod is active?
Thraxus  [author] Apr 18 @ 6:36am 
Static grids are all stations by game design, even if it was a ship turned static. Unfortunately there is no "station" designation on a grid, so being static inherently means "station".
Nalesh Apr 16 @ 2:58pm 
When it says npc stations, does that mean all static grids, or specifically stations like economy stations, etc?
Thraxus  [author] Dec 8, 2024 @ 5:53pm 
To be determined. If they spawn as ships and not stations, possibly. I need reports that say it happens before I can say it happens though. Logs help a ton as well.
Thraxus  [author] Dec 5, 2024 @ 8:03pm 
It shouldn't - it's programmed to only care about prefabs. You can always check the logs though - I put every delete in there with the reason it was removed. A value of "None" means something other than CleanFreak did the delete.
Rooster Dec 5, 2024 @ 7:55pm 
Will this delete the new drop boxes that drop when you break down something with an inventory? I lost some ore today twice when I took down an assembler and refinery. Vanilla debris cleanup is disabled
Thraxus  [author] Nov 8, 2024 @ 12:41pm 
Doesn't matter. Should work anywhere in the list.
Zeruel Nov 8, 2024 @ 11:34am 
And where does it go in the loading order?
Thraxus  [author] Nov 8, 2024 @ 10:28am 
Yep. It basically does a better job at cleanup than vanilla, but uses the same ideas, so it is compatible with pretty much any mod and any server.