TheDragonLib is a library mod that provides some essential utils and functionality for most of sokratis12GR's mods.
How to Install TheDragonLib (Mod)
TheDragonLib by sokratis12GR is verified for Forge, Neoforge across Minecraft versions 1.16.3, 1.16.4, 1.16.5, 1.18.1, 1.18.2, 1.19, 1.19.1, 1.19.2 (latest release: 1.1.0, file size: 93 KB). Follow the steps below to install it safely from ModCraft.tv:
- Click the Download button above and select your Minecraft version (1.16.3, 1.16.4, 1.16.5, 1.18.1, 1.18.2, 1.19, 1.19.1, 1.19.2) and platform (Forge, Neoforge).
- Make sure you have the compatible loader or environment installed for Forge, Neoforge.
- Move the downloaded TheDragonLib file into your Minecraft
.minecraft/modsfolder and launch the game.
All Versions
+ Add Version### New Utilities
- Added
util.ModCompat.isLoaded(String modId)— a one-line check for whether another mod is loaded, replacing hand-rolled per-mod loader enums. - Added
util.RomanNumeralUtil.generate(int)— converts an int to a Roman numeral string.
### New Client Rendering Helpers
- Added
client.util.PoseStackHelper.translateAndScale/rotateItem— commonPoseStacktransforms for drawing anItemStackat an offset inside a block entity renderer. - Added
client.util.RenderingUtils.swing/flap/bob/walk— limb-animation math forModelParts.
### New Config/GUI Helpers
- Added
client.config.RegistryCandidates— turns a built-in or datapack registry (entities, items, blocks, attributes, enchantments, biomes) into a searchable candidate list forEntryPickerScreen, including a fallback for datapack-driven registries (biomes, enchantments) when no world is loaded, e.g. editing config from the title screen. - Added a second, heavier config-list editor for pipe-delimited, multi-field config rows:
client.config.RuleType(field schema with per-field validation),RuleSuggestionSource(caller-supplied id lookups),RuleListContext(translation key prefixes),RuleListScreenandRuleEditScreen. This complements the existing append-onlyPickerListScreenfor config lists that need several validated fields per row, edited in place. - Added
ConfigHelper.getOrDefault/ConfigHolder.getOrDefault— a guard that returns a fallback instead of throwingIllegalStateExceptionwhen a config value is read before its spec is loaded (e.g. datagen or other contexts where no config file is ever loaded, such as a block'sisEnabled(FeatureFlagSet)check running under the loot table provider).
### Internal Cleanup
- No breaking changes to existing public APIs.
- Fixed crashing due to
@OnlyInremnants.
# 26.1.2 - 1.1.0
### New Config Core
- Added
config.ConfigHelper/ConfigHolder— cuts out theForgeConfigSpec.Builder().configure(...)boilerplate perModConfig.Type, plus agetOrDefaultguard that returns a fallback instead of throwingIllegalStateExceptionwhen a config value is read before its spec is loaded (e.g. datagen).
### New Config GUI - Full Spec Editor
- Added
client.config.ConfigScreenHelper/ConfigSpecScreen— a reflection-driven editor for an entireForgeConfigSpec: booleans/enums as cycle buttons, numbers/strings as validated text boxes, lists opening a list screen, and nested sections as child screens of the same kind. Wired up through Forge's config-screen extension point without pullingScreeninto common code.
### New Config GUI - List Editors
- Added
client.config.StringListScreen— a generic add/edit/remove editor for aList-typedForgeConfigSpec.ConfigValue. - Added
client.config.PickerListScreen/EntryPicker/EntryPickerScreen— extendsStringListScreenwith a searchable, category-filterable, single- or multi-select picker for adding entries to a config list. - Added
client.config.RegistryCandidates— turns a built-in or datapack registry (entities, items, blocks, attributes, enchantments, biomes) into a searchable candidate list forEntryPickerScreen, including a fallback for datapack-driven registries when no world is loaded, e.g. editing config from the title screen.
### New Config GUI - Rule List Editor
- Added
client.config.RuleType/RuleSuggestionSource/RuleListContext/RuleListScreen/RuleEditScreen— a heavier config-list editor for pipe-delimited, multi-field config rows with per-field validation and id suggestions, for config lists that need several validated fields per row.
### New Client Rendering/Utility Helpers
- Added
client.util.PoseStackHelper.translateAndScale/rotateItem— commonPoseStacktransforms for drawing anItemStackat an offset inside a block entity renderer. - Added
client.util.RenderingUtils.swing/flap/bob/walk— limb-animation math forModelParts. - Added
util.ModCompat.isLoaded(String modId)— a one-line check for whether another mod is loaded, replacing hand-rolled per-mod loader enums. - Added
util.RomanNumeralUtil.generate(int)— converts an int to a Roman numeral string.
### Internal Cleanup
- No breaking changes to existing public APIs.
### New Config Core
- Added
config.ConfigHelper/ConfigHolder— cuts out theForgeConfigSpec.Builder().configure(...)boilerplate perModConfig.Type, plus agetOrDefaultguard that returns a fallback instead of throwingIllegalStateExceptionwhen a config value is read before its spec is loaded (e.g. datagen).
### New Config GUI - Full Spec Editor
- Added
client.config.ConfigScreenHelper/ConfigSpecScreen— a reflection-driven editor for an entireForgeConfigSpec: booleans/enums as cycle buttons, numbers/strings as validated text boxes, lists opening a list screen, and nested sections as child screens of the same kind. Wired up through Forge's config-screen extension point without pullingScreeninto common code.
### New Config GUI - List Editors
- Added
client.config.StringListScreen— a generic add/edit/remove editor for aList-typedForgeConfigSpec.ConfigValue. - Added
client.config.PickerListScreen/EntryPicker/EntryPickerScreen— extendsStringListScreenwith a searchable, category-filterable, single- or multi-select picker for adding entries to a config list. - Added
client.config.RegistryCandidates— turns a built-in or datapack registry (entities, items, blocks, attributes, enchantments, biomes) into a searchable candidate list forEntryPickerScreen, including a fallback for datapack-driven registries when no world is loaded, e.g. editing config from the title screen.
### New Config GUI - Rule List Editor
- Added
client.config.RuleType/RuleSuggestionSource/RuleListContext/RuleListScreen/RuleEditScreen— a heavier config-list editor for pipe-delimited, multi-field config rows with per-field validation and id suggestions, for config lists that need several validated fields per row.
### New Client Rendering/Utility Helpers
- Added
client.util.PoseStackHelper.translateAndScale/rotateItem— commonPoseStacktransforms for drawing anItemStackat an offset inside a block entity renderer. - Added
client.util.RenderingUtils.swing/flap/bob/walk— limb-animation math forModelParts. - Added
util.ModCompat.isLoaded(String modId)— a one-line check for whether another mod is loaded, replacing hand-rolled per-mod loader enums. - Added
util.RomanNumeralUtil.generate(int)— converts an int to a Roman numeral string.
### Internal Cleanup
- No breaking changes to existing public APIs.
### Fixes
- Added
ConfigHelper.getOrDefault/ConfigHolder.getOrDefault— a guard that returns a fallback instead of throwingIllegalStateExceptionwhen a config value is read before its spec is loaded (e.g. datagen or other contexts where no config file is ever loaded, such as a block'sisEnabled(FeatureFlagSet)check running under the loot table provider).
# 26.1.2 - 1.2.0
### New Utilities
- Added
util.ModCompat.isLoaded(String modId)— a one-line check for whether another mod is loaded, replacing hand-rolled per-mod loader enums. - Added
util.RomanNumeralUtil.generate(int)— converts an int to a Roman numeral string.
### New Client Rendering Helpers
- Added
client.util.PoseStackHelper.translateAndScale/rotateItem— commonPoseStacktransforms for drawing anItemStackat an offset inside a block entity renderer. - Added
client.util.RenderingUtils.swing/flap/bob/walk— limb-animation math forModelParts.
### New Config/GUI Helpers
- Added
client.config.RegistryCandidates— turns a built-in or datapack registry (entities, items, blocks, attributes, enchantments, biomes) into a searchable candidate list forEntryPickerScreen, including a fallback for datapack-driven registries (biomes, enchantments) when no world is loaded, e.g. editing config from the title screen. - Added a second, heavier config-list editor for pipe-delimited, multi-field config rows:
client.config.RuleType(field schema with per-field validation),RuleSuggestionSource(caller-supplied id lookups),RuleListContext(translation key prefixes),RuleListScreenandRuleEditScreen. This complements the existing append-onlyPickerListScreenfor config lists that need several validated fields per row, edited in place.
### Internal Cleanup
- No breaking changes to existing public APIs.
- Ported to 1.19
- Added support for 1.16.4 on the 1.16.3 version