All Projects → 2No2Name → hopperOptimizations

2No2Name / hopperOptimizations

Licence: MIT license
A mod that optimizes hoppers and their interactions with entities and inventories. It drastically reduces hopper lag without changing any behavior.

Programming Languages

java
68154 projects - #9 most used programming language

Projects that are alternatives of or similar to hopperOptimizations

ForgeModdingSkeleton
Skeletons for building Forge mods
Stars: ✭ 21 (-67.69%)
Mutual labels:  minecraft-mod
ICBM-Classic
Classic 1.6.4 version of ICBM remastered for newer MC versions
Stars: ✭ 34 (-47.69%)
Mutual labels:  minecraft-mod
LaplacianOpt.jl
A Julia/JuMP Package for Maximizing Algebraic Connectivity of Undirected Weighted Graphs
Stars: ✭ 16 (-75.38%)
Mutual labels:  optimization
Nutrition
A Minecraft mod that ensures you eat healthy.
Stars: ✭ 112 (+72.31%)
Mutual labels:  minecraft-mod
SpruceUI
A Minecraft library mod which adds a new abstraction to create GUI interfaces. Still close to the Vanilla design code-wise.
Stars: ✭ 47 (-27.69%)
Mutual labels:  minecraft-mod
Jumploader
Use Fabric mods in Twitch modpacks!
Stars: ✭ 19 (-70.77%)
Mutual labels:  minecraft-mod
Thistle
6502 based architecture for OpenComputers
Stars: ✭ 26 (-60%)
Mutual labels:  minecraft-mod
genx
Genx provides modular building blocks to run simulations of optimization and search problems using Genetic Algorithms
Stars: ✭ 31 (-52.31%)
Mutual labels:  optimization
Iodine
A Minecraft mod - server plugin pair that adds custom GUIs and overlays. No more inventory and chat menus!
Stars: ✭ 23 (-64.62%)
Mutual labels:  minecraft-mod
ForgeTutorial
Has all of the code for the modding tutorial
Stars: ✭ 26 (-60%)
Mutual labels:  minecraft-mod
meteor-rejects
An addon to Meteor Client that features that won't be added to Meteor. Because they were either rejected or are ports from other clients.
Stars: ✭ 144 (+121.54%)
Mutual labels:  minecraft-mod
ImageWorldGenerator
A minecraft mod to generate a world from an image/map
Stars: ✭ 20 (-69.23%)
Mutual labels:  minecraft-mod
NetherEx
No description or website provided.
Stars: ✭ 28 (-56.92%)
Mutual labels:  minecraft-mod
BetterAchievements
An improvement to the Minecraft achievement screen
Stars: ✭ 20 (-69.23%)
Mutual labels:  minecraft-mod
FabricProxy
Fabric mod for support forward player data from proxy
Stars: ✭ 40 (-38.46%)
Mutual labels:  minecraft-mod
cem
Reimplementation of Custom Entity Models in Minecraft for the Fabric Modloader
Stars: ✭ 92 (+41.54%)
Mutual labels:  minecraft-mod
Inspecio
A Minecraft mod which adds more tooltip components to items.
Stars: ✭ 87 (+33.85%)
Mutual labels:  minecraft-mod
ClientTweaks
Minecraft Mod. There, I fixed Minecraft for you. Various optional tweaks to improve Minecraft Quality of Life.
Stars: ✭ 13 (-80%)
Mutual labels:  minecraft-mod
Optimization
A set of lightweight header-only template functions implementing commonly-used optimization methods on Riemannian manifolds and convex spaces.
Stars: ✭ 66 (+1.54%)
Mutual labels:  optimization
no-tree-punching
A Minecraft mod which adds a bit of realism to the early game.
Stars: ✭ 28 (-56.92%)
Mutual labels:  minecraft-mod

This mod will no longer be updated. In Minecraft 1.17+ all hopper optimzations are in the optimization mod Lithium. The optimizations are generally even better than before.

Hopper Optimizations Mod

This Mod optimizes hoppers interacting with inventories and item entities. It implements optimizations without changing any observable behavior (besides the better performance). This branch of hopper optimizations requires installing my fork of Lithium.

Performance measurements are welcome. If you find a bug, please report it on the issue tracker. You can support me on patreon

Installation instructions

  • Install the fabric mod loader. https://fabricmc.net/use/
  • download both hopperOptimizations and my fork of Lithium
  • put both hopperOptimizations[...].jar and lithium-fabric-fork-by-2no2name[...].jar into the mods folder.
  • start the game (no configuration required)

Features

These features are speeding up minecraft hoppers, effectively fixing hopper lag. Besides the lag reduction the behavior is exactly like vanilla.

Inventory Optimizations

Inventories keep extra data such as a modification counter, an item type -> slot mask map, and empty & full slot masks. This allows replacing vanilla's linear search though the whole inventory with a few mask operations to find slots that the hopper can transfer from or to. If the previous transfer attempt failed, and both the hopper and the other inventory haven't increased their modification counter, the hopper can skip the next transfer attempt after mimicking the comparator updates the failed transfer of the naive vanilla implementation sends.

Entity Tracking

Hoppers register their entity search area to a modified version of Lithium's entity tracker engine (available in my fork of Lithium). Now entities notify hoppers about their arrival at hoppers when they move into their interaction area, instead of each hopper searching for entities to interact with in every tick. Only when entities move collisions with the hopper interaction areas need to be calculated.

Cache Inventories

Hoppers keep a reference to inventory blocks (block entities, double chests, or composters) until they are removed or otherwise become invalid. This is faster than looking up the inventory all the time.

Fast Signal Strength

Comparators use extra data from Inventories (item counter) to determine the signal strength of an inventory without accessing all slots.

Cached empty state of Item stacks

Item stacks cache whether they are empty in vanilla, but at the same time the value is recalculated often for no reason. Instead, we always use the cached value.

License

This project uses the MIT license. The Lithium Mod by JellySquid3 and my fork use a different license!

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].