Add toString() implementation to MonsterEntity
This commit is contained in:
parent
79381845b0
commit
297fb46bde
@ -327,6 +327,10 @@ class MonsterEntity(val variant: MonsterVariant, level: Double? = null) : ActorE
|
|||||||
|
|
||||||
private val deathDamageKinds = ObjectArraySet<String>()
|
private val deathDamageKinds = ObjectArraySet<String>()
|
||||||
|
|
||||||
|
override fun toString(): String {
|
||||||
|
return "MonsterEntity[${variant.type}@${variant.seed} / ${if (isInWorld) world.toString() else "not in world"} / $position]"
|
||||||
|
}
|
||||||
|
|
||||||
override fun experienceDamage(damage: DamageRequestPacket): List<DamageNotification> {
|
override fun experienceDamage(damage: DamageRequestPacket): List<DamageNotification> {
|
||||||
val notifications = statusController.experienceDamage(damage.request)
|
val notifications = statusController.experienceDamage(damage.request)
|
||||||
val totalDamage = notifications.sumOf { it.healthLost }
|
val totalDamage = notifications.sumOf { it.healthLost }
|
||||||
|
Loading…
Reference in New Issue
Block a user