Revert "Made the cleangui module toggle a non-shadowed string. (#341)" (#349)

This reverts commit 4c65ec4825.
This commit is contained in:
Bella Who 2019-12-30 14:05:12 -05:00 committed by GitHub
parent 4c65ec4825
commit 39b9524cd2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 11 deletions

View File

@ -1,7 +1,7 @@
package me.zeroeightsix.kami.mixin.client;
import me.zeroeightsix.kami.module.ModuleManager;
import me.zeroeightsix.kami.module.modules.bewwawho.gui.CleanGUI;
import net.minecraft.client.gui.FontRenderer;
import net.minecraft.client.gui.Gui;
import net.minecraft.client.gui.GuiNewChat;
import org.spongepowered.asm.mixin.Mixin;
@ -17,18 +17,10 @@ public abstract class MixinGuiNewChat {
@Redirect(method = "drawChat", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/gui/GuiNewChat;drawRect(IIIII)V"))
private void drawRectBackgroundClean(int left, int top, int right, int bottom, int color) {
if (!CleanGUI.enabled() || (CleanGUI.enabled() && !CleanGUI.chatGlobal.getValue())) {
if (!CleanGUI.enabled() || (CleanGUI.enabled() && !CleanGUI.chatGlobal.getValue())) { //TODO: changing this value doesn't work
// if (!ModuleManager.isModuleEnabled("CleanGUI")) {
Gui.drawRect(left, top, right, bottom, color);
}
}
@Redirect(method = "drawChat", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/gui/FontRenderer;drawStringWithShadow(Ljava/lang/String;FFI)I"))
private int drawStringWithShadowClean(FontRenderer fontRenderer, String text, float x, float y, int color) {
if (!CleanGUI.enabled() || (CleanGUI.enabled() && !CleanGUI.chatGlobal.getValue())) {
return fontRenderer.drawStringWithShadow(text, x, y, color);
}
return fontRenderer.drawString(text, (int) x, (int) y, color);
}
}