aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2/skyhanni/mixins/hooks/MixinPatcherFontRendererHookHook.kt
blob: 25d415889b0db3e9348ab7f9cfef06f956c20dee (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
package at.hannibal2.skyhanni.mixins.hooks

import at.hannibal2.skyhanni.features.chroma.ChromaManager
import at.hannibal2.skyhanni.utils.LorenzUtils
import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable

class MixinPatcherFontRendererHookHook {
    companion object {

        @JvmStatic
        fun overridePatcherFontRenderer(string: String, shadow: Boolean, cir: CallbackInfoReturnable<Boolean>) {
            if (!LorenzUtils.onHypixel) return

            if (ChromaManager.config.enabled.get()) {
                cir.cancel()
                cir.returnValue = false
            }
        }
    }
}