Fix all (non-deprecation) compiler warnings (#3321)

* Fix all (non-deprecation) compiler warnings

* satisfy spotless

* use a method ref over a lambda
This commit is contained in:
Al Winfy authored and GitHub committed 2020-06-07 21:48:55 -05:00
1 parent a01f3fed15
commit cbc36366de
30 files changed
+55 -40

No files matched your search

@@ -191,14 +191,14 @@ public class EntityMagicMissile extends ThrowableEntity {
double range = 12;
AxisAlignedBB bounds = new AxisAlignedBB(getPosX() - range, getPosY() - range, getPosZ() - range, getPosX() + range, getPosY() + range, getPosZ() + range);
List entities;
List<Entity> entities;
if (isEvil()) {
entities = world.getEntitiesWithinAABB(PlayerEntity.class, bounds);
} else {
entities = world.getEntitiesWithinAABB(Entity.class, bounds, Predicates.instanceOf(IMob.class));
}
while (entities.size() > 0) {
Entity e = (Entity) entities.get(world.rand.nextInt(entities.size()));
Entity e = entities.get(world.rand.nextInt(entities.size()));
if (!(e instanceof LivingEntity) || !e.isAlive()) { // Just in case...
entities.remove(e);
continue;