Class EntityDamageListener
java.lang.Object
dev.cwhead.GravesX.listener.integration.nexo.EntityDamageListener
- All Implemented Interfaces:
org.bukkit.event.Listener
Listens for EntityDamageEvent and cancels damage if the entity is an ItemFrame associated with a grave.
-
Constructor Summary
ConstructorsConstructorDescriptionEntityDamageListener
(Nexo nexo) Constructs a new EntityDamageListener with the specified Nexo instance. -
Method Summary
Modifier and TypeMethodDescriptionvoid
onEntityDamage
(org.bukkit.event.entity.EntityDamageEvent event) Handles EntityDamageEvent.
-
Constructor Details
-
EntityDamageListener
Constructs a new EntityDamageListener with the specified Nexo instance.- Parameters:
nexo
- The Nexo instance to use.
-
-
Method Details
-
onEntityDamage
public void onEntityDamage(org.bukkit.event.entity.EntityDamageEvent event) Handles EntityDamageEvent. If the entity being damaged is an ItemFrame and is associated with a grave, it cancels the damage event.- Parameters:
event
- The EntityDamageEvent to handle.
-