Assorted Lib
A library mod that does nothing on it's own. But will be a requirement for the new versions of my different Assorted mods.
This includes a number of utilities to make it easier to support both Forge and Fabric versions.
This does not require any other mod/tool besides the usual for each environment. (Forge itself and the Fabric Loader and Fabric API)
All Versions
+ Add Version- Fixed players getting kicked with Invalid player data when Iris is installed
- Fixed players getting kicked with Invalid player data when Iris is installed
Updated to Minecraft 26.3, for NeoForge and Fabric.
- Recipes, loot tables and advancements are registry entries in 26.3, so a mod's NeoForge datagen
ForgeRegistryEntries along with its worldgen. It replacesForgeDatapackRegistryProvider and the recipe Runners, and still writes the files for both loaders.ConditionalRecipeProviderandLibBlockLootProviderare built from 26.3's datagen contexts, and
IConditionHelper#conditionalContext gives each entry its load conditions.- Fuel is an item component now.
IPlatformHelper#isFuelchecks an item on either side,
#getFuelTime gives its burn time in a furnace, another block or anywhere on the server, andBurnTimes names the burn times a mod's fuels use.CompostChancesandIPlatformHelper#modifyDefaultComponentsset components on items, which is
LootTableModificationContext#lootTablegives the holder a nested loot table needs now.SubmitHelperkeeps thesubmitModelcalls that drew the block breaking overlay.BlockPosUtilkeeps the box shaped block searchesBlockPosno longer has.- On NeoForge the blocks given to
registerFlammablego in NeoForge's flammable data map, written
HandWrittenData#advancementreads an advancement a mod writes as json by hand back through
- A manual recipe page skips the recipes that are not loaded, such as ones an optional mod adds, and
ClientModelCheckandManualCheckare client gametest helpers. They find blocks and items that
CommonTestsregisters four gametests every mod can share. They check that each recipe is made from
item is in a creative tab, apart from any the mod names as kept out on purpose.
ClientChecks runs the client checks from a Fabric client gametest, andTestSupport#mortalPlayer gives a test player that can be hurt. ClientModelCheck also readies everyentity's renderer, and
CommonTests#upgradesThatLoseTheirData checks that storage upgrade recipes keepwhat the upgraded item held.
- The
assortedlib:recipe_existsdisplay condition hides a manual page until one of its recipes is
ChapterBuilder#optionalRecipes adds a recipe page with it, for recipes another mod'singredient turns on. The manual checks its conditions again once recipes reach the client.
Updated to Minecraft 26.3, for NeoForge and Fabric.
- Recipes, loot tables and advancements are registry entries in 26.3, so a mod's NeoForge datagen
ForgeRegistryEntries along with its worldgen. It replacesForgeDatapackRegistryProvider and the recipe Runners, and still writes the files for both loaders.ConditionalRecipeProviderandLibBlockLootProviderare built from 26.3's datagen contexts, and
IConditionHelper#conditionalContext gives each entry its load conditions.- Fuel is an item component now.
IPlatformHelper#isFuelchecks an item on either side,
#getFuelTime gives its burn time in a furnace, another block or anywhere on the server, andBurnTimes names the burn times a mod's fuels use.CompostChancesandIPlatformHelper#modifyDefaultComponentsset components on items, which is
LootTableModificationContext#lootTablegives the holder a nested loot table needs now.SubmitHelperkeeps thesubmitModelcalls that drew the block breaking overlay.BlockPosUtilkeeps the box shaped block searchesBlockPosno longer has.- On NeoForge the blocks given to
registerFlammablego in NeoForge's flammable data map, written
HandWrittenData#advancementreads an advancement a mod writes as json by hand back through
- A manual recipe page skips the recipes that are not loaded, such as ones an optional mod adds, and
ClientModelCheckandManualCheckare client gametest helpers. They find blocks and items that
CommonTestsregisters four gametests every mod can share. They check that each recipe is made from
item is in a creative tab, apart from any the mod names as kept out on purpose.
ClientChecks runs the client checks from a Fabric client gametest, andTestSupport#mortalPlayer gives a test player that can be hurt. ClientModelCheck also readies everyentity's renderer, and
CommonTests#upgradesThatLoseTheirData checks that storage upgrade recipes keepwhat the upgraded item held.
- The
assortedlib:recipe_existsdisplay condition hides a manual page until one of its recipes is
ChapterBuilder#optionalRecipes adds a recipe page with it, for recipes another mod'singredient turns on. The manual checks its conditions again once recipes reach the client.
IPlatformHelper#registerFlammablelets fire spread to and burn away a mod's block, with the
PlayerDeathDropsEventfires once a player's death is final, after any totem, and before their
the drops.
IClientHelper#registerLevelSubmitadds geometry to every level frame, after entities and
- Registry aliases, for a mod that moves its content to a new id:
IRegistryFactory#alias, or
RegistryProvider#aliasFrom(oldNamespace) to alias everything a provider registers. A worldsaved under the old ids loads the same entities, items and blocks.
SharedCreativeTabsgives a family of mods one creative tab between them, registered by
- A mod's manual chapters can join another namespace's section:
LibManualProvidertakes a
icon can list several items, the first registered drawn.MovedIdskeeps a player's recipe book and advancement progress when a mod moves its recipes and
inherit(oldNamespace, newNamespace), and renameCriteria for criteriathat were renamed. It also carries over structures already in a world and the loot of chests
that were never opened.
migration.carryOverMovedIds in the new assortedlib-common.toml (.json on Fabric) turns it off.ICanColormarks a block a paint roller can recolor, so blocks from one mod take another mod's paint.AdvancementIconsdraws an advancement with the first of several items that is installed, for a
- Mods can join a family to share a creative tab and manual section, and each one can be turned off in the family's parts config.
creative.hideUncraftableItemsinassortedlib-common.toml(.jsonon Fabric) hides items from the creative menu when nothing installed
CreativeTabItems#addIfObtainable, and ItemUtil.isTagEmpty does the check.- The storage pieces Assorted Storage's parts share now live here, so they can become separate mods.
core.storage has StorageMaterial, the base storage block, block entity and menus, andcore.storage.ender the locked ender inventories. Their screens are in client.screen.storage.- The chest, barrel, hopper and shulker box blocks are here too, with their block entities, menus,
materials. Nothing is registered by Lib. A mod hands its blocks the block entity and menu types it
registered through
StorageTypes, and a block entity takes its type from its block.LockConversionssays what a lock turns a block into, so one padlock locks the containers of
LockItems and the new c:locks and c:keys tags let a containertake a lock or check a key without knowing the mod that adds them.
LevelUpgradessays how a mod's containers upgrade from one material to the next, so a level
StorageAccessUtilmoved here too, andregisterKeySourceadds somewhere else a key can be, such
SharedDataComponentsgives a family of mods one data component type between them, registered
StorageInfo, the lock and level lines on storage items, usesit, and the shared container backgrounds are Lib's own textures now.
core.toolholds the tool materials Assorted Tools' parts share.ToolTiers.get()gives wood through
assortedlib-tool-tiers.toml, which onlyexists once a mod asks for it.
ArmorMaterialConfig, ConfigurableArmorItem, ConfigurableTieredItemand
HarvestTiers came with them.ISwitchModesitems share one switch-modes key, Z by default. A mod turns it on with
ModeSwitching.enable() and, on the client, ModeSwitchKey.enable(); without one, there is no keyand no packet.
MovedIdsalso carries over data-driven entries saved under an old id, such as an enchantment on an
IConditionHelper#conditionalOutputtakes a function from a recipe id to its conditions instead of a map. A mod that calls it directly can passmap::get.- Fixed recipe conditions, tooltips and biome changes that could go missing on NeoForge when several mods added them at the same time while loading.
IPlatformHelper#registerFlammablelets fire spread to and burn away a mod's block, with the
PlayerDeathDropsEventfires once a player's death is final, after any totem, and before their
the drops.
IClientHelper#registerLevelSubmitadds geometry to every level frame, after entities and
- Registry aliases, for a mod that moves its content to a new id:
IRegistryFactory#alias, or
RegistryProvider#aliasFrom(oldNamespace) to alias everything a provider registers. A worldsaved under the old ids loads the same entities, items and blocks.
SharedCreativeTabsgives a family of mods one creative tab between them, registered by
- A mod's manual chapters can join another namespace's section:
LibManualProvidertakes a
icon can list several items, the first registered drawn.MovedIdskeeps a player's recipe book and advancement progress when a mod moves its recipes and
inherit(oldNamespace, newNamespace), and renameCriteria for criteriathat were renamed. It also carries over structures already in a world and the loot of chests
that were never opened.
migration.carryOverMovedIds in the new assortedlib-common.toml (.json on Fabric) turns it off.ICanColormarks a block a paint roller can recolor, so blocks from one mod take another mod's paint.AdvancementIconsdraws an advancement with the first of several items that is installed, for a
- Mods can join a family to share a creative tab and manual section, and each one can be turned off in the family's parts config.
creative.hideUncraftableItemsinassortedlib-common.toml(.jsonon Fabric) hides items from the creative menu when nothing installed
CreativeTabItems#addIfObtainable, and ItemUtil.isTagEmpty does the check.- The storage pieces Assorted Storage's parts share now live here, so they can become separate mods.
core.storage has StorageMaterial, the base storage block, block entity and menus, andcore.storage.ender the locked ender inventories. Their screens are in client.screen.storage.- The chest, barrel, hopper and shulker box blocks are here too, with their block entities, menus,
materials. Nothing is registered by Lib. A mod hands its blocks the block entity and menu types it
registered through
StorageTypes, and a block entity takes its type from its block.LockConversionssays what a lock turns a block into, so one padlock locks the containers of
LockItems and the new c:locks and c:keys tags let a containertake a lock or check a key without knowing the mod that adds them.
LevelUpgradessays how a mod's containers upgrade from one material to the next, so a level
StorageAccessUtilmoved here too, andregisterKeySourceadds somewhere else a key can be, such
SharedDataComponentsgives a family of mods one data component type between them, registered
StorageInfo, the lock and level lines on storage items, usesit, and the shared container backgrounds are Lib's own textures now.
core.toolholds the tool materials Assorted Tools' parts share.ToolTiers.get()gives wood through
assortedlib-tool-tiers.toml, which onlyexists once a mod asks for it.
ArmorMaterialConfig, ConfigurableArmorItem, ConfigurableTieredItemand
HarvestTiers came with them.ISwitchModesitems share one switch-modes key, Z by default. A mod turns it on with
ModeSwitching.enable() and, on the client, ModeSwitchKey.enable(); without one, there is no keyand no packet.
MovedIdsalso carries over data-driven entries saved under an old id, such as an enchantment on an
IConditionHelper#conditionalOutputtakes a function from a recipe id to its conditions instead of a map. A mod that calls it directly can passmap::get.- Fixed recipe conditions, tooltips and biome changes that could go missing on NeoForge when several mods added them at the same time while loading.
IWorldGenHelper#addCustomSpawneradds a custom spawner to every server level, beside vanilla's
- Mods can add creatures now.
IPlatformHelper#registerEntityAttributesand
#registerSpawnPlacement register a mob's attributes and where it may spawn, andIWorldGenHelper#addSpawnToBiomes adds it to the natural spawns of the biomes. Spawns are added in the same order on both loaders.
IWorldGenHelper#addSpawnToStructuresadds a creature to the natural spawns inside the structures
spawns there, and nothing is taken away.
- Long item descriptions in tooltips wrap onto several lines instead of running across the screen.
IWorldGenHelper#addCustomSpawneradds a custom spawner to every server level, beside vanilla's
- Mods can add creatures now.
IPlatformHelper#registerEntityAttributesand
#registerSpawnPlacement register a mob's attributes and where it may spawn, andIWorldGenHelper#addSpawnToBiomes adds it to the natural spawns of the biomes. Spawns are added in the same order on both loaders.
IWorldGenHelper#addSpawnToStructuresadds a creature to the natural spawns inside the structures
spawns there, and nothing is taken away.
- Long item descriptions in tooltips wrap onto several lines instead of running across the screen.
- Features added to biomes now go in the same order on both loaders, so one seed gives one
NeoForge side added them in registration order while Fabric sorts by the placed feature's id -
identical terrain, every scattered feature somewhere else. NeoForge now sorts the same way.
- Added the instruction manual: an in-game book that any mod depending on Assorted Lib can add a
assets/<modid>/manual/*.json, so a resource pack can extendor rewrite them. Right clicking a block, item or creature that has a page opens the book there,
and the book shows two pages at once.
- Recipe pages are drawn on the screen of the container that makes them, taken from that container's own texture. A container's fuel and tool slots are drawn too, cycling through what they accept.
- The whole manual is data: the book's own look, which mods are in the index, their chapters, which
resource packs, so a pack can move a slot, re-point a link, re-skin the book or rewrite a chapter
without touching a mod.
- Holding the manual puts a green check mark beside the crosshair when whatever it is on has a page,
manual.showPageIndicator.- Right clicking an item frame with the manual opens the page of the item on display.
- Features added to biomes now go in the same order on both loaders, so one seed gives one
NeoForge side added them in registration order while Fabric sorts by the placed feature's id -
identical terrain, every scattered feature somewhere else. NeoForge now sorts the same way.
- Added the instruction manual: an in-game book that any mod depending on Assorted Lib can add a
assets/<modid>/manual/*.json, so a resource pack can extendor rewrite them. Right clicking a block, item or creature that has a page opens the book there,
and the book shows two pages at once.
- Recipe pages are drawn on the screen of the container that makes them, taken from that container's own texture. A container's fuel and tool slots are drawn too, cycling through what they accept.
- The whole manual is data: the book's own look, which mods are in the index, their chapters, which
resource packs, so a pack can move a slot, re-point a link, re-skin the book or rewrite a chapter
without touching a mod.
- Holding the manual puts a green check mark beside the crosshair when whatever it is on has a page,
manual.showPageIndicator.- Right clicking an item frame with the manual opens the page of the item on display.
- An item transfer that is rolled back no longer rebuilds the slot it touched from a single stack,
- On Fabric, a block whose slot count changes while it runs is no longer frozen at the count it had
- An item transfer that is rolled back no longer rebuilds the slot it touched from a single stack,
- On Fabric, a block whose slot count changes while it runs is no longer frozen at the count it had
Updated to Minecraft 26.2, for NeoForge and Fabric.
- Rebuilt on the 26.2 registry, model, networking and inventory APIs.
Updated to Minecraft 26.2, for NeoForge and Fabric.
- Rebuilt on the 26.2 registry, model, networking and inventory APIs.