Skip to content

Commit

Permalink
Make EntityUtils constants final
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexander01998 committed Oct 29, 2023
1 parent 5930fd8 commit a203f0e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/java/net/wurstclient/util/EntityUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public static Stream<Entity> getAttackableEntities()
.filter(IS_ATTACKABLE);
}

public static Predicate<Entity> IS_ATTACKABLE = e -> e != null
public static final Predicate<Entity> IS_ATTACKABLE = e -> e != null
&& !e.isRemoved()
&& (e instanceof LivingEntity && ((LivingEntity)e).getHealth() > 0
|| e instanceof EndCrystalEntity
Expand All @@ -50,7 +50,7 @@ public static Stream<AnimalEntity> getValidAnimals()
.filter(IS_VALID_ANIMAL);
}

public static Predicate<AnimalEntity> IS_VALID_ANIMAL =
public static final Predicate<AnimalEntity> IS_VALID_ANIMAL =
a -> a != null && !a.isRemoved() && a.getHealth() > 0;

/**
Expand Down

0 comments on commit a203f0e

Please sign in to comment.