Class EntityProjectileDamage
java.lang.Object
net.minestom.server.entity.damage.DamageType
net.minestom.server.entity.damage.EntityProjectileDamage
- All Implemented Interfaces:
DataContainer
public class EntityProjectileDamage extends DamageType
Represents damage inflicted by an entity, via a projectile.
-
Field Summary
-
Constructor Summary
Constructors Constructor Description EntityProjectileDamage(Entity shooter, Entity projectile)
-
Method Summary
Modifier and Type Method Description Entity
getProjectile()
Gets the projectile responsible for the damage.Entity
getShooter()
Gets the shooter of the projectile.Methods inherited from class net.minestom.server.entity.damage.DamageType
buildDeathMessage, buildDeathScreenText, fromEntity, fromPlayer, fromProjectile, getData, getGenericSound, getIdentifier, getPlayerSound, getSound, setData
-
Constructor Details
-
Method Details
-
getProjectile
Gets the projectile responsible for the damage.- Returns:
- the projectile
-
getShooter
Gets the shooter of the projectile.- Returns:
- the shooter of the projectile, null if not any
-