aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2/skyhanni/data
diff options
context:
space:
mode:
authorhannibal2 <24389977+hannibal00212@users.noreply.github.com>2023-08-03 22:29:50 +0200
committerhannibal2 <24389977+hannibal00212@users.noreply.github.com>2023-08-03 22:29:50 +0200
commit30a225daffaabfa0457dbc8e182f575683a0cc95 (patch)
treedf9c5abc4930f5844be65d7fa0b4e3fba6a56115 /src/main/java/at/hannibal2/skyhanni/data
parent5dee3f298497dae472e80235091b659e4042fd49 (diff)
downloadskyhanni-30a225daffaabfa0457dbc8e182f575683a0cc95.tar.gz
skyhanni-30a225daffaabfa0457dbc8e182f575683a0cc95.tar.bz2
skyhanni-30a225daffaabfa0457dbc8e182f575683a0cc95.zip
added toMutableList back to all entity utils methods, removed OrNull methods
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/data')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/data/EntityData.kt3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/data/EntityData.kt b/src/main/java/at/hannibal2/skyhanni/data/EntityData.kt
index 0bc742198..dad4a1bf3 100644
--- a/src/main/java/at/hannibal2/skyhanni/data/EntityData.kt
+++ b/src/main/java/at/hannibal2/skyhanni/data/EntityData.kt
@@ -21,8 +21,7 @@ class EntityData {
@SubscribeEvent
fun onTick(event: LorenzTickEvent) {
- val entities = EntityUtils.getEntitiesOrNull<EntityLivingBase>() ?: return
- for (entity in entities) {
+ for (entity in EntityUtils.getEntities<EntityLivingBase>()) {
val maxHealth = entity.baseMaxHealth
val oldMaxHealth = maxHealthMap.getOrDefault(entity, -1)
if (oldMaxHealth != maxHealth) {