diff --git a/lib/GMLIB_API-JS.js b/lib/GMLIB_API-JS.js index 3a2fe29..1b6df03 100644 --- a/lib/GMLIB_API-JS.js +++ b/lib/GMLIB_API-JS.js @@ -442,14 +442,6 @@ class Minecraft { static readNbtFromFile(path, isBinary = true) { return GMLIB_API.readNbtFromFile(path, isBinary); } - - static getBlockDestroySpeed(block) { - return GMLIB_API.getBlockDestroySpeed(block); - } - - static getDestroyBlockSpeed(item,block) { - return GMLIB_API.getDestroyBlockSpeed(item,block); - } } class Recipes { @@ -973,6 +965,14 @@ LLSE_Item.prototype.getTranslateName = function (language) { return I18nAPI.get(this.getTranslateKey(), [], language); } +LLSE_Block.prototype.getBlockDestroySpeed = function () { + return GMLIB_API.getBlockDestroySpeed(this); +} + +LLSE_Item.prototype.getDestroyBlockSpeed = function (block) { + return GMLIB_API.getDestroyBlockSpeed(this,block); +} + module.exports = { StaticFloatingText, DynamicFloatingText, diff --git a/src/CompatibilityApi.cpp b/src/CompatibilityApi.cpp index 8cd63dd..9ed1fe6 100644 --- a/src/CompatibilityApi.cpp +++ b/src/CompatibilityApi.cpp @@ -1,7 +1,4 @@ #include "Global.h" -#include "RemoteCallAPI.h" -#include "mc/world/actor/Actor.h" -#include "mc/world/item/registry/ItemStack.h" #include bool isInteger(const std::string& str) {