Entity Culling v1.1.0
What's new
v1.1.0 (A huge update that i wasn't planning on dropping soon but yall made me do it) Changelog:
Goodies:
+ Added Distance-tiered entity cheacking means entities closer to the player are checked more frequently, while distant entities are checked less often to reduce CPU usage.
0–16 blocks: every scan
16–32 blocks: every 2nd scan
32+ blocks: every 4th scan
+ Added Duplicate-spawn protection means the addon now checks for an existing matching entity near the saved position before restoring a culled entity.
+ Added Crash/restart recovery means stale culling records are automatically detected and cleaned up if the game closes or crashes during a culling/restoration operation.
+ Added Shared visibility system means FOV and wall-occlusion detection is now handled by one shared visibility function used by both culling and restoration.
Fixes:
*Fixed a potential issue where entities could theoretically be restored more than once after an interrupted spawn operation.
*Fixed the opposite persistence issue where a culling record could remain after the entity was never successfully removed.
*Fixed duplicated visibility/FOV logic that could cause the culling and restoration systems to behave differently.
*Reduced unnecessary raycasts and entity visibility checks in areas with lots of mobs.
*Improved consistency between when an entity is considered visible and when a previously culled entity is considered ready to restore.
Performance:
+ Reduced the number of expensive FOV and block-raycast checks performed in mob-heavy areas.
+ Distant entities are now checked less frequently while nearby entities receive more frequent visibility checks.
+ The culling and restoration systems now share the same visibility logic, reducing redundant calculations and preventing logic drift.
Balancing:
+ Added additional safeguards against duplicate entities after crashes, interrupted operations, or stale saved records.
+ Improved handling of persistent entity data across world reloads.
Thanks for the feedback
This mod has no additional files

