
Utility mod that contains really useful code for quite a few mods.
This library provides:
- Simple, annotation-based content registration.
- For Blocks, HammerLib automagically registers BlockItem(s). If you want to disable BlockItem(s), let your block implement INoItemBlock, ICustomBlockItem, or ICreativeTabBlock, depending on what you want to achieve.
- For BlockEntity rendering, custom BlockEntityType constants may have additional @TileRenderer, pointing to an IBESR<Tile> class.
- Old-styled language parsers in format of "key=value", instead of JSONs (the file names and format is like in older game versions, but you need to call LanguageAdapter.registerMod(MOD_ID); inside your mod's constructor for it to register.
- Mod Source checks, that allow you to check if the mod was downloaded from adware/malware sites, AND warn users about it.
- Java-based recipe registration with a simple RegisterRecipesEvent, that runs on HammerLib.EVENT_BUS, allowing you, as a developer, to register crafting recipes like before, with code.
- Java-based tag population, with BuildTagsEvent, that runs on HammerLib.EVENT_BUS.
- Vastly simplified networking, using Network class, and IPacket + INBTPacket to allow for flawless and intuitive packet code development.
- Wrappers for block harvesting, that has been moved over to tags - BlockHarvestAdapter
- Field-based NBT serialization, so that you don't make a typo/forget to write serialization/deserialization code.
- Good old TileEntity wrappers, with TileSyncable and TileSyncableTickable, that allow synchronization of initial state, as well as registering properties that will be synchronized independently.
- ContainerAPI for BlockEntities, allowing to avoid MenuType<?> altogether (no need to register screen providers, menu types etc)
- ItemStack -> Color[] API, with TexturePixelGetter.getAllColors
- Annotation-based custom model loaders (@LoadUnbakedGeometry on IUnbakedGeometry<SELF>), avoids using the geometry loader class by making a common wrapper.
- ...And a whole lot more!
And a lot of rich features for mod devs.
Not enough? You can just view sources on GitHub, it's free!
![]()
Permissions:
- You can use this mod in your modpack.
- Yes, you are allowed to build a mod that requires Hammer Core, but not embeds it!
- You are not allowed to repost this mod to other sites without providing a CurseForge/Modrinth download link and my permission (
Zeitheron on Discord) - You are not allowed to include this (or any other mods of DragonForge team) in your own mod. Building addons, however, is allowed, but a friendly PM would be good.
Note:
- The only supported version of minecraft is the latest one that this mod exists for. DO NOT ASK TO DOWNGRADE!
Join the discord server and follow Zeitheron on Twitter!
If you would like to support my work, you can become a patron via . ![]()
All Versions
+ Add Version| Name | Game version | Platforms | Published | Downloads | Actions |
|---|---|---|---|---|---|
|
R
21.0.17
|
14h ago | 1 | |||
|
R
21.0.16
|
14h ago | 1 | |||
|
R
21.0.15
|
14h ago | 1 | |||
| 14h ago | 1 | ||||
| 14h ago | 1 | ||||
|
R
12.2.63
|
14h ago | 1 | |||
| 14h ago | 1 | ||||
| 14h ago | 1 | ||||
| 14h ago | 1 | ||||
| 14h ago | 1 | ||||
|
R
12.2.58
|
14h ago | 1 | |||
|
R
20.1.50
|
14h ago | 1 | |||
|
R
21.4.5
|
14h ago | 1 | |||
|
R
21.4.4
|
14h ago | 1 | |||
|
R
21.4.3
|
14h ago | 1 | |||
|
R
21.4.2
|
14h ago | 1 | |||
|
R
21.4.1
|
14h ago | 1 | |||
|
R
20.1.48
|
14h ago | 1 | |||
|
R
20.1.47
|
14h ago | 1 | |||
|
R
20.1.46
|
14h ago | 1 | |||
|
R
20.1.45
|
14h ago | 1 | |||
|
R
20.1.44
|
14h ago | 1 | |||
|
R
20.1.43
|
14h ago | 1 | |||
|
R
20.1.41
|
14h ago | 1 | |||
|
R
20.1.39
|
14h ago | 1 | |||
|
R
20.1.38
|
14h ago | 1 | |||
|
R
20.1.37
|
14h ago | 1 | |||
|
R
20.1.36
|
14h ago | 1 | |||
|
R
20.1.35
|
14h ago | 1 | |||
|
R
21.0.14
|
14h ago | 1 | |||
|
R
20.1.33
|
14h ago | 1 | |||
|
R
12.2.56
|
14h ago | 1 | |||
|
R
12.2.55
|
14h ago | 1 | |||
|
R
12.2.54
|
14h ago | 1 | |||
|
R
12.2.53
|
14h ago | 1 | |||
|
R
12.2.52
|
14h ago | 1 | |||
|
R
12.2.51
|
14h ago | 1 | |||
|
R
20.1.32
|
14h ago | 1 | |||
|
R
21.0.13
|
14h ago | 1 | |||
|
R
20.1.31
|
14h ago | 1 | |||
|
R
21.0.12
|
14h ago | 1 | |||
|
R
21.0.11
|
14h ago | 1 | |||
|
R
21.0.10
|
14h ago | 1 | |||
|
R
21.0.9
|
14h ago | 1 | |||
|
R
20.1.30
|
14h ago | 1 | |||
|
R
19.3.82
|
14h ago | 1 | |||
|
R
21.0.8
|
14h ago | 1 | |||
|
R
21.0.7
|
14h ago | 1 | |||
|
R
21.0.6
|
14h ago | 1 | |||
|
R
21.0.5
|
14h ago | 1 | |||
|
R
21.0.4
|
14h ago | 1 | |||
|
B
21.0.4
|
14h ago | 1 | |||
|
B
21.0.3
|
14h ago | 1 | |||
|
B
21.0.2
|
14h ago | 1 | |||
|
B
21.0.1
|
14h ago | 1 | |||
|
B
21.0.0
|
14h ago | 1 | |||
|
B
20.6.30
|
14h ago | 1 | |||
| 14h ago | 1 | ||||
|
B
20.6.29
|
14h ago | 1 | |||
|
B
20.5.29
|
14h ago | 1 | |||
|
R
20.4.29
|
14h ago | 1 | |||
|
R
20.3.29
|
14h ago | 1 | |||
|
R
20.2.29
|
14h ago | 1 | |||
|
R
20.1.29
|
14h ago | 1 | |||
|
R
19.3.81
|
14h ago | 1 | |||
|
B
20.6.28
|
14h ago | 1 | |||
|
B
20.5.28
|
14h ago | 1 | |||
|
R
20.4.28
|
14h ago | 1 | |||
|
R
20.3.28
|
14h ago | 1 | |||
|
R
20.2.28
|
14h ago | 1 | |||
|
R
20.1.28
|
14h ago | 1 | |||
| 14h ago | 1 | ||||
|
B
20.6.26
|
14h ago | 1 | |||
|
B
20.5.26
|
14h ago | 1 | |||
|
R
20.3.26
|
14h ago | 1 | |||
|
R
20.2.26
|
14h ago | 1 | |||
|
R
20.1.26
|
14h ago | 1 | |||
|
R
12.2.50
|
14h ago | 1 | |||
|
R
12.2.49
|
14h ago | 1 | |||
|
R
12.2.48
|
14h ago | 1 | |||
|
R
12.2.47
|
14h ago | 1 | |||
|
R
20.1.25
|
14h ago | 1 | |||
|
R
19.3.76
|
14h ago | 1 | |||
|
R
20.4.0
|
14h ago | 1 | |||
|
R
20.3.0
|
14h ago | 1 | |||
|
R
19.3.75
|
14h ago | 1 | |||
|
R
20.2.2
|
14h ago | 1 | |||
|
R
16.5.50
|
14h ago | 1 | |||
|
R
20.1.24
|
14h ago | 1 | |||
|
R
19.3.74
|
14h ago | 1 | |||
|
R
12.2.46
|
14h ago | 1 | |||
|
R
12.2.43
|
14h ago | 1 | |||
|
R
12.2.42
|
14h ago | 1 | |||
|
R
12.2.39
|
14h ago | 1 | |||
|
R
12.2.38
|
14h ago | 1 | |||
|
R
20.1.23
|
14h ago | 1 | |||
|
R
19.3.73
|
14h ago | 1 | |||
|
R
20.1.22
|
14h ago | 1 | |||
|
R
19.3.72
|
14h ago | 1 | |||
|
R
20.1.19
|
14h ago | 1 | |||
|
R
19.3.69
|
14h ago | 1 | |||
|
R
20.1.18
|
14h ago | 1 | |||
|
R
19.3.68
|
14h ago | 1 | |||
|
R
19.3.67
|
14h ago | 1 | |||
|
R
20.1.17
|
14h ago | 1 | |||
|
R
19.3.66
|
14h ago | 1 | |||
|
R
20.1.16
|
14h ago | 1 | |||
|
R
20.1.15
|
14h ago | 1 | |||
|
R
19.3.65
|
14h ago | 1 | |||
|
R
20.1.14
|
14h ago | 1 | |||
|
R
19.3.64
|
14h ago | 1 | |||
|
R
20.1.13
|
14h ago | 1 | |||
|
R
19.3.63
|
14h ago | 1 | |||
|
R
2.0.6.37
|
14h ago | 1 | |||
|
R
19.3.62
|
14h ago | 1 | |||
|
R
19.3.61
|
14h ago | 1 | |||
|
R
2.0.6.33
|
14h ago | 1 | |||
|
R
19.3.60
|
14h ago | 1 | |||
|
R
19.3.59
|
14h ago | 1 | |||
|
R
20.1.12
|
14h ago | 1 | |||
|
R
20.1.10
|
14h ago | 1 | |||
|
R
20.1.9
|
14h ago | 1 | |||
|
R
20.1.8
|
14h ago | 1 | |||
|
R
20.1.6
|
14h ago | 1 | |||
|
R
20.1.5
|
14h ago | 1 | |||
|
R
20.1.4
|
14h ago | 1 | |||
|
R
20.1.3
|
14h ago | 1 | |||
|
R
20.0.8
|
14h ago | 1 | |||
|
R
20.1.2
|
14h ago | 1 | |||
|
R
20.0.7
|
14h ago | 1 | |||
|
R
20.0.6
|
14h ago | 1 | |||
|
R
20.1.1
|
14h ago | 1 | |||
|
R
20.0.5
|
14h ago | 1 | |||
|
R
20.0.4
|
14h ago | 1 | |||
|
R
19.5.57
|
14h ago | 1 | |||
|
R
19.3.57
|
14h ago | 1 | |||
| 14h ago | 1 | ||||
| 14h ago | 1 | ||||
| 14h ago | 1 | ||||
| 14h ago | 1 | ||||
| 14h ago | 1 | ||||
| 14h ago | 1 | ||||
| 14h ago | 1 | ||||
| 14h ago | 1 | ||||
| 14h ago | 1 | ||||
| 14h ago | 1 | ||||
| 14h ago | 1 | ||||
| 14h ago | 1 |
Changelog:
- Port missing features from FlowGui 1.20.1; ([19cc5c798574d5c](https://github.com/dragon-forge/HammerLib/commit/19cc5c798574d5c)) by Zeith
Changelog:
- Port missing features from FlowGui 1.20.1;
- DistExecutor is back; (for very not safe things)
- Many utilities ported from 1.20.1;
Changelog:
- Merge pull request #73 from RuyaSavascisi/1.21.0 ([2f473c9dc4ab8af](https://github.com/dragon-forge/HammerLib/commit/2f473c9dc4ab8af)) by Zeith
- tr_tr.lang Turkish Localization ([99611ec91e7d87a](https://github.com/dragon-forge/HammerLib/commit/99611ec91e7d87a)) by RuyaSavascisi
- Fix javadoc typo. ([76c98bb9641d504](https://github.com/dragon-forge/HammerLib/commit/76c98bb9641d504)) by Zeith
- Update lombok and specify changelog generator version. ([60d9fc42a6cde0e](https://github.com/dragon-forge/HammerLib/commit/60d9fc42a6cde0e)) by Zeith
- [1.21] Update build.txt ([15f5bc4495c9252](https://github.com/dragon-forge/HammerLib/commit/15f5bc4495c9252)) by Zeith
- [1.21] Added ability to change click sound in GuiButtonObject; ([ce97be8df023022](https://github.com/dragon-forge/HammerLib/commit/ce97be8df023022)) by Zeith
# Changes:
- 12.2.66 - Fix ShaderLightingVariable producing absurd values on SteamOS.
- 12.2.65 - ResourceBasedShaderVar.postProcessCode.
<h3><a href="https://mcdoc.zeith.org/docs/intro">To get developer builds, see HammerLib wiki.</a></h3>
<h1>Changes:</h1>
<ul>
<li> 12.2.65 - ResourceBasedShaderVar.postProcessCode.</li>
<li> 12.2.65 - ShaderResource and ResourceBasedShaderVar.</li>
<li> 12.2.64 - ShaderVar.onReload, implement manual 30s timeout for ModSourceAdapter.</li>
<li> 12.2.63 - Several missing methods in KeyMap + its refactor to match later game versions.</li>
<li> 12.2.62 - Fix UUID NBT serialization to use int[4] (as single property) instead of old 1.12.2 two property approach (Most/Least suffixes).</li>
<li> 12.2.61 - Several profiling and data features, as well as async HTTP handling for mod sources at early start.</li>
<li> 12.2.60 - Fix crashing with ThaumicAdditions. (Close #86)</li>
<li> 12.2.59 - Fix maven-publish to force upload deobf artifact as main, and remove all runtime dependencies.</li>
</ul>
- Several missing methods in KeyMap + its refactor to match later game versions.
# Changes:
- 12.2.62 - Fix UUID NBT serialization to use int\[4\] (as single property) instead of old 1.12.2 two property approach (Most/Least suffixes).
# Changes:
- 12.2.61 - Several profiling and data features, as well as async HTTP handling for mod sources at early start.
# Changes:
- 12.2.60 - Fix crashing with ThaumicAdditions. (Close #86)
# Changes:
- 12.2.59 - Fix VariableShaderProgram's uniform cache being populated incorrectly and make default float values in the cache NaN, so regardless of what the first setUniform call will have - it will always go through.
- 12.2.59 - Cleanup a lot of unused things, optimize VariableShaderProgram by using hash maps instead of dumb array maps, as well as reuse previous shader states for int1/float1 uniforms, reducing amount of GL calls when the data is the same.
# Changes:
- Prevent shaders from reloading during preInit (because some mods force a reload on preinit for... some reason);
- Actually query ShaderVar state and recompile shader program whenever variables change;
- Utility methods for ColoredLight;
- Fix shader NPEs caused by null values;
- Reset shader variable hasChanged state on upload.
- Backport secure jar display in mod list;
- Proper synchronization with SimpleInventory change;
Changelog:
- Remove deprecated field HLConstants.CRAFTING_MATERIAL ([fa09ec0417d0d21](https://github.com/dragon-forge/HammerLib/commit/fa09ec0417d0d21)) by Zeith
- Update build.txt ([49f26d2eadee22b](https://github.com/dragon-forge/HammerLib/commit/49f26d2eadee22b)) by Zeith
Changelog:
- Add signed jar status display in mod list. ([e64350b5afc64e5](https://github.com/dragon-forge/HammerLib/commit/e64350b5afc64e5)) by Zeith
Changelog:
- [21.4.3] Add <hover> object to allow hiding things until hovered on. ([8191eadfb304740](https://github.com/dragon-forge/HammerLib/commit/8191eadfb304740)) by Zeith
- Remove NeoForge mod loader from modrinth loaders section since it determines the loader by itself. ([9d5b3eb54f41dcf](https://github.com/dragon-forge/HammerLib/commit/9d5b3eb54f41dcf)) by Zeith
Changelog:
- Expand server context inside RegisterRecipesEvent with registry access and recipe manager.
- RotationHelper.fromNormal
- RecipeHelper.NEOFORGE_MOD_ID_FOR_TAGS
- ObjectMirrorConverter.unwrap
- Fix FluidFactory.is(Fluid)
- Copy of
java.awt.Colorwithout loading Toolkit library (which will be unavailable on headless servers); - Tweaks to spoofed recipes (using multimaps)
- Remove experimental spoofed recipe access from RegisterRecipesEvent.
- Rework recipe builders to use less generics and allow any identifiable output to be used, not just items;
- Remove experimental spoofed recipe access from RegisterRecipesEvent;
Changelog:
- TableHelper.computeIfAbsent
- ShapeUtils
- RotatedShapeCache / RotatedShapeCacheSimple
- AABBUtils fixes
Changelog:
- EmissiveGeometry ("loader": "hammerlib:emissive") + DelegateBakedModel
- GuiObject.elementZPos
- tr_tr.lang Turkish Localization
Changelog:
- Add
render-widthandrender-heightto allow for independent image size from its UV size. - Text component drivers parse java string literals as well now.
Changelog:
- Add item decorations to GuiItemObject;
- Added GuiTooltipObject;
- Added a few add/remove hooks to GuiObject;
- Added GuiObject.drawTooltip for components to render tooltip if needed (like fluids and items);
- Abstract Tooltip interface for rendering tooltips in flowguis;
- GuiFluidObject for fluids;
- IExtendedFluidType for fluid rarity and tooltip image;
- Improvements to FluidHelper;
- Add effective way of converting nashorn JSON to Gson and Json through ObjectMirrorConverter;
- Added Suggestions for properties (API for HammerHelper)
Changelog:
- Add GuiItemObject (and <item/> flowgui xml tag);
- Add JeiKeyRole [obtained via IJeiPluginHL.get().getRoleForKey()] shortcut to show recipes/usages;
- Add GLStencil (and a config option to enable/disable stencils);
- Added ComDrivers.readString & ComDrivers;.driveString for support of dynamically driven text;
- Group few parameters into DriverContext;
- Added FlowguiShaderRegistry to allow customization of shaders on images and sprite buttons;
- Enable ES6 support in OpenJDKParser;
- Suppliers2 for mapping suppliers;
- GuiWidgetWrapperObject for embedding abstract widgets into GuiObject system;
Changelog:
- Add
render-widthandrender-heightto allow for independent image size from its UV size. - Text component drivers parse java string literals as well now.
Changelog:
- Flowgui XML improvements
Changelog:
- [1.21.4] Changes to data scanning. ([d7ebdf3dfbc0384](https://github.com/dragon-forge/HammerLib/commit/d7ebdf3dfbc0384)) by Zeith
- [1.21.4] Bring back CC Tweaked compat! ([98c1ce03cf79de2](https://github.com/dragon-forge/HammerLib/commit/98c1ce03cf79de2)) by Zeith
- [1.21.4] Languages are back up! ([27f5e06f042c131](https://github.com/dragon-forge/HammerLib/commit/27f5e06f042c131)) by Zeith
- [1.21.4] Cleanup unused glint shaders! ([b5eb83d47affb30](https://github.com/dragon-forge/HammerLib/commit/b5eb83d47affb30)) by Zeith
- [1.21.4] Fixed glint! ([3d19595124fdb9c](https://github.com/dragon-forge/HammerLib/commit/3d19595124fdb9c)) by Zeith
- [1.21.4] Fix shaders ([dcaaf62ff07e944](https://github.com/dragon-forge/HammerLib/commit/dcaaf62ff07e944)) by Zeith
- 1.21.4 ([c0c435cec8e5f36](https://github.com/dragon-forge/HammerLib/commit/c0c435cec8e5f36)) by Zeith
- 1.21.4 ([c3bc59f24191a75](https://github.com/dragon-forge/HammerLib/commit/c3bc59f24191a75)) by Zeith
- Fix javadoc typo. ([76c98bb9641d504](https://github.com/dragon-forge/HammerLib/commit/76c98bb9641d504)) by Zeith
- Update lombok and specify changelog generator version. ([60d9fc42a6cde0e](https://github.com/dragon-forge/HammerLib/commit/60d9fc42a6cde0e)) by Zeith
- [1.21] Update build.txt ([15f5bc4495c9252](https://github.com/dragon-forge/HammerLib/commit/15f5bc4495c9252)) by Zeith
- [1.21] Added ability to change click sound in GuiButtonObject; ([ce97be8df023022](https://github.com/dragon-forge/HammerLib/commit/ce97be8df023022)) by Zeith
Changelog:
- [1.21.4] Changes to data scanning. ([d7ebdf3dfbc0384](https://github.com/dragon-forge/HammerLib/commit/d7ebdf3dfbc0384)) by Zeith
- [1.21.4] Bring back CC Tweaked compat! ([98c1ce03cf79de2](https://github.com/dragon-forge/HammerLib/commit/98c1ce03cf79de2)) by Zeith
- [1.21.4] Languages are back up! ([27f5e06f042c131](https://github.com/dragon-forge/HammerLib/commit/27f5e06f042c131)) by Zeith
- [1.21.4] Cleanup unused glint shaders! ([b5eb83d47affb30](https://github.com/dragon-forge/HammerLib/commit/b5eb83d47affb30)) by Zeith
- [1.21.4] Fixed glint! ([3d19595124fdb9c](https://github.com/dragon-forge/HammerLib/commit/3d19595124fdb9c)) by Zeith
- [1.21.4] Fix shaders ([dcaaf62ff07e944](https://github.com/dragon-forge/HammerLib/commit/dcaaf62ff07e944)) by Zeith
- 1.21.4 ([c0c435cec8e5f36](https://github.com/dragon-forge/HammerLib/commit/c0c435cec8e5f36)) by Zeith
- 1.21.4 ([c3bc59f24191a75](https://github.com/dragon-forge/HammerLib/commit/c3bc59f24191a75)) by Zeith
- Fix javadoc typo. ([76c98bb9641d504](https://github.com/dragon-forge/HammerLib/commit/76c98bb9641d504)) by Zeith
- Update lombok and specify changelog generator version. ([60d9fc42a6cde0e](https://github.com/dragon-forge/HammerLib/commit/60d9fc42a6cde0e)) by Zeith
- [1.21] Update build.txt ([15f5bc4495c9252](https://github.com/dragon-forge/HammerLib/commit/15f5bc4495c9252)) by Zeith
- [1.21] Added ability to change click sound in GuiButtonObject; ([ce97be8df023022](https://github.com/dragon-forge/HammerLib/commit/ce97be8df023022)) by Zeith
Changelog:
- [1.21] Flowgui API ported to 1.21 ([196425b35cb0400](https://github.com/dragon-forge/HammerLib/commit/196425b35cb0400)) by Zeith
- [1.20.1] Rename parameter names. ([b30734a89ce777d](https://github.com/dragon-forge/HammerLib/commit/b30734a89ce777d)) by Zeith
- [1.20.1] Patch Flowgui API ([7fea3b5ddf6f4c4](https://github.com/dragon-forge/HammerLib/commit/7fea3b5ddf6f4c4)) by Zeith
- [1.21] Flowgui API, allowing component inheritance, complex slot transformations and ([846d7f25d5d5aba](https://github.com/dragon-forge/HammerLib/commit/846d7f25d5d5aba)) by Zeith
- Update deps ([68376d702682c77](https://github.com/dragon-forge/HammerLib/commit/68376d702682c77)) by Zeith
- Add DirectStorage.apply to transform the value using an unary operator. ([1cd7256a979bc11](https://github.com/dragon-forge/HammerLib/commit/1cd7256a979bc11)) by Zeith
- Update build info, ([2c40e114cb0eb07](https://github.com/dragon-forge/HammerLib/commit/2c40e114cb0eb07)) by Zeith
