private void LoadBalancer()
        {
            FastRefresh = false;
            var shieldsWaking  = 0;
            var entsUpdated    = 0;
            var entsremoved    = 0;
            var entsLostShield = 0;

            if (EntSlotTick && ++RefreshCycle >= EntSlotScaler)
            {
                RefreshCycle = 0;
            }
            MyEntity ent;

            while (EntRefreshQueue.TryDequeue(out ent))
            {
                MyProtectors myProtector;
                if (!GlobalProtect.TryGetValue(ent, out myProtector))
                {
                    continue;
                }

                var            entShields    = myProtector.Shields;
                var            refreshCount  = 0;
                DefenseShields iShield       = null;
                var            removeIShield = false;

                foreach (var s in entShields.Keys)
                {
                    if (s.WasPaused)
                    {
                        continue;
                    }

                    var grid = ent as MyCubeGrid;
                    if (grid != null && s.DsState.State.ReInforce && s.ShieldComp.SubGrids.ContainsKey(grid))
                    {
                        iShield = s;
                        refreshCount++;
                    }
                    else if (!ent.InScene || ent.MarkedForClose || !s.ResetEnts(ent, Tick))
                    {
                        myProtector.Shields.Remove(s);
                        entsLostShield++;
                    }
                    else
                    {
                        refreshCount++;
                    }

                    if (iShield == null && myProtector.IntegrityShield == s)
                    {
                        removeIShield = true;
                        myProtector.IntegrityShield = null;
                    }

                    var detectedStates = s.PlayerByShield || s.MoverByShield || Tick <= s.LastWokenTick + 580 || iShield != null || removeIShield;
                    if (ScalerChanged || detectedStates)
                    {
                        s.Asleep = false;
                        shieldsWaking++;
                    }
                }

                if (iShield != null)
                {
                    myProtector.Shields.Remove(iShield);
                    myProtector.IntegrityShield = iShield;
                }

                if (refreshCount == 0)
                {
                    GlobalProtect.Remove(ent);
                    ProtSets.Return(myProtector);
                    entsremoved++;
                }
                else
                {
                    entsUpdated++;
                }
            }
            if (Tick1800 && Enforced.Debug >= 3)
            {
                for (int i = 0; i < SlotCnt.Length; i++)
                {
                    SlotCnt[i] = 0;
                }
                foreach (var pair in GlobalProtect)
                {
                    SlotCnt[pair.Value.RefreshSlot]++;
                }
                Log.Line($"[NewRefresh] SlotScaler:{EntSlotScaler} - EntsUpdated:{entsUpdated} - ShieldsWaking:{shieldsWaking} - EntsRemoved: {entsremoved} - EntsLostShield:{entsLostShield} - EntInRefreshSlots:({SlotCnt[0]} - {SlotCnt[1]} - {SlotCnt[2]} - {SlotCnt[3]} - {SlotCnt[4]} - {SlotCnt[5]} - {SlotCnt[6]} - {SlotCnt[7]} - {SlotCnt[8]}) \n" +
                         $"                                     ProtectedEnts:{GlobalProtect.Count} - FunctionalShields:{FunctionalShields.Count} - AllControllerBlocks:{Controllers.Count}");
            }
        }