From 088ffe23a502d8cd1753371a7ff1d6d2d255216b Mon Sep 17 00:00:00 2001 From: c0508383 Date: Wed, 20 Jul 2022 16:07:51 -0500 Subject: [PATCH] GuiQuestLog: -Fixed quest tracking not being able to be removed --- .../noppes/npcs/client/gui/player/GuiQuestLog.java | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/main/java/noppes/npcs/client/gui/player/GuiQuestLog.java b/src/main/java/noppes/npcs/client/gui/player/GuiQuestLog.java index 69b9a5846..4fce0cb4a 100644 --- a/src/main/java/noppes/npcs/client/gui/player/GuiQuestLog.java +++ b/src/main/java/noppes/npcs/client/gui/player/GuiQuestLog.java @@ -124,13 +124,13 @@ public class GuiQuestLog extends GuiNPCInterface implements ITopButtonListener,I super.drawScreen(i, j, f); if(noQuests){ - mc.fontRenderer.drawString(StatCollector.translateToLocal("quest.noquests"),guiLeft + 84,guiTop + 80, CustomNpcResourceListener.DefaultTextColor); + fontRendererObj.drawString(StatCollector.translateToLocal("quest.noquests"),guiLeft + 84,guiTop + 80, CustomNpcResourceListener.DefaultTextColor); return; } for(GuiMenuSideButton button: sideButtons.values().toArray(new GuiMenuSideButton[sideButtons.size()])){ button.drawButton(mc, i, j); } - mc.fontRenderer.drawString(data.selectedCategory,guiLeft + 5,guiTop + 5, CustomNpcResourceListener.DefaultTextColor); + fontRendererObj.drawString(data.selectedCategory,guiLeft + 5,guiTop + 5, CustomNpcResourceListener.DefaultTextColor); if(!data.hasSelectedQuest()) return; @@ -138,11 +138,11 @@ public class GuiQuestLog extends GuiNPCInterface implements ITopButtonListener,I if (questDetails) { drawProgress(); String title = StatCollector.translateToLocal("gui.text"); - mc.fontRenderer.drawString(title, guiLeft + 284 - mc.fontRenderer.getStringWidth(title), guiTop + 179, CustomNpcResourceListener.DefaultTextColor); + fontRendererObj.drawString(title, guiLeft + 284 - fontRendererObj.getStringWidth(title), guiTop + 179, CustomNpcResourceListener.DefaultTextColor); } else { drawQuestText(); String title = StatCollector.translateToLocal("quest.objectives"); - mc.fontRenderer.drawString(title, guiLeft + 168, guiTop + 179, CustomNpcResourceListener.DefaultTextColor); + fontRendererObj.drawString(title, guiLeft + 168, guiTop + 179, CustomNpcResourceListener.DefaultTextColor); } GL11.glPushMatrix(); @@ -165,7 +165,7 @@ public class GuiQuestLog extends GuiNPCInterface implements ITopButtonListener,I private void drawProgress() { String complete = data.getComplete(); if(complete != null && !complete.isEmpty()) - mc.fontRenderer.drawString(StatCollector.translateToLocalFormatted("quest.completewith", complete), guiLeft + 144, guiTop + 105, CustomNpcResourceListener.DefaultTextColor); + fontRendererObj.drawString(StatCollector.translateToLocalFormatted("quest.completewith", complete), guiLeft + 144, guiTop + 105, CustomNpcResourceListener.DefaultTextColor); int yoffset = guiTop + 22; for(String process : data.getQuestStatus()){ @@ -181,7 +181,7 @@ public class GuiQuestLog extends GuiNPCInterface implements ITopButtonListener,I } process = name + process.substring(index); } - mc.fontRenderer.drawString("- " + process, guiLeft + 144, yoffset , CustomNpcResourceListener.DefaultTextColor); + fontRendererObj.drawString("- " + process, guiLeft + 144, yoffset , CustomNpcResourceListener.DefaultTextColor); yoffset += 10; } } @@ -250,7 +250,7 @@ public class GuiQuestLog extends GuiNPCInterface implements ITopButtonListener,I @Override public void save() { - if (this.data != null && !this.data.trackedQuestKey.isEmpty()) + if (this.data != null) Client.sendData(EnumPacketServer.UpdateTrackedQuest, this.data.trackedQuestKey); }