aboutsummaryrefslogtreecommitdiff
path: root/src/main/kotlin/com/dulkirfabric/util
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/kotlin/com/dulkirfabric/util')
-rw-r--r--src/main/kotlin/com/dulkirfabric/util/GlowingEntityInterface.kt4
-rw-r--r--src/main/kotlin/com/dulkirfabric/util/HudRenderUtil.kt8
2 files changed, 4 insertions, 8 deletions
diff --git a/src/main/kotlin/com/dulkirfabric/util/GlowingEntityInterface.kt b/src/main/kotlin/com/dulkirfabric/util/GlowingEntityInterface.kt
index 9b129fd..e676736 100644
--- a/src/main/kotlin/com/dulkirfabric/util/GlowingEntityInterface.kt
+++ b/src/main/kotlin/com/dulkirfabric/util/GlowingEntityInterface.kt
@@ -3,11 +3,9 @@ package com.dulkirfabric.util
import java.awt.Color
interface GlowingEntityInterface {
- fun setDulkirEntityGlow(shouldGlow: Boolean = false, glowColor: Color, shouldESP: Boolean = false)
+ fun setDulkirEntityGlow(shouldGlow: Boolean = false, glowColor: Color)
fun shouldDulkirEntityGlow() : Boolean
fun getDulkirEntityGlowColor() : Color?
-
- fun shouldDulkirEntityESP() : Boolean
} \ No newline at end of file
diff --git a/src/main/kotlin/com/dulkirfabric/util/HudRenderUtil.kt b/src/main/kotlin/com/dulkirfabric/util/HudRenderUtil.kt
index 40840d9..02b79f7 100644
--- a/src/main/kotlin/com/dulkirfabric/util/HudRenderUtil.kt
+++ b/src/main/kotlin/com/dulkirfabric/util/HudRenderUtil.kt
@@ -1,8 +1,6 @@
package com.dulkirfabric.util
import com.dulkirfabric.DulkirModFabric.mc
-import net.fabricmc.fabric.api.client.rendering.v1.WorldRenderContext
-import net.minecraft.client.font.TextRenderer
import net.minecraft.client.gui.DrawContext
import net.minecraft.text.Text
@@ -11,11 +9,11 @@ object HudRenderUtil {
val matrices = context.matrices
val tr = mc.textRenderer
val w = tr.getWidth(content)
- val sf: Float = mc.window.scaledWidth / w.toFloat()
+ val sf: Float = mc.window.scaledWidth / w.toFloat() / 3
matrices.push()
- matrices.translate(mc.currentScreen!!.width / 3f, mc.window.scaledHeight / 2f,
- 0f)
+ matrices.translate(mc.window.scaledWidth / 3f, mc.window.scaledHeight / 2f, 0f)
matrices.scale(sf, sf, 1f)
context.drawText(tr, content, 0, -tr.fontHeight / 2, -1, true)
+ matrices.pop()
}
} \ No newline at end of file