From 3497e2d1e7f1b90e325a698cc1ed6f25e94b8393 Mon Sep 17 00:00:00 2001 From: Chaoscaot Date: Tue, 13 Apr 2021 19:52:31 +0200 Subject: [PATCH] Remove Unused IMoving Checks Around --- .../src/de/steamwar/fightsystem/listener/Recording.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/FightSystem_Main/src/de/steamwar/fightsystem/listener/Recording.java b/FightSystem_Main/src/de/steamwar/fightsystem/listener/Recording.java index f3bd7c9..8d0bb26 100644 --- a/FightSystem_Main/src/de/steamwar/fightsystem/listener/Recording.java +++ b/FightSystem_Main/src/de/steamwar/fightsystem/listener/Recording.java @@ -145,11 +145,12 @@ public class Recording implements Listener { @EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true) public void onEntityDamage(EntityDamageEvent e) { + if(e.getEntityType() != EntityType.PLAYER) + return; + if(e.getCause() == EntityDamageEvent.DamageCause.FIRE_TICK || e.getCause() == EntityDamageEvent.DamageCause.FIRE ||e.getEntity().getFireTicks() > 0) RecordSystem.setOnFire(e.getEntity(), false); - if(e.getEntityType() != EntityType.PLAYER) - return; Player p = (Player) e.getEntity(); if(isNotSent(p))