-
Notifications
You must be signed in to change notification settings - Fork 0
Dynamic GameRules Reference
Dasik (Rifaditya) edited this page Aug 9, 2026
·
1 revision
Stack Size Adjuster registers namespaced GameRules via DynamicGameRuleManager from DasikLibrary. All rules belong to the custom category stack-size-adjuster:stack-size-adjuster.
| GameRule Key | Type | Default | Min / Max Bound | Description |
|---|---|---|---|---|
stack-size-adjuster:items_64_limit |
Integer | 128 |
Stack size cap for items naturally stacking to 64. | |
stack-size-adjuster:items_16_limit |
Integer | 32 |
Stack size cap for items naturally stacking to 16. | |
stack-size-adjuster:items_1_limit |
Integer | 1 |
Stack size cap for naturally unstackable items. | |
stack-size-adjuster:max_drop_entities |
Integer | 8 |
Maximum item entities spawned per slot on container break. |
/gamerule stack-size-adjuster:items_64_limit
/gamerule stack-size-adjuster:items_64_limit 512
/gamerule stack-size-adjuster:max_drop_entities 4
When a world is generated or loaded:
-
StackSizeConfig(globalconfig/stack-size-adjuster.json) sets the default template values for newly created worlds. - For existing worlds, changing GameRules in-game via
/gameruleor the GameRule GUI updatesStackSizeManagerin real-time. - Modifying a GameRule triggers
MinecraftServerMixin.onGameRuleChanged:@Inject(method = "onGameRuleChanged", at = @At("TAIL")) private <T> void onGameRuleChanged(GameRule<T> rule, T value, CallbackInfo ci) { Identifier ruleId = rule.getIdentifier(); if (ruleId != null && ruleId.getNamespace().equals("stack-size-adjuster")) { if (value instanceof Integer intVal) { StackSizeManager.setLimit(ruleId.getPath(), intVal, (MinecraftServer) (Object) this); } } }
- The server automatically broadcasts
StackSizeLimitSyncPayloadto all online players and callsplayer.containerMenu.broadcastFullState().
๐ Repository Source Disclaimer: The documentation in this Wiki reflects the current source code state in the repository, which may include recent unreleased commits or developmental features ahead of public release builds on CurseForge and Modrinth.
Copyright ยฉ 2026 Dasik (Rifaditya). Licensed under the GNU General Public License v3.0 (GPLv3).
๐ Home
- Dynamic GameRules
- Category Stack Limits
- Container Drop Optim.
- Large Chest Overflow
- ModMenu & YACL Config
- Item Count Rendering
- Item Clumps Synergies
- Troubleshooting & FAQ
- Developer Setup
- Architecture Layout
- Mixin Reference
- Addon Override API
- Network Sync Protocol
- Give Command Handling
- Behavior Profiles
- Consumer Mods Guide
- Performance Impact
- Advancements Matrix
- Author: Dasik (Rifaditya)
- License: GPL-3.0-or-later