diff options
author | Soopyboo32 <49228220+Soopyboo32@users.noreply.github.com> | 2021-11-15 17:17:57 +0800 |
---|---|---|
committer | Soopyboo32 <49228220+Soopyboo32@users.noreply.github.com> | 2021-11-15 17:17:57 +0800 |
commit | b0a76fb4e93be9356d947e1b29a08804de76b870 (patch) | |
tree | aa59502e4dc9616b589e903e936c28f5d98aecbf /features/slayers/index.js | |
parent | eadcb388106517adc994152cd4c35ed47c93a4f2 (diff) | |
download | SoopyV2-b0a76fb4e93be9356d947e1b29a08804de76b870.tar.gz SoopyV2-b0a76fb4e93be9356d947e1b29a08804de76b870.tar.bz2 SoopyV2-b0a76fb4e93be9356d947e1b29a08804de76b870.zip |
- Fix for lag in build battle
- dragon wings rbg support
- anti hub spam
- cosmetics live updating
- connection to socket
Diffstat (limited to 'features/slayers/index.js')
-rw-r--r-- | features/slayers/index.js | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/features/slayers/index.js b/features/slayers/index.js index 3599996..8d35304 100644 --- a/features/slayers/index.js +++ b/features/slayers/index.js @@ -69,9 +69,12 @@ class Slayers extends Feature { this.todoE2 = [] this.emanBoss = undefined this.nextIsBoss = 0 + this.counter = 0 + + this.entityAttackEventLoaded = false + this.entityAttackEventE = undefined this.registerForge(net.minecraftforge.event.entity.EntityJoinWorldEvent, this.entityJoinWorldEvent) - this.registerForge(net.minecraftforge.event.entity.living.LivingAttackEvent, this.entityAttackEvent) //TODO: Use CT event when ct 2.0 because they fixed this.registerEvent("tick", this.tick) this.registerEvent("renderWorld", this.renderWorld) this.registerEvent("worldLoad", this.worldLoad) @@ -111,6 +114,19 @@ class Slayers extends Feature { } renderWorld(ticks){ + + if(this.FeatureManager.features["dataLoader"].class.isInSkyblock){ + if(!this.entityAttackEventLoaded){ + this.entityAttackEventLoaded = true + this.entityAttackEventE = this.registerForge(net.minecraftforge.event.entity.living.LivingAttackEvent, this.entityAttackEvent) //TODO: Use CT event when ct 2.0 because they fixed + } + }else{ + if(this.entityAttackEventLoaded){ + this.entityAttackEventLoaded = false + this.unregisterForge(this.entityAttackEventE) + } + } + Object.values(this.beaconPoints).forEach(line=>{ let lastPoint = undefined line.forEach(p=>{ @@ -346,7 +362,9 @@ class Slayers extends Feature { this.eyeE = undefined this.nextIsBoss = undefined this.hudElements = [] + this.entityAttackEventLoaded = undefined this.todoE2 = undefined + this.entityAttackEventE = undefined } onDisable(){ |