mirror of
https://github.com/Minestom/Minestom.git
synced 2025-01-08 09:27:58 +01:00
Not calculating entity collisions for arrows in first 3 ticks of its life
This commit is contained in:
parent
714e107eb3
commit
6e23552d9a
@ -90,6 +90,9 @@ public class EntityAbstractArrow extends ObjectEntity implements Projectile {
|
|||||||
.filter(entity -> entity instanceof LivingEntity)
|
.filter(entity -> entity instanceof LivingEntity)
|
||||||
.collect(Collectors.toSet());
|
.collect(Collectors.toSet());
|
||||||
}
|
}
|
||||||
|
if (getAliveTicks() < 3) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
Optional<Entity> victimOptional = entities.stream()
|
Optional<Entity> victimOptional = entities.stream()
|
||||||
.filter(entity -> entity.getBoundingBox().intersect(pos.getX(), pos.getY(), pos.getZ()))
|
.filter(entity -> entity.getBoundingBox().intersect(pos.getX(), pos.getY(), pos.getZ()))
|
||||||
.findAny();
|
.findAny();
|
||||||
|
Loading…
Reference in New Issue
Block a user