DamageCause Issues

Discussion in 'Spigot Plugin Development' started by DireLegendDev, Jul 8, 2015.

  1. I am trying to stop players that are in an arraylist from being damaged by fire. When I use essentials /burn it stops the damage, but w/ flint and steel damage is caused. I tried both DamageCause.FIRE && DamageCause.FIRE_TICKS but neither worked.

    Code (Text):
        public void onNoFire(EntityDamageEvent e) {
            if (e.getEntity() instanceof Player) {
                Player player = (Player) e.getEntity();
                if (e.getCause() == DamageCause.FIRE) {
                    if (nofire.contains(player)) {
  2. Solved- Just tested for all fire damage causes and its fixed for some reason!