RELEASE 1.0 (EARLY ALPHA)
- Item.createFoodItem method patch to specify lots of new params (all listed in declarations)
- ToolAPI module fully rewritten to native code and vanilla tool classes. You can still use ToolAPI to register tools, but in order not to make KEX use a little crutch many times, consider using ToolsModule.register[Sword/Axe/Pickaxe/Shovel/Hoe/CustomTool] or Item.create[([Sword/Axe/Pickaxe/Shovel/Hoe]Item)/CustomTool] (instead of normal Item.createItem).
- ToolAPI.ToolParams interface now has new method int getAttackDamageBonus(ItemInstance item), to override default damage to be applied to item depending on the stack contents (example of use: Nano Saber from IC2)
- ItemsModule with 8 new methods for items (will increase in future updates)
- LootModule to modify vanilla loot tables (dungeon chests, entities drops and fishing loot, NOT trading)
- Actor, Mob, Slime, MobEffect, MobEffectInstance API (experimental, not tested)
- Small fix in Item.createFoodItem patch
- Fixed all errors called by tools logics
- Restructured and refactored LootModule
- Added methods to the LootModifier class: addJSModifyCallback, addJSONModifyCallback, addJSPostModifyCallback, addJSONPostModifyCallback.
- The first pair is used to change the JSON object of the loot table directly after all programmatical modifications.
- The other pair is used to work with the JSON object of the loot table after all types of modifications. In these callbacks all the provided objects are copies and shouldn't be modified.
- Added method LootModule.addPiglinBarteringItem to add new items to the piglin bartering list. This method takes no parameters and returns LootEntry interface.
- Added function getKEXVersion(), returns array containing three integers of the current mod version (now it's [1, 2, 0]).
- AddonUtils class is now exported by the shared API.
- Added function getKEXVersionCode(), which can be used for more convenient version checks.
- Added callback \"KEX-InnerCoreIdsCached\", provides no parameters.
- Fixed LootModifier methods addJSModifyCallback, addJSPostModifyCallback crashing.
- Fixed food creation method patch
- Food parameters API.
- Food parameters object can be accessed by ItemsModule.getFood(id), returns null if given item is not a food.
- There is also ItemsModule.isFood(id) method, to check if the item is edible or not.
- Added method ItemsModule.newFoodSaturationModifier(name, value), to register custom string food saturation modifiers, that are specified in JSON components. Vanilla has only 6 pre-defined modifiers: poor, low, normal, good, max and supernatural.
- Added method ItemsModule.saturationModifierFromString(name), which returns the numeric saturation modifier value defined by the given name, or 0.6 if the saturation modifier with given name does not exist (0.6 is the value for normal modifier).
- Added method Actor.isElytraFlying().
- Fixed destroyBlockHook function in ToolsModule not taking BlockState as a block object. Now this function and other ones using the block objects are universal for both FullBlock and BlockState objects.
- Now ToolsModule.destroyBlockHook function is completely universal and can take any JS objects containing id and data fields, not only FullBlock instances.
- Small fix in food saturation logics.
- Added ESaturationModifier enum.
- Added Player, LocalPlayer, MoveInputHandler and LootTableContext native classes.
- Added GlobalContext module, currently has only one method, getLocalPlayer().
- Added callbacks module.
- First new callbacks are PlayerJump and GameModeChanged.
- Pre-defined EntityHurt callback is now also fired at magic damage.
- Added new methods to the Actor class:
- void removeEffects(boolean harmful, boolean harmless)
- boolean isOnGround()
- A bunch of methods connected with breathable component
- Added method LootModule.addOnDropCallbackFor to modify the list of items every time they are being chosen randomly, to be dropped from the mob or to be put into the chest. Function interface for the callback provides you with the list of items itself, and the LootTableContext object, to get additional data about the entity death / chest filling moment.
- Fixed some of ToolAPI method patches returning Java strings instead of JS ones, improved TypeScript declarations in terms of string types.
- Fixed Player.openSign method crashing, and reworked it, for it to create sign GUI screen with the text that had already been written on the sign before.
- Small fix in tool levels logics
- Some important fixes in tools logics
- Useful additions to the Callback module (by 80LK)
- Callback.on(name, handler, priority?) - analogue of Callback.addCallback
- Callback.once(name, handler, priority?) - same as on, but the event handler will be called only once
- Callback.off(name, handler) - removes the given event handler
- Added method ItemsModule.setMaxUseDurationDynamic
- Made InnerCore-defined EItemAnimation enum full, added DRINK, BLOCK, CAMERA, SPEAR, CROSSBOW
- Fixed conflict with very old versions of ToolLib library (tested with ToolLib V14 in Nocube's Wilderness mod)
- Fixed conflict with HarvestCraft mod
- Added new tool types to the ToolsModule - shears and flint-and-steel
- Adapted one internal feature to the future version of InnerCore pack
- Fixed custom tools crashing on last InnerCore Test pack update
- Fixed ToolAPI.getDestroyTimeViaTool method patch
- Some more ToolAPI backward compatibility fixes
- Fixed custom tools not breaking