▶️ ЗАБЕРИ СВОИ 8 ПОДАРКОВ 🎁 ПРИ СОЗДАНИИ СВОЕГО МАЙНКРАФТ СЕРВЕРА
NeuroLag

NeuroLag

A smart, resource-aware optimization plugin that dynamically adjusts Mob AI based on server TPS and RAM to ensure a lag-free SMP experience

46
1
Все версииNeuroLag 1.0.6

NeuroLag 1.0.6

Release2 нед. назад

Список изменений

[1.0.6] — 2025-03-11

Fixed

  • Bug — Tick-Rate Throttling (Feature 2) never activated
    In applyAiBatched, shouldHaveAi was always true for MEDIUM state because globalAiOn = !state.equals("CRITICAL") evaluates to true. The throttle condition !shouldHaveAi was therefore always false, so distant mobs in MEDIUM were silently given full AI instead of being throttled.
    Fix: chunk proximity is now evaluated independently first. Near-player mobs always get full AI; distant mobs in MEDIUM state enter the throttle queue; CRITICAL mobs get setAI(false) as intended.

  • Bug — /nlag toggle did not actually pause monitoring
    Setting manualOverride = true had no effect on tick() — the scheduler task continued running. Fix: monitorTask.cancel() is now called when pausing; startMonitor() is called when resuming (existing behaviour).

  • Bug — /nlag simulate clear threw NumberFormatException
    Tab-complete suggested "clear" as a valid argument, but the code passed it directly to Double.parseDouble(), crashing with an unhandled exception.
    Fix: an explicit equalsIgnoreCase("clear") check now runs before the parse.

  • Minor — Recovery (NORMAL) action bar could be suppressed by cooldown
    The 5-second notify cooldown was applied to all state transitions, including CRITICAL → NORMAL recovery. If a CRITICAL message had just been sent, admins would miss the recovery notification entirely.
    Fix: cooldown only throttles MEDIUM/CRITICAL spam; NORMAL recovery always fires.

  • Minor — notifyTimes map not cleared on restoreAll()
    Stale cooldown timestamps persisted across /nlag reload and plugin restarts, causing the first post-reload notification to be silently dropped.
    Fix: notifyTimes.clear() added to restoreAll().


[1.0.5] — 2025-03-10

Added

  • Feature 1 — Chunk-Based AI Throttling
    Mobs within a configurable chunk radius of any online player always retain their AI, even in CRITICAL state. Only mobs in truly unobserved chunks are disabled. Controlled by chunk-ai.enabled and chunk-ai.distance-chunks.

  • Feature 2 — Tick-Rate Throttling
    In MEDIUM state, instead of hard-disabling mob AI, a dedicated per-tick task cycles through distant mobs and enables their AI for exactly 1 tick every N ticks. Mobs appear sluggish rather than completely frozen, which feels far more natural in-game. Controlled by tick-throttle.enabled and tick-throttle.ticks-per-ai-tick.

  • Feature 3 — Spawn Rate Suppression
    During MEDIUM or CRITICAL lag, world monster and animal spawn caps are temporarily lowered to reduce new mob generation. Limits are fully restored on recovery. Controlled by spawn-suppression.*.

  • Feature 4 — Per-Player Action Bar Notification
    When a player has affected mobs within a configurable radius, they receive a personal action bar message explaining why nearby mobs seem different. Previously only ops received any notification. Controlled by per-player-notify.*.

  • Feature 5 — /nlag simulate <tps>
    Overrides the TPS value used by the engine without affecting the real server. Allows admins to test threshold configurations, Discord alerts, and reports without needing actual server lag. Running /nlag simulate with no argument clears the override.

  • Feature 6 — Auto Lag Reports
    After recovering from a CRITICAL event that lasted longer than min-duration-seconds, a timestamped report is written to plugins/NeuroLag/lag-reports/. Each report includes world name, duration, lowest TPS reached, recovery TPS, affected mob count, online player count, and JVM heap statistics.

  • Feature 7 — Entity Whitelist
    Specific EntityType names can be added to targets.whitelist-types to permanently exempt them from all optimization and culling. Additionally, protect-named-mobs and protect-tamed-mobs options prevent NeuroLag from touching player pets, named mobs, and boss entities.

  • Feature 8 — Discord Webhook
    Posts a rich Discord embed when a world enters CRITICAL lag and when it recovers. The recovery embed includes total CRITICAL duration and the lowest TPS reached. Uses Java 11+ HttpClient — no external library required. Controlled by discord.*.

  • Feature 9 — Memory Pressure Detection
    Reads JVM heap usage ratio at each TPS check. When heap exceeds trigger-percent, an additional offset is subtracted from effective TPS before threshold evaluation, causing NeuroLag to act more aggressively when RAM is nearly exhausted. Controlled by memory-pressure.*.

  • Feature 10 — Player-Count Scaling
    TPS thresholds are linearly scaled upward as the number of online players increases between min-players and max-players. At maximum players, all thresholds shift up by max-threshold-offset TPS. Per-world threshold overrides are scaled the same way. Controlled by player-scaling.*.

  • /nlag simulate tab-completion — suggests common TPS values (5, 10, 15, 18, 20).

  • Heap stats in /nlag help panel and /nlag status — shows used/max MB and percentage.

  • World state icons in /nlag status NORMAL, MEDIUM, CRITICAL.

  • /nlag toggle now calls restoreAll() before resuming the monitor, ensuring any frozen mobs are immediately unfrozen.

Файлы

NeuroLag-1.0.6.jar(30.46 KiB)
Основной
Скачать

Метаданные

Канал релиза

Release

Номер версии

1.0.6

Загрузчики

Bukkit
Paper
Purpur
Spigot

Версии игры

1.21–1.21.11

Загрузок

5

Дата публикации

2 нед. назад

Загрузил

ID версии

Главная