mirror of https://github.com/kami-blue/client
move truedurability to thing
This commit is contained in:
parent
9105fa0c3d
commit
8209736982
|
@ -214,7 +214,9 @@ public class KamiGUI extends GUI {
|
|||
boolean privateInfoTps = (((InfoOverlay) ModuleManager.getModuleByName("InfoOverlay")).globalInfoTps.getValue());
|
||||
boolean privateInfoFps = (((InfoOverlay) ModuleManager.getModuleByName("InfoOverlay")).globalInfoFps.getValue());
|
||||
boolean privateInfoPin = (((InfoOverlay) ModuleManager.getModuleByName("InfoOverlay")).globalInfoPin.getValue());
|
||||
boolean privateInfoDur = (((InfoOverlay) ModuleManager.getModuleByName("InfoOverlay")).globalInfoDur.getValue());
|
||||
boolean privateInfoMem = (((InfoOverlay) ModuleManager.getModuleByName("InfoOverlay")).globalInfoMem.getValue());
|
||||
|
||||
int privatePingValue = CalcPing.globalInfoPingValue();
|
||||
String privateDisplayN = Wrapper.getMinecraft().player.getName();
|
||||
|
||||
|
@ -234,13 +236,17 @@ public class KamiGUI extends GUI {
|
|||
if (privateInfoPin) {
|
||||
information.addLine("\u00A7b" + privatePingValue + Command.SECTION_SIGN + "3 ms");
|
||||
}
|
||||
if (privateInfoDur) {
|
||||
ItemStack itemStack = Wrapper.getMinecraft().player.getHeldItemMainhand();
|
||||
int itemDurability = itemStack.getMaxDamage() - itemStack.getItemDamage();
|
||||
information.addLine("\u00A7b" + Integer.toString(itemDurability) + "\u00A73 dura");
|
||||
}
|
||||
if (privateInfoMem) {
|
||||
information.addLine("\u00A7b" + (Runtime.getRuntime().freeMemory() / 1000000) + Command.SECTION_SIGN + "3mB free");
|
||||
}
|
||||
} else {
|
||||
information.setText("");
|
||||
information.addLine("\u00A7b" + KamiMod.KAMI_KANJI + "\u00A73 " + KamiMod.MODVER);
|
||||
information.addLine(Command.SECTION_SIGN + "EEnable InfoOverlay!");
|
||||
}
|
||||
|
||||
|
||||
|
@ -258,20 +264,6 @@ public class KamiGUI extends GUI {
|
|||
information.setFontRenderer(fontRenderer);
|
||||
frames.add(frame);
|
||||
|
||||
frame = new Frame(getTheme(), new Stretcherlayout(1), "True Durability");
|
||||
frame.setCloseable(false);
|
||||
frame.setPinneable(true);
|
||||
Label durability = new Label("");
|
||||
durability.setShadow(true);
|
||||
durability.addTickListener(() -> {
|
||||
ItemStack itemStack = Wrapper.getMinecraft().player.getHeldItemMainhand();
|
||||
int itemDurability = itemStack.getMaxDamage() - itemStack.getItemDamage();
|
||||
durability.setText(String.valueOf(itemDurability));
|
||||
});
|
||||
frame.addChild(durability);
|
||||
durability.setFontRenderer(fontRenderer);
|
||||
frames.add(frame);
|
||||
|
||||
frame = new Frame(getTheme(), new Stretcherlayout(1), "Friends");
|
||||
frame.setCloseable(false);
|
||||
frame.setPinneable(true);
|
||||
|
|
|
@ -16,7 +16,8 @@ public class InfoOverlay extends Module {
|
|||
public Setting<Boolean> globalInfoTps = register(Settings.b("TPS", true));
|
||||
public Setting<Boolean> globalInfoFps = register(Settings.b("FPS", true));
|
||||
public Setting<Boolean> globalInfoPin = register(Settings.b("Ping", true));
|
||||
public Setting<Boolean> globalInfoMem = register(Settings.b("Memory", true));
|
||||
public Setting<Boolean> globalInfoDur = register(Settings.b("Durability", true));
|
||||
public Setting<Boolean> globalInfoMem = register(Settings.b("Memory", false));
|
||||
|
||||
public void onDisable() {
|
||||
this.enable();
|
||||
|
|
Loading…
Reference in New Issue