mirror of
https://github.com/PaperMC/Paper.git
synced 2025-08-11 18:22:08 -07:00
[Bleeding] Implemented ProjectileLaunchEvent. Addresses BUKKIT-284
This commit is contained in:
committed by
EvilSeph
parent
6f6f8ef008
commit
92f771a022
@@ -897,6 +897,11 @@ public class World implements IBlockAccess {
|
||||
if (event.isCancelled()) {
|
||||
return false;
|
||||
}
|
||||
} else if (entity.getBukkitEntity() instanceof org.bukkit.entity.Projectile) {
|
||||
// Not all projectiles extend EntityProjectile, so check for Bukkit interface instead
|
||||
if (CraftEventFactory.callProjectileLaunchEvent(entity).isCancelled()) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
// CraftBukkit end
|
||||
|
||||
|
Reference in New Issue
Block a user