9
0
mirror of https://github.com/Auxilor/EcoMobs.git synced 2025-12-22 08:29:20 +00:00

remove useless mob getter

This commit is contained in:
grzybeek
2022-07-21 17:07:37 +02:00
parent de2b8f7526
commit 05cf399e77

View File

@@ -7,7 +7,7 @@ import org.bukkit.entity.Mob
class LivingEcoBoss( class LivingEcoBoss(
plugin: EcoPlugin, plugin: EcoPlugin,
private val mob: Mob, val entity: Mob,
val boss: EcoBoss, val boss: EcoBoss,
private val tickers: Set<BossTicker> private val tickers: Set<BossTicker>
) { ) {
@@ -17,9 +17,6 @@ class LivingEcoBoss(
} }
}.apply { runTaskTimer(1, 1) } }.apply { runTaskTimer(1, 1) }
val entity: Mob
get() = mob
val chunk: Chunk val chunk: Chunk
get() = entity.location.chunk get() = entity.location.chunk
@@ -47,10 +44,10 @@ class LivingEcoBoss(
entity.remove() entity.remove()
tickers.forEach { it.onDeath(this, currentTick) } tickers.forEach { it.onDeath(this, currentTick) }
boss.markDead(mob.uniqueId) boss.markDead(entity.uniqueId)
} }
override fun toString(): String { override fun toString(): String {
return "LivingEcoBoss{boss=${boss}, uuid=${mob.uniqueId}}" return "LivingEcoBoss{boss=${boss}, uuid=${entity.uniqueId}}"
} }
} }