Added option to disable kill aura on death

This commit is contained in:
willem 2020-05-15 16:27:57 +02:00
parent 4b8fb6dbba
commit d9264043c2
1 changed files with 5 additions and 1 deletions

View File

@ -38,6 +38,7 @@ class Aura : Module() {
private val prefer = register(Settings.e<HitMode>("Prefer", HitMode.SWORD))
private val autoTool = register(Settings.b("Auto Weapon", true))
private val sync = register(Settings.b("TPS Sync", false))
private val disableOnDeath = register(Settings.b("Disable On Death", false))
private var waitCounter = 0
enum class HitMode {
@ -49,7 +50,10 @@ class Aura : Module() {
}
override fun onUpdate() {
if (mc.player == null || mc.player.isDead) return
if (mc.player == null || mc.player.isDead) {
if (disableOnDeath.value) disable()
return
}
val autoWaitTick = 20.0f - LagCompensator.INSTANCE.tickRate
val canAttack = mc.player.getCooledAttackStrength(if (sync.value) -autoWaitTick else 0.0f) >= 1