aboutsummaryrefslogtreecommitdiff
path: root/src/main/java
diff options
context:
space:
mode:
authorWyvest <45589059+Wyvest@users.noreply.github.com>2022-01-03 11:12:54 +0700
committerWyvest <45589059+Wyvest@users.noreply.github.com>2022-01-03 11:12:54 +0700
commit487709996c22fb0dbcac792076be799a09865600 (patch)
tree5ab6f27a54d673fb057fd3eafd9a5e27816f898c /src/main/java
parentdf895d122a8a2ea249e686578e026c1d0a8b8c47 (diff)
downloadChatting-487709996c22fb0dbcac792076be799a09865600.tar.gz
Chatting-487709996c22fb0dbcac792076be799a09865600.tar.bz2
Chatting-487709996c22fb0dbcac792076be799a09865600.zip
Chattils -> Chatting (1.1.0)
Update images (ty Mo2men) update screenshot line tooltip (ty Mo2men)
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/cc/woverflow/chatting/hook/GuiNewChatHook.java (renamed from src/main/java/cc/woverflow/chattils/hook/GuiNewChatHook.java)4
-rw-r--r--src/main/java/cc/woverflow/chatting/mixin/ClientCommandHandlerMixin.java (renamed from src/main/java/cc/woverflow/chattils/mixin/ClientCommandHandlerMixin.java)9
-rw-r--r--src/main/java/cc/woverflow/chatting/mixin/EntityPlayerSPMixin.java (renamed from src/main/java/cc/woverflow/chattils/mixin/EntityPlayerSPMixin.java)8
-rw-r--r--src/main/java/cc/woverflow/chatting/mixin/GuiChatMixin.java (renamed from src/main/java/cc/woverflow/chattils/mixin/GuiChatMixin.java)48
-rw-r--r--src/main/java/cc/woverflow/chatting/mixin/GuiNewChatAccessor.java (renamed from src/main/java/cc/woverflow/chattils/mixin/GuiNewChatAccessor.java)2
-rw-r--r--src/main/java/cc/woverflow/chatting/mixin/GuiNewChatMapMixin.java (renamed from src/main/java/cc/woverflow/chattils/mixin/GuiNewChatMapMixin.java)4
-rw-r--r--src/main/java/cc/woverflow/chatting/mixin/GuiNewChatMixin.java (renamed from src/main/java/cc/woverflow/chattils/mixin/GuiNewChatMixin.java)78
-rw-r--r--src/main/java/cc/woverflow/chatting/mixin/GuiUtilsMixin.java (renamed from src/main/java/cc/woverflow/chattils/mixin/GuiUtilsMixin.java)6
-rw-r--r--src/main/java/cc/woverflow/chatting/mixin/WyvtilsListenerMixin.java (renamed from src/main/java/cc/woverflow/chattils/mixin/WyvtilsListenerMixin.java)4
9 files changed, 82 insertions, 81 deletions
diff --git a/src/main/java/cc/woverflow/chattils/hook/GuiNewChatHook.java b/src/main/java/cc/woverflow/chatting/hook/GuiNewChatHook.java
index f84fd43..51b19d4 100644
--- a/src/main/java/cc/woverflow/chattils/hook/GuiNewChatHook.java
+++ b/src/main/java/cc/woverflow/chatting/hook/GuiNewChatHook.java
@@ -1,4 +1,4 @@
-package cc.woverflow.chattils.hook;
+package cc.woverflow.chatting.hook;
import net.minecraft.client.gui.ChatLine;
@@ -9,7 +9,7 @@ public interface GuiNewChatHook {
boolean shouldCopy();
- Transferable getChattilsChatComponent(int mouseY);
+ Transferable getChattingChatComponent(int mouseY);
default ChatLine getFullMessage(ChatLine line) {
throw new AssertionError("getFullMessage not overridden on GuiNewChat");
diff --git a/src/main/java/cc/woverflow/chattils/mixin/ClientCommandHandlerMixin.java b/src/main/java/cc/woverflow/chatting/mixin/ClientCommandHandlerMixin.java
index 0692342..f771c87 100644
--- a/src/main/java/cc/woverflow/chattils/mixin/ClientCommandHandlerMixin.java
+++ b/src/main/java/cc/woverflow/chatting/mixin/ClientCommandHandlerMixin.java
@@ -1,7 +1,7 @@
-package cc.woverflow.chattils.mixin;
+package cc.woverflow.chatting.mixin;
-import cc.woverflow.chattils.chat.ChatShortcuts;
-import cc.woverflow.chattils.config.ChattilsConfig;
+import cc.woverflow.chatting.chat.ChatShortcuts;
+import cc.woverflow.chatting.config.ChattingConfig;
import kotlin.Pair;
import net.minecraft.client.Minecraft;
import net.minecraft.command.CommandHandler;
@@ -13,7 +13,6 @@ import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.injection.At;
import org.spongepowered.asm.mixin.injection.Redirect;
-import java.util.Iterator;
import java.util.List;
@Mixin(value = ClientCommandHandler.class, remap = false)
@@ -22,7 +21,7 @@ public class ClientCommandHandlerMixin extends CommandHandler {
private List<String> addChatShortcuts(ClientCommandHandler instance, ICommandSender iCommandSender, String leftOfCursor, BlockPos blockPos) {
Minecraft mc = FMLClientHandler.instance().getClient();
List<String> autocompleteList = instance.getTabCompletionOptions(mc.thePlayer, leftOfCursor, mc.thePlayer.getPosition());
- if (ChattilsConfig.INSTANCE.getChatShortcuts()) {
+ if (ChattingConfig.INSTANCE.getChatShortcuts()) {
for (Pair<String, String> pair : ChatShortcuts.INSTANCE.getShortcuts()) {
if (pair.getFirst().startsWith(leftOfCursor)) {
autocompleteList.add(pair.getFirst());
diff --git a/src/main/java/cc/woverflow/chattils/mixin/EntityPlayerSPMixin.java b/src/main/java/cc/woverflow/chatting/mixin/EntityPlayerSPMixin.java
index 48dfc10..42c5579 100644
--- a/src/main/java/cc/woverflow/chattils/mixin/EntityPlayerSPMixin.java
+++ b/src/main/java/cc/woverflow/chatting/mixin/EntityPlayerSPMixin.java
@@ -1,7 +1,7 @@
-package cc.woverflow.chattils.mixin;
+package cc.woverflow.chatting.mixin;
-import cc.woverflow.chattils.chat.ChatTabs;
-import cc.woverflow.chattils.config.ChattilsConfig;
+import cc.woverflow.chatting.chat.ChatTabs;
+import cc.woverflow.chatting.config.ChattingConfig;
import net.minecraft.client.entity.EntityPlayerSP;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.injection.At;
@@ -12,7 +12,7 @@ public class EntityPlayerSPMixin {
@ModifyVariable(method = "sendChatMessage", at = @At("HEAD"), ordinal = 0, argsOnly = true)
private String handleSentMessages(String value) {
if (value.startsWith("/")) return value;
- if (ChattilsConfig.INSTANCE.getChatTabs() && ChatTabs.INSTANCE.getCurrentTab() != null && !ChatTabs.INSTANCE.getCurrentTab().getPrefix().isEmpty()) {
+ if (ChattingConfig.INSTANCE.getChatTabs() && ChatTabs.INSTANCE.getCurrentTab() != null && !ChatTabs.INSTANCE.getCurrentTab().getPrefix().isEmpty()) {
return ChatTabs.INSTANCE.getCurrentTab().getPrefix() + value;
} else {
return value;
diff --git a/src/main/java/cc/woverflow/chattils/mixin/GuiChatMixin.java b/src/main/java/cc/woverflow/chatting/mixin/GuiChatMixin.java
index 9af0204..73b76e7 100644
--- a/src/main/java/cc/woverflow/chattils/mixin/GuiChatMixin.java
+++ b/src/main/java/cc/woverflow/chatting/mixin/GuiChatMixin.java
@@ -1,14 +1,14 @@
-package cc.woverflow.chattils.mixin;
+package cc.woverflow.chatting.mixin;
-import cc.woverflow.chattils.chat.ChatSearchingManager;
-import cc.woverflow.chattils.chat.ChatShortcuts;
-import cc.woverflow.chattils.chat.ChatTab;
-import cc.woverflow.chattils.chat.ChatTabs;
-import cc.woverflow.chattils.config.ChattilsConfig;
-import cc.woverflow.chattils.gui.components.ScreenshotButton;
-import cc.woverflow.chattils.gui.components.SearchButton;
-import cc.woverflow.chattils.hook.GuiNewChatHook;
-import cc.woverflow.chattils.utils.ModCompatHooks;
+import cc.woverflow.chatting.chat.ChatSearchingManager;
+import cc.woverflow.chatting.chat.ChatShortcuts;
+import cc.woverflow.chatting.chat.ChatTab;
+import cc.woverflow.chatting.chat.ChatTabs;
+import cc.woverflow.chatting.config.ChattingConfig;
+import cc.woverflow.chatting.gui.components.ScreenshotButton;
+import cc.woverflow.chatting.gui.components.SearchButton;
+import cc.woverflow.chatting.hook.GuiNewChatHook;
+import cc.woverflow.chatting.utils.ModCompatHooks;
import com.google.common.collect.Lists;
import net.minecraft.client.Minecraft;
import net.minecraft.client.gui.GuiChat;
@@ -34,24 +34,24 @@ public abstract class GuiChatMixin extends GuiScreen {
@Unique
private static final List<String> COPY_TOOLTIP = Lists.newArrayList(
- "\u00A73\u00A7l\u00A7nCopy To Clipboard",
- "\u00A7lNORMAL CLICK\u00A7r - Full Message",
- "\u00A7lCTRL CLICK\u00A7r - Single Line",
- "\u00A7lSHIFT CLICK\u00A7r - Screenshot Line",
+ "\u00A7e\u00A7lCopy To Clipboard",
+ "\u00A7b\u00A7lNORMAL CLICK\u00A7r \u00A78- \u00A77Full Message",
+ "\u00A7b\u00A7lCTRL CLICK\u00A7r \u00A78- \u00A77Single Line",
+ "\u00A7b\u00A7lSHIFT CLICK\u00A7r \u00A78- \u00A77Screenshot Line",
"",
- "\u00A73\u00A7l\u00A7nModifiers",
- "\u00A7lALT\u00A7r - Formatting Codes");
+ "\u00A7e\u00A7lModifiers",
+ "\u00A7b\u00A7lALT\u00A7r \u00A78- \u00A77Formatting Codes");
private SearchButton searchButton;
@Inject(method = "initGui", at = @At("TAIL"))
private void init(CallbackInfo ci) {
- if (ChattilsConfig.INSTANCE.getChatSearch()) {
+ if (ChattingConfig.INSTANCE.getChatSearch()) {
searchButton = new SearchButton();
buttonList.add(searchButton);
}
buttonList.add(new ScreenshotButton());
- if (ChattilsConfig.INSTANCE.getChatTabs()) {
+ if (ChattingConfig.INSTANCE.getChatTabs()) {
for (ChatTab chatTab : ChatTabs.INSTANCE.getTabs()) {
buttonList.add(chatTab.getButton());
}
@@ -60,14 +60,14 @@ public abstract class GuiChatMixin extends GuiScreen {
@Inject(method = "updateScreen", at = @At("HEAD"))
private void updateScreen(CallbackInfo ci) {
- if (ChattilsConfig.INSTANCE.getChatSearch() && searchButton.isEnabled()) {
+ if (ChattingConfig.INSTANCE.getChatSearch() && searchButton.isEnabled()) {
searchButton.getInputField().updateCursorCounter();
}
}
@Inject(method = "keyTyped", at = @At("HEAD"), cancellable = true)
private void keyTyped(char typedChar, int keyCode, CallbackInfo ci) {
- if (ChattilsConfig.INSTANCE.getChatSearch() && searchButton.isEnabled()) {
+ if (ChattingConfig.INSTANCE.getChatSearch() && searchButton.isEnabled()) {
ci.cancel();
if (keyCode == 1) {
searchButton.onMousePress();
@@ -83,7 +83,7 @@ public abstract class GuiChatMixin extends GuiScreen {
GuiNewChatHook hook = ((GuiNewChatHook) Minecraft.getMinecraft().ingameGUI.getChatGUI());
float f = mc.ingameGUI.getChatGUI().getChatScale();
int x = MathHelper.floor_float((float) mouseX / f);
- if (hook.shouldCopy() && (hook.getRight() + ModCompatHooks.getXOffset()) <= x && (hook.getRight() + ModCompatHooks.getXOffset()) + 9 > x) {
+ if (hook.shouldCopy() && (hook.getRight() + ModCompatHooks.getXOffset()) <= x && (hook.getRight() + ModCompatHooks.getXOffset()) + 11 > x) {
GuiUtils.drawHoveringText(COPY_TOOLTIP, mouseX, mouseY, width, height, -1, fontRendererObj);
GlStateManager.disableLighting();
}
@@ -94,8 +94,8 @@ public abstract class GuiChatMixin extends GuiScreen {
GuiNewChatHook hook = ((GuiNewChatHook) Minecraft.getMinecraft().ingameGUI.getChatGUI());
float f = mc.ingameGUI.getChatGUI().getChatScale();
int x = MathHelper.floor_float((float) mouseX / f);
- if (hook.shouldCopy() && (hook.getRight() + ModCompatHooks.getXOffset()) <= x && (hook.getRight() + ModCompatHooks.getXOffset()) + 9 > x) {
- Transferable message = hook.getChattilsChatComponent(Mouse.getY());
+ if (hook.shouldCopy() && (hook.getRight() + ModCompatHooks.getXOffset()) <= x && (hook.getRight() + ModCompatHooks.getXOffset()) + 11 > x) {
+ Transferable message = hook.getChattingChatComponent(Mouse.getY());
if (message == null) return;
try {
Toolkit.getDefaultToolkit().getSystemClipboard().setContents(message, null);
@@ -107,7 +107,7 @@ public abstract class GuiChatMixin extends GuiScreen {
@ModifyArg(method = "keyTyped", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/gui/GuiChat;sendChatMessage(Ljava/lang/String;)V"), index = 0)
private String modifySentMessage(String original) {
- if (ChattilsConfig.INSTANCE.getChatShortcuts()) {
+ if (ChattingConfig.INSTANCE.getChatShortcuts()) {
if (original.startsWith("/")) {
return "/" + ChatShortcuts.INSTANCE.handleSentCommand(StringUtils.substringAfter(original, "/"));
}
diff --git a/src/main/java/cc/woverflow/chattils/mixin/GuiNewChatAccessor.java b/src/main/java/cc/woverflow/chatting/mixin/GuiNewChatAccessor.java
index 1bce77a..8b81a50 100644
--- a/src/main/java/cc/woverflow/chattils/mixin/GuiNewChatAccessor.java
+++ b/src/main/java/cc/woverflow/chatting/mixin/GuiNewChatAccessor.java
@@ -1,4 +1,4 @@
-package cc.woverflow.chattils.mixin;
+package cc.woverflow.chatting.mixin;
import net.minecraft.client.gui.ChatLine;
import net.minecraft.client.gui.GuiNewChat;
diff --git a/src/main/java/cc/woverflow/chattils/mixin/GuiNewChatMapMixin.java b/src/main/java/cc/woverflow/chatting/mixin/GuiNewChatMapMixin.java
index 97d39c5..5b38bda 100644
--- a/src/main/java/cc/woverflow/chattils/mixin/GuiNewChatMapMixin.java
+++ b/src/main/java/cc/woverflow/chatting/mixin/GuiNewChatMapMixin.java
@@ -1,6 +1,6 @@
-package cc.woverflow.chattils.mixin;
+package cc.woverflow.chatting.mixin;
-import cc.woverflow.chattils.hook.GuiNewChatHook;
+import cc.woverflow.chatting.hook.GuiNewChatHook;
import net.minecraft.client.gui.ChatLine;
import net.minecraft.client.gui.GuiNewChat;
import net.minecraft.util.IChatComponent;
diff --git a/src/main/java/cc/woverflow/chattils/mixin/GuiNewChatMixin.java b/src/main/java/cc/woverflow/chatting/mixin/GuiNewChatMixin.java
index eea68c8..4edafb2 100644
--- a/src/main/java/cc/woverflow/chattils/mixin/GuiNewChatMixin.java
+++ b/src/main/java/cc/woverflow/chatting/mixin/GuiNewChatMixin.java
@@ -1,12 +1,13 @@
-package cc.woverflow.chattils.mixin;
-
-import cc.woverflow.chattils.Chattils;
-import cc.woverflow.chattils.chat.ChatSearchingManager;
-import cc.woverflow.chattils.chat.ChatTabs;
-import cc.woverflow.chattils.config.ChattilsConfig;
-import cc.woverflow.chattils.hook.GuiNewChatHook;
-import cc.woverflow.chattils.utils.ModCompatHooks;
-import cc.woverflow.chattils.utils.RenderHelper;
+package cc.woverflow.chatting.mixin;
+
+import cc.woverflow.chatting.Chatting;
+import cc.woverflow.chatting.chat.ChatSearchingManager;
+import cc.woverflow.chatting.chat.ChatTabs;
+import cc.woverflow.chatting.config.ChattingConfig;
+import cc.woverflow.chatting.gui.components.CleanButton;
+import cc.woverflow.chatting.hook.GuiNewChatHook;
+import cc.woverflow.chatting.utils.ModCompatHooks;
+import cc.woverflow.chatting.utils.RenderHelper;
import gg.essential.universal.UMouse;
import net.minecraft.client.Minecraft;
import net.minecraft.client.gui.*;
@@ -33,15 +34,15 @@ import java.util.Locale;
@Mixin(value = GuiNewChat.class, priority = Integer.MIN_VALUE)
public abstract class GuiNewChatMixin extends Gui implements GuiNewChatHook {
- @Unique private int chattils$right = 0;
- @Unique private boolean chattils$shouldCopy;
- @Unique private boolean chattils$chatCheck;
- @Unique private int chattils$textOpacity;
+ @Unique private int chatting$right = 0;
+ @Unique private boolean chatting$shouldCopy;
+ @Unique private boolean chatting$chatCheck;
+ @Unique private int chatting$textOpacity;
@Shadow @Final private Minecraft mc;
@Shadow @Final private List<ChatLine> drawnChatLines;
@SuppressWarnings({"FieldCanBeLocal", "unused"})
private float percentComplete;
- private String chattils$previousText = "";
+ private String chatting$previousText = "";
@Shadow public abstract boolean getChatOpen();
@@ -54,12 +55,12 @@ public abstract class GuiNewChatMixin extends Gui implements GuiNewChatHook {
@Shadow public abstract void deleteChatLine(int id);
- @Unique private static final ResourceLocation COPY = new ResourceLocation("chattils:copy.png");
+ @Unique private static final ResourceLocation COPY = new ResourceLocation("chatting:copy.png");
@Inject(method = "printChatMessageWithOptionalDeletion", at = @At("HEAD"), cancellable = true)
private void handlePrintChatMessage(IChatComponent chatComponent, int chatLineId, CallbackInfo ci) {
handleChatTabMessage(chatComponent, chatLineId, mc.ingameGUI.getUpdateCounter(), false, ci);
- if (!EnumChatFormatting.getTextWithoutFormattingCodes(chatComponent.getUnformattedText()).toLowerCase(Locale.ENGLISH).contains(chattils$previousText.toLowerCase(Locale.ENGLISH))) {
+ if (!EnumChatFormatting.getTextWithoutFormattingCodes(chatComponent.getUnformattedText()).toLowerCase(Locale.ENGLISH).contains(chatting$previousText.toLowerCase(Locale.ENGLISH))) {
percentComplete = 1.0F;
}
}
@@ -72,20 +73,20 @@ public abstract class GuiNewChatMixin extends Gui implements GuiNewChatHook {
@Inject(method = "drawChat", at = @At("HEAD"))
private void checkScreenshotKeybind(int j2, CallbackInfo ci) {
- if (Chattils.INSTANCE.getKeybind().isPressed()) {
- Chattils.INSTANCE.setDoTheThing(true);
+ if (Chatting.INSTANCE.getKeybind().isPressed()) {
+ Chatting.INSTANCE.setDoTheThing(true);
}
- chattils$chatCheck = false;
+ chatting$chatCheck = false;
}
@ModifyVariable(method = "drawChat", at = @At("HEAD"), argsOnly = true)
private int setUpdateCounterWhjenYes(int updateCounter) {
- return Chattils.INSTANCE.getDoTheThing() ? 0 : updateCounter;
+ return Chatting.INSTANCE.getDoTheThing() ? 0 : updateCounter;
}
@ModifyVariable(method = "drawChat", at = @At("STORE"), index = 2)
private int setChatLimitWhenYes(int linesToDraw) {
- return Chattils.INSTANCE.getDoTheThing()
+ return Chatting.INSTANCE.getDoTheThing()
? GuiNewChat.calculateChatboxHeight(mc.gameSettings.chatHeightFocused) / 9
: linesToDraw;
}
@@ -102,8 +103,8 @@ public abstract class GuiNewChatMixin extends Gui implements GuiNewChatHook {
int mouseY = MathHelper.floor_double(UMouse.getScaledY()) - 27 + ModCompatHooks.getYOffset() - ModCompatHooks.getChatPosition();
mouseX = MathHelper.floor_float((float)mouseX / f);
mouseY = -(MathHelper.floor_float((float)mouseY / f)); //WHY DO I NEED TO DO THIS
- if (mouseX >= (left + ModCompatHooks.getXOffset()) && mouseY < bottom && mouseX < (right + 9 + ModCompatHooks.getXOffset()) && mouseY >= top) {
- chattils$shouldCopy = true;
+ if (mouseX >= (left + ModCompatHooks.getXOffset()) && mouseY < bottom && mouseX < (right + 11 + ModCompatHooks.getXOffset()) && mouseY >= top) {
+ chatting$shouldCopy = true;
drawCopyChatBox(right, top);
}
}
@@ -111,12 +112,12 @@ public abstract class GuiNewChatMixin extends Gui implements GuiNewChatHook {
@Redirect(method = "drawChat", at = @At(value = "FIELD", target = "Lnet/minecraft/client/gui/GuiNewChat;drawnChatLines:Ljava/util/List;", opcode = Opcodes.GETFIELD))
private List<ChatLine> injected(GuiNewChat instance) {
- return ChatSearchingManager.filterMessages(chattils$previousText, drawnChatLines);
+ return ChatSearchingManager.filterMessages(chatting$previousText, drawnChatLines);
}
@ModifyVariable(method = "drawChat", at = @At("STORE"), ordinal = 7)
private int modifyYeah(int value) {
- return chattils$textOpacity = (int) (((float) (getChatOpen() ? 255 : value)) * (mc.gameSettings.chatOpacity * 0.9F + 0.1F));
+ return chatting$textOpacity = (int) (((float) (getChatOpen() ? 255 : value)) * (mc.gameSettings.chatOpacity * 0.9F + 0.1F));
}
@Redirect(method = "drawChat", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/gui/FontRenderer;drawStringWithShadow(Ljava/lang/String;FFI)I"))
@@ -126,28 +127,28 @@ public abstract class GuiNewChatMixin extends Gui implements GuiNewChatHook {
@Inject(method = "drawChat", at = @At("RETURN"))
private void checkStuff(int j2, CallbackInfo ci) {
- if (!chattils$chatCheck && chattils$shouldCopy) {
- chattils$shouldCopy = false;
+ if (!chatting$chatCheck && chatting$shouldCopy) {
+ chatting$shouldCopy = false;
}
}
@Inject(method = "getChatHeight", at = @At("HEAD"), cancellable = true)
private void customHeight_getChatHeight(CallbackInfoReturnable<Integer> cir) {
- if (ChattilsConfig.INSTANCE.getCustomChatHeight()) cir.setReturnValue(Chattils.INSTANCE.getChatHeight(this.getChatOpen()));
+ if (ChattingConfig.INSTANCE.getCustomChatHeight()) cir.setReturnValue(Chatting.INSTANCE.getChatHeight(this.getChatOpen()));
}
@Override
public int getRight() {
- return chattils$right;
+ return chatting$right;
}
@Override
public boolean shouldCopy() {
- return chattils$shouldCopy;
+ return chatting$shouldCopy;
}
private void handleChatTabMessage(IChatComponent chatComponent, int chatLineId, int updateCounter, boolean displayOnly, CallbackInfo ci) {
- if (ChattilsConfig.INSTANCE.getChatTabs()) {
+ if (ChattingConfig.INSTANCE.getChatTabs()) {
if (!ChatTabs.INSTANCE.shouldRender(chatComponent)) {
percentComplete = 1.0F;
if (chatLineId != 0) {
@@ -166,7 +167,7 @@ public abstract class GuiNewChatMixin extends Gui implements GuiNewChatHook {
}
private void drawCopyChatBox(int right, int top) {
- chattils$chatCheck = true;
+ chatting$chatCheck = true;
GlStateManager.enableRescaleNormal();
GlStateManager.enableBlend();
GlStateManager.enableDepth();
@@ -179,8 +180,9 @@ public abstract class GuiNewChatMixin extends Gui implements GuiNewChatHook {
GlStateManager.enableBlend();
GlStateManager.blendFunc(770, 771);
GlStateManager.color(1.0f, 1.0f, 1.0f, 1.0f);
- chattils$right = right;
+ chatting$right = right;
Gui.drawModalRectWithCustomSizedTexture(right, top, 0f, 0f, 9, 9, 9, 9);
+ drawRect(right - 1, top - 1, right + 10, top + 10, (((right + ModCompatHooks.getXOffset()) <= (UMouse.getScaledX() / mc.ingameGUI.getChatGUI().getChatScale()) && (right + ModCompatHooks.getXOffset()) + 11 > (UMouse.getScaledX() / mc.ingameGUI.getChatGUI().getChatScale())) ? CleanButton.Companion.getHoveredColor() : CleanButton.Companion.getColor()));
GlStateManager.disableAlpha();
GlStateManager.disableRescaleNormal();
GlStateManager.disableLighting();
@@ -188,7 +190,7 @@ public abstract class GuiNewChatMixin extends Gui implements GuiNewChatHook {
}
@Override
- public Transferable getChattilsChatComponent(int mouseY) {
+ public Transferable getChattingChatComponent(int mouseY) {
if (this.getChatOpen()) {
ScaledResolution scaledresolution = new ScaledResolution(this.mc);
int i = scaledresolution.getScaleFactor();
@@ -207,7 +209,7 @@ public abstract class GuiNewChatMixin extends Gui implements GuiNewChatHook {
ChatLine fullLine = this.getFullMessage(subLine);
if (GuiScreen.isShiftKeyDown()) {
if (fullLine != null) {
- BufferedImage image = Chattils.INSTANCE.screenshotLine(fullLine);
+ BufferedImage image = Chatting.INSTANCE.screenshotLine(fullLine);
if (image != null) RenderHelper.INSTANCE.copyBufferedImageToClipboard(image);
}
return null;
@@ -225,16 +227,16 @@ public abstract class GuiNewChatMixin extends Gui implements GuiNewChatHook {
@Override
public String getPrevText() {
- return chattils$previousText;
+ return chatting$previousText;
}
@Override
public void setPrevText(String prevText) {
- chattils$previousText = prevText;
+ chatting$previousText = prevText;
}
@Override
public int getTextOpacity() {
- return chattils$textOpacity;
+ return chatting$textOpacity;
}
}
diff --git a/src/main/java/cc/woverflow/chattils/mixin/GuiUtilsMixin.java b/src/main/java/cc/woverflow/chatting/mixin/GuiUtilsMixin.java
index df8216b..6489f67 100644
--- a/src/main/java/cc/woverflow/chattils/mixin/GuiUtilsMixin.java
+++ b/src/main/java/cc/woverflow/chatting/mixin/GuiUtilsMixin.java
@@ -1,6 +1,6 @@
-package cc.woverflow.chattils.mixin;
+package cc.woverflow.chatting.mixin;
-import cc.woverflow.chattils.config.ChattilsConfig;
+import cc.woverflow.chatting.config.ChattingConfig;
import net.minecraftforge.fml.client.config.GuiUtils;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.Shadow;
@@ -15,7 +15,7 @@ public class GuiUtilsMixin {
@Redirect(method = "drawHoveringText", at = @At(value = "INVOKE", target = "Lnet/minecraftforge/fml/client/config/GuiUtils;drawGradientRect(IIIIIII)V"))
private static void redirectBackground(int zLevel, int left, int top, int right, int bottom, int startColor, int endColor) {
- if (!ChattilsConfig.INSTANCE.getRemoveTooltipBackground()) {
+ if (!ChattingConfig.INSTANCE.getRemoveTooltipBackground()) {
drawGradientRect(zLevel, left, top, right, bottom, startColor, endColor);
}
}
diff --git a/src/main/java/cc/woverflow/chattils/mixin/WyvtilsListenerMixin.java b/src/main/java/cc/woverflow/chatting/mixin/WyvtilsListenerMixin.java
index 13a4167..7b22479 100644
--- a/src/main/java/cc/woverflow/chattils/mixin/WyvtilsListenerMixin.java
+++ b/src/main/java/cc/woverflow/chatting/mixin/WyvtilsListenerMixin.java
@@ -1,6 +1,6 @@
-package cc.woverflow.chattils.mixin;
+package cc.woverflow.chatting.mixin;
-import cc.woverflow.chattils.utils.RenderHelper;
+import cc.woverflow.chatting.utils.RenderHelper;
import org.spongepowered.asm.mixin.Dynamic;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.Pseudo;