Added TooltipRenderer to mimic Item Tooltip Rendering for hover texts and replaced some error/info messages to use the TooltipRenderer
This commit is contained in:
@@ -1,8 +1,11 @@
|
||||
package eu.crushedpixel.replaymod.gui.elements;
|
||||
|
||||
import eu.crushedpixel.replaymod.ReplayMod;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.Gui;
|
||||
|
||||
import java.awt.*;
|
||||
|
||||
import static eu.crushedpixel.replaymod.gui.overlay.GuiReplayOverlay.TEXTURE_SIZE;
|
||||
import static eu.crushedpixel.replaymod.gui.overlay.GuiReplayOverlay.replay_gui;
|
||||
import static org.lwjgl.opengl.GL11.GL_BLEND;
|
||||
@@ -149,7 +152,7 @@ public class GuiTimeline extends Gui {
|
||||
if (mouseTime != -1) {
|
||||
long sec = mouseTime / 1000;
|
||||
String timestamp = String.format("%02d:%02ds", sec / 60, sec % 60);
|
||||
drawCenteredString(mc.fontRendererObj, timestamp, mouseX, mouseY + 5, 0xffffffff);
|
||||
ReplayMod.tooltipRenderer.drawTooltip(mouseX, mouseY, timestamp, null, Color.WHITE.getRGB());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user