Surviving Mars

Surviving Mars

422 ratings
Drone Load Balancing
2
   
Award
Favorite
Favorited
Unfavorite
File Size
Posted
Updated
425.923 KB
Mar 28, 2018 @ 2:59pm
Sep 9, 2021 @ 2:24pm
15 Change Notes ( view )

Subscribe to download
Drone Load Balancing

Description
This mod automatically reassigns drones from low-load hubs to heavy-load hubs every hour. Drones are moved from the highest-population low-load hub to the lowest-population heavy-load hub in order to balance the load between hubs. Compatible with Below and Beyond update! The update only provides a notification that a hub is under heavy load, DLB's notification is when a hub is under heavy load and has the maximum number of assigned drones.

if Mod Config is available, the number of drones reassigned every hour is configurable. Otherwise the default value of 2 is used (range: 1-10). Can also control the minimum number of drones (for default hubs and tech-upgraded hubs separately).

Reassigns are handled via converting drones to prefabs and reconstructing them, avoiding travel time and possible battery issues. Low-load hubs with fewer than 5 drones are never considered. Stockpiles of drone prefabs will be assigned to heavy-load hubs at the same rate, if enabled via Mod Config.
< >
143 Comments
Draco18s  [author] Nov 15, 2023 @ 10:26am 
BioDiesel: not exactly. If drones are idle it doesn't do anything to them. But it does "pack them up" in order to transfer which hub they're assigned to. There really isn't a way to tell whether or not an individual drone is doing anything, the only way to monitor things is based on hub activity load.
BioDiesel112™ Nov 15, 2023 @ 9:39am 
does it repack unused drones ?
Draco18s  [author] Jan 16, 2023 @ 9:23am 
There's already a maximum cap on the number of drones a hub supports, so that shouldn't even be a concern.
KampfTomate007 Jan 16, 2023 @ 5:35am 
IIRC this mod only adds, or transfers drones between hubs, but is it possible to also make them remove unneeded drones and keep them as prefabs?

I'm mostly asking because in the endgame you easily get 20 hubs, and if it can't remove drones when idle then it might eventually end up adding all 2000 drones even if the average workload only requires like 200.

This could become a problem by causing a decent amount of lag and at the same time forces you to only have as many drones as you need on average workload, meaning during spikes it won't have enough drones, but at the same time you lose drones over time to things like events, threats, or similar and can't replace them without manually watching your drone addemblers to not overproduce.

I used to use the Automatic Drone Reassignment Reboot mod but it seems to have been discontinued so this mod seems to be the only option left.
Draco18s  [author] Sep 9, 2022 @ 12:36pm 
Good to hear! This mod should be pretty stable across updates, as Paradox hasn't touched the drone hub code at all, so for it to just stop working was worrisome. But if it was just a perception issue, then that makes sense.
Yeah, it only packs up a couple of drones ... I think it was every in-game hour? Without mod config, it will only re-assign 2 drones at a time, and only if there's a significant discrepancy in task load, so it can be kind of subtle sometimes.
Dswp_CZE Sep 9, 2022 @ 8:16am 
Well, maybe I was not patience in my playtime, because today I´m registering movement of drones between hubs. So the mod probably works. Of course if you as its creator can check it in the future, that would be great :)
Draco18s  [author] Sep 8, 2022 @ 12:37pm 
Thanks for letting me know, Dswp_CZE. I can't currently look into what's going wrong (or more accurately, the mod editor doesn't function on linux, so there's a limit to what I can do to investigate and fix the issue, and 100% can't push a new version; my Windows machine has decided that it has 4 minutes of up time and then it crashes).

Sorry. :\
Dswp_CZE Sep 8, 2022 @ 10:34am 
I don´t think this is working at all. I have the mod enabled and see no difference, I must still manually transfer drones between hubs.
Draco18s  [author] Dec 12, 2021 @ 8:47am 
Interesting, thanks for the extra info. Won't have the capability for looking into this in some time (lack a Windows machine at present).
ExavierMacbeth Dec 12, 2021 @ 8:34am 
Definitely Sure. Only mod I had installed that affects the Drone Hubs and the issue does not present itself when I disable your mod (Though any existing glitched range UIs still remain, my guess baked into the save). But like I said it only occurs when you use the prefab repack function... just dismantling the hub into resources does not glitch it out.

My guess would be the fact that the Hub & 6 drones getting removed as part of the repack effect is causing something to throw a null object error. Probably not clearing the scripts cleanly.