@Override
  public boolean test(Character attacker, Character attacked, Skill skill, float val) {
    if (!attacker.isPlayer()) return true;

    Equipment equipment = attacker.getEquipment();

    if (equipment == null) return false;

    Slot[] slots = equipment.getSlots();

    for (Enum<?> type : types) {
      for (Slot slot : slots) {
        if (slot.isEmpty()) continue;

        if (type == slot.getItem().getType()) return true;
      }
    }

    return false;
  }