Compatibility
Minecraft: Java Edition
Platforms
Supported environments
Links
Tags
Creators
Details
LagShield [NeoForge 1.21] LagShield is a server-side performance mod for NeoForge 1.21. It is designed specifically for hybrid server environments (such as Arclight or Mohist) to ensure compatibility with Forge mods while maintaining server stability.
The mod monitors the server load (MSPT) in real-time and dynamically adjusts mob spawns, entity AI, and movement speeds to keep the TPS stable.
Features Adaptive Performance Instead of enforcing static limits, the mod reacts to the current server load.
Stable (<40ms MSPT): No restrictions applied.
High Load (50ms+ MSPT): Mob spawns are reduced, and AI is disabled for distant entities.
Critical (>60ms MSPT): Strict limits on spawns and entity speeds are enforced to prevent crashes.
Asynchronous Processing To reduce strain on the main thread, calculations such as mob density checks and AI logic are offloaded to a background thread. The system uses data snapshots to ensure thread safety on hybrid servers and to prevent conflicts with other mods.
Speed Limiter Prevents entities (players or mobs) from loading chunks faster than the server can process them. This is particularly useful for mods that allow very fast movement (e.g., Vampirism, flight items). During high server load, these speeds are automatically throttled.
Mob Limits & Protection Chunk Limit: Dynamically limits the number of mobs per chunk based on server load.
Protected Entities: Bosses, Villagers, tamed animals, and name-tagged mobs are ignored by the mod and will not be despawned or frozen.
Commands The main command is /lagshield.
/lagshield status Displays current server information:
TPS & MSPT (Milliseconds per Tick)
Current Stress Level (Percentage)
Status of asynchronous processes (Number of frozen mobs/tracked chunks)
Configuration The mod generates a configuration file at config/lagshield-common.toml. You can adjust the following settings:
Enable/Disable asynchronous modules.
Adjust speed limits and sensitivity.
Set the maximum number of mobs per chunk.
Edit the list of protected mobs (VIP List).
Installation: This mod is required on the server side only. Clients do not need to install it.
✔ Support & Origins This mod was specifically developed for the Werewolves vs Vampires modpack to ensure a 24/7 lag-free experience.
Check out my other projects: CurseForge - epicskydex
Support the Developer: Support me on Ko-fi


