Add a riskyCheats boolean

This commit is contained in:
Username404 2021-05-29 13:01:39 +02:00
parent f7215b4202
commit 14b3d63b57
Signed by: Username404-59
GPG Key ID: 7AB361FBB257A5D1
2 changed files with 6 additions and 0 deletions

View File

@ -46,6 +46,8 @@ sealed class ButtonImpl: ColoredElement(0.0, 0.0, 73, 8, opacity = 0.60F) {
} catch (e: NoSuchMethodException) {
it.getDeclaredField("INSTANCE").get(null)
}) as ButtonImpl)
}.filterNot {
(it.info.parent == Category.RISKY) && !riskyCheats
}.plus(Configuration.macros)
)
}

View File

@ -1,6 +1,10 @@
package fr.username404.snowygui.gui.feature
import fr.username404.snowygui.config.Configuration
import net.minecraft.client.Minecraft
import io.github.config4k.getValue
val riskyCheats: Boolean by Configuration.obtained
@ButtonInfo(Category.RISKY)
object NoHurtCamera: ButtonImpl()