概览
MillOptimize 是一款专为 Millénaire 模组打造的高性能优化插件。它旨在通过优化 NPC AI 的处理方式以及村庄的运算逻辑,帮助在大型定居点中维持高 TPS(每秒刻数)。
? 目标环境
- Minecraft 版本: 1.21.1
- 目标模组: Millénaire 9.0.0-beta.1
- 平台: NeoForge
主要特性
? 核心使命
随着定居点的扩张,NPC AI 和村庄机制带来的计算负载可能会让最强大的服务器也感到吃力。MillOptimize 通过在智能层面限制非必要的后台进程,弥合了“真实模拟”与“流畅体验”之间的差距。
? 演进与传承
本项目是 MillMix_Jubi 的专属分支及继任者。
? 村庄持久化(“点睛之笔”)
此版本独有功能。
在标准的 Millénaire 中,如果没有玩家靠近或玩家断开连接,村庄往往会“暂停”或失去活力。
MillOptimize 引入了一个持久化层:
- 活跃状态追踪:模组会记住玩家最后访问过的村庄。
- 持续进化:即使玩家断开连接,村庄仍会继续建设、扩张并正常运作。
- 持久化层:使用 NBT 数据确保村庄进度在不同会话之间正确保存和恢复。
- 服务器和谐:设计初衷是让世界保持“鲜活”,同时避免不必要的 CPU 峰值。
? AI 节流(基于距离的优化)
- 智能感知:模组会检测处于玩家直接 vicinity(100 格以外)之外的 NPC。
- 动态节流:它会自动禁用这些 NPC 的目标调度器。
- 结果:在广袤的地图中,由于你同一时间只能看到部分居民,这能大幅降低 CPU 开销。
? 村庄搜索缓存
通过缓存玩家的最后位置,减少重型村庄搜索操作的频率。如果玩家没有显著移动,模组会防止不必要的高昂区块重新计算。
- 防止因频繁查找村庄而导致的“卡顿”。
- 通过缓存玩家的最后位置,如果玩家静止或缓慢移动,模组可避免沉重的区块重新计算。
⚙️ 技术细节
- 模组类型: 优化 / 插件
- 优化策略: 动态节流和基于 NBT 的状态管理。
许可证
MIT
? 安装方法
- 确保已安装 Millénaire 9.0.0-beta.1。
- 将
milloptimize.jar 文件放入你的 mods 文件夹。
- 享受无卡顿、充满活力的世界!
本项目是 MillMix_Jubi 的分支。
我的 GitHub -
Overview
MillOptimize is a high-performance optimization addon specifically engineered for the Millénaire mod. It is designed to help maintain high TPS (Ticks Per Second) in large-scale settlements by optimizing how NPC AI is handled and how villages are processed.
? Target Environment
- Minecraft Version: 1.21.1
- Target Mod: Millénaire 9.0.0-beta.1
- Platform: NeoForge
Key Features
? The Core Mission
As settlements grow, the computational load of NPC AI and village mechanics can become overwhelming for even the most powerful servers. MillOptimize bridges the gap between "realistic simulation" and "smooth gameplay" by intelligently throttling non-essential background processes.
? Evolution & Heritage
This project is a dedicated fork and successor to MillMix_Jubi.
? Village Persistence (The "Cherry on Top")
Unique to this version.
In standard Millénaire, villages often "pause" or lose their momentum when no players are nearby or if a player disconnects.
MillOptimize introduces a persistence layer:
- Active State Tracking: The mod remembers the last village visited by the player.
- Continuous Evolution: Villages continue to build, expand, and function even after a player disconnects.
- Persistence Layer: Uses NBT data to ensure that village progress is saved and restored correctly between sessions.
- Server Harmony: Designed to keep the world "alive" without causing unnecessary CPU spikes.
? AI Throttling (Distance-Based Optimization)
- Smart Awareness: The mod detects NPCs that are outside the player's immediate vicinity (beyond 100 blocks).
- Dynamic Throttling: It automatically disables the goal scheduler for these NPCs.
- Result: Massive reduction in CPU overhead in sprawling maps where you only see a fraction of the inhabitants at any one time.
? Village Search Caching
Reduces the frequency of heavy village search operations by caching the player's last position. If the player hasn't moved significantly, the mod prevents unnecessary expensive chunk recalculations.
- Prevents the "stutter" often caused by frequent village lookups.
- By caching the player's last position, the mod avoids heavy chunk recalculations if the player is stationary or moving slowly.
⚙️ Technical Details
- Mod Type: Optimization / Addon
- Optimization Strategy: Dynamic throttling and NBT-based state management.
License
MIT
? Installation
- Ensure you have Millénaire 9.0.0-beta.1 installed.
- Place the
milloptimize.jar file into your mods folder.
- Enjoy a lag-free, living world!
This project is a fork of MillMix_Jubi.
My GitHub -
评论 0
登录后参与评分
还没有评论,来抢沙发吧