Harium | 通用优化
通过智能代码替换实现高效性能
什么是 Harium
Harium 是一个通用优化模组(基于 Lithium),它将低效的原版代码重写为更快、更智能的实现方式——同时不改变游戏行为。
同样的游戏,更好的性能。
Harium 针对 Minecraft 中 CPU 密集型最高的系统:实体处理、红石、AI、漏斗和物理引擎——用优化的替代算法替换缓慢的逻辑,产生完全相同的结果。
优化类别
每个类别均可单独启用或禁用。
- AI & 寻路:更快的方块类型查找、优化的 POI 搜索、移除无用行为
- 实体系统:基于区块的移动追踪、优化的碰撞检测、更智能的物品合并
- 方块与红石:优化的红石导线功率计算、非活跃方块实体休眠机制
- 漏斗与物品栏:事件驱动的漏斗逻辑并引入缓存——仅在物品栏真正发生变化时才扫描漏斗
- 内存分配:使用 FastUtil 集合消除热路径中不必要的对象创建
- VoxelShapes(体素形状):针对快速碰撞检测和光线追踪的专用形状实现
- 集合类:在整个代码库中将标准 Java 集合替换为经过优化的 FastUtil 替代品
关键技术手段
- 事件驱动架构:方块区块仅在发生变更时通知监听器,而非每 tick 轮询
- 缓存层:对方块状态、实体位置和物品内容设置多级缓存
- 智能迭代:按区块顺序遍历实体,以提升 CPU 缓存局部性并支持提前终止
- 减少锁竞争:使用基于数组的数据跟踪条目替代同步映射
分支信息
Harium 是 Lithium 的一个分支,原版由 jellysquid3 开发。
兼容性:旨在完全兼容原版行为。不改变任何游戏玩法。
致谢与支持
原版 Lithium 由 jellysquid3 创建,并由社区维护。
Harium 通过额外的改进扩展了优化覆盖范围。
加入社区
在我们的 Discord 获取帮助与更新。
加入 Discord
Harium - 由 Hari 维护 - 高性能 Minecraft
82 link Description: Harium Create a server and get 25% off your first month Create Server, Value: url-shortener.curseforge.com/g07nH
本项目描述由 AI 辅助准备。
Harium | General Purpose Optimization
Smart Performance Through Intelligent Code Replacement
What Is Harium
Harium is a general-purpose optimization mod (based on Lithium) that rewrites inefficient vanilla code with faster, smarter implementations — without changing game behavior.
Same Game. Better Performance.
Harium targets the most CPU-intensive systems in Minecraft: entity processing, redstone, AI, hoppers, and physics — replacing slow algorithms with optimized alternatives that produce identical results.
Optimization Categories
Each category can be individually enabled or disabled.
- AI & Pathfinding: Faster block type lookups, optimized POI searches, removed useless behaviors
- Entity System: Section-based movement tracking, optimized collision detection, smarter item merging
- Block & Redstone: Optimized redstone wire power calculations, BlockEntity sleeping for inactive tiles
- Hopper & Inventory: Event-driven hopper logic with caching — hoppers only scan when inventories actually change
- Memory Allocations: Eliminates unnecessary object creation in hot code paths using FastUtil collections
- VoxelShapes: Specialized shape implementations for faster collision detection and ray tracing
- Collections: Replaces standard Java collections with optimized FastUtil alternatives throughout
Key Technical Approaches
- Event-Driven Architecture: Block sections notify listeners only when changes occur, instead of polling every tick
- Caching Layers: Multiple levels of caching for block states, entity positions, and inventory contents
- Smart Iteration: Chunk-ordered entity iteration for better CPU cache locality and early termination
- Reduced Locking: Array-based data tracker entries instead of synchronized maps
Fork Information
Harium is a fork of Lithium by jellysquid3.
Compatible: Designed to be fully compatible with vanilla behavior. No gameplay changes.
Credits & Support
Original Lithium created by jellysquid3 and maintained by the community.
Harium extends the optimization coverage with additional improvements.
Join the Community
Get help and updates on our Discord.
JOIN DISCORD
Harium - Maintained by Hari - High Performance Minecraft
82 link Description: Harium Create a server and get 25% off your first month Create Server, Value: url-shortener.curseforge.com/g07nH
This project description was prepared with AI assistance.
评论 0
登录后参与评分
还没有评论,来抢沙发吧