aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2/skyhanni/features/misc
diff options
context:
space:
mode:
authorhannibal2 <24389977+hannibal00212@users.noreply.github.com>2023-02-26 16:27:19 +0100
committerhannibal2 <24389977+hannibal00212@users.noreply.github.com>2023-02-26 16:27:19 +0100
commit9639b0927aabbc7f23e62a603e1ffee8832235f8 (patch)
treec6f0880b2ad8d29c1ab3547862c39d1cbcf86a0f /src/main/java/at/hannibal2/skyhanni/features/misc
parentfeef78a4b554a3142167db10d7e23bf95e3676bc (diff)
downloadskyhanni-9639b0927aabbc7f23e62a603e1ffee8832235f8.tar.gz
skyhanni-9639b0927aabbc7f23e62a603e1ffee8832235f8.tar.bz2
skyhanni-9639b0927aabbc7f23e62a603e1ffee8832235f8.zip
Removed hide dead entities bc its already in skytils and working.
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/features/misc')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/misc/HideDeadEntities.kt74
1 files changed, 38 insertions, 36 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/misc/HideDeadEntities.kt b/src/main/java/at/hannibal2/skyhanni/features/misc/HideDeadEntities.kt
index e4a29513f..6bca8e97d 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/misc/HideDeadEntities.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/misc/HideDeadEntities.kt
@@ -1,36 +1,38 @@
-package at.hannibal2.skyhanni.features.misc
-
-import at.hannibal2.skyhanni.events.CheckRenderEntityEvent
-import at.hannibal2.skyhanni.events.EntityHealthUpdateEvent
-import at.hannibal2.skyhanni.utils.LorenzUtils
-import net.minecraftforge.fml.common.eventhandler.SubscribeEvent
-
-class HideDeadEntities {
- private val hiddenEntities = mutableListOf<Int>()
-
- @SubscribeEvent
- fun onEntityHealthUpdate(event: EntityHealthUpdateEvent) {
- val entityId = event.entity.entityId
-
- if (event.health <= 0) {
- if (!hiddenEntities.contains(entityId)) {
- hiddenEntities.add(entityId)
-// LorenzUtils.chat("died: ${event.entity.name}")
- }
- } else {
- if (hiddenEntities.contains(entityId)) {
- hiddenEntities.remove(entityId)
- LorenzUtils.debug("respawned: ${event.entity.name}")
- }
- }
- }
-
- @SubscribeEvent
- fun onCheckRender(event: CheckRenderEntityEvent<*>) {
- if (!LorenzUtils.inSkyBlock) return
-
- if (hiddenEntities.contains(event.entity.entityId)) {
- event.isCanceled = true
- }
- }
-} \ No newline at end of file
+//package at.hannibal2.skyhanni.features.misc
+//
+//import at.hannibal2.skyhanni.events.CheckRenderEntityEvent
+//import at.hannibal2.skyhanni.events.EntityHealthUpdateEvent
+//import at.hannibal2.skyhanni.utils.LorenzUtils
+//import net.minecraftforge.fml.common.eventhandler.SubscribeEvent
+//
+//
+//// Skytils feature does work already.
+//
+//class HideDeadEntities {
+// private val hiddenEntities = mutableListOf<Int>()
+//
+// @SubscribeEvent
+// fun onEntityHealthUpdate(event: EntityHealthUpdateEvent) {
+// val entityId = event.entity.entityId
+//
+// if (event.health <= 0) {
+// if (!hiddenEntities.contains(entityId)) {
+// hiddenEntities.add(entityId)
+// }
+// } else {
+// if (hiddenEntities.contains(entityId)) {
+// hiddenEntities.remove(entityId)
+// LorenzUtils.debug("respawned: ${event.entity.name}")
+// }
+// }
+// }
+//
+// @SubscribeEvent
+// fun onCheckRender(event: CheckRenderEntityEvent<*>) {
+// if (!LorenzUtils.inSkyBlock) return
+//
+//// if (hiddenEntities.contains(event.entity.entityId)) {
+//// event.isCanceled = true
+//// }
+// }
+//} \ No newline at end of file