diff --git a/src/main/java/techreborn/TechReborn.java b/src/main/java/techreborn/TechReborn.java index 773daea8c..575a0809f 100644 --- a/src/main/java/techreborn/TechReborn.java +++ b/src/main/java/techreborn/TechReborn.java @@ -125,5 +125,5 @@ public class TechReborn implements ModInitializer { LOGGER.info("TechReborn setup done!"); } - + } diff --git a/src/main/java/techreborn/items/tool/ItemDebugTool.java b/src/main/java/techreborn/items/tool/ItemDebugTool.java index 473f97521..0af368439 100644 --- a/src/main/java/techreborn/items/tool/ItemDebugTool.java +++ b/src/main/java/techreborn/items/tool/ItemDebugTool.java @@ -36,7 +36,7 @@ import net.minecraft.state.property.Property; import net.minecraft.util.ActionResult; import net.minecraft.util.SystemUtil; - +import net.minecraft.util.registry.Registry; import reborncore.api.power.IEnergyInterfaceTile; import reborncore.common.powerSystem.PowerSystem; import techreborn.TechReborn; @@ -66,12 +66,6 @@ public class ItemDebugTool extends Item { sendMessage(context, new TextComponent(getTileEntityType(tile))); if (tile instanceof IEnergyInterfaceTile) { sendMessage(context, new TextComponent(getRCPower((IEnergyInterfaceTile) tile))); - } else { - IEnergyStorage capEnergy = tile - .getCapability(CapabilityEnergy.ENERGY, context.getPlayerHorizontalFacing()).orElseGet(null); - if (capEnergy != null) { - sendMessage(context, new TextComponent(getForgePower(capEnergy))); - } } } return ActionResult.SUCCESS; @@ -100,7 +94,7 @@ public class ItemDebugTool extends Item { String s = "" + ChatFormat.GREEN; s += "Block Registry Name: "; s += ChatFormat.BLUE; - s += block.getRegistryName().toString(); + s += Registry.BLOCK.getId(block); return s; } @@ -124,16 +118,4 @@ public class ItemDebugTool extends Item { return s; } - - private String getForgePower(IEnergyStorage cap) { - String s = "" + ChatFormat.GREEN; - s += "Power: "; - s += ChatFormat.RED; - s += cap.getEnergyStored(); - s += "/"; - s += cap.getMaxEnergyStored(); - s += " RF"; - - return s; - } }