Don't blindly check cancel status for all damage

If fall damage is disabled via another plugin like WorldGuard, abilities like Shockwave can't function upon landing. Plus, there's already a lot of checks for event.isCancelled, so don't see a reason to do a check for the entire event.
This commit is contained in:
RoboMWM 2016-05-19 16:08:30 -07:00
parent e9ee121574
commit d242ecd1fc

View file

@ -732,11 +732,8 @@ public class PKListener implements Listener {
event.setFormat(format);
}
@EventHandler(priority = EventPriority.NORMAL, ignoreCancelled = true)
@EventHandler(priority = EventPriority.NORMAL)
public void onPlayerDamage(EntityDamageEvent event) {
if (event.isCancelled()) {
return;
}
if (event.getEntity() instanceof Player) {
Player player = (Player) event.getEntity();