mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-23 11:06:29 +01:00
SPIGOT-3482: ProjectileHitEvent for shulker bullet and llama spit
This commit is contained in:
parent
2c5c611d0c
commit
86aa17fae1
@ -9,3 +9,11 @@
|
||||
private NBTTagCompound b;
|
||||
|
||||
public EntityLlamaSpit(World world) {
|
||||
@@ -143,6 +143,7 @@
|
||||
}
|
||||
|
||||
public void a(MovingObjectPosition movingobjectposition) {
|
||||
+ org.bukkit.craftbukkit.event.CraftEventFactory.callProjectileHitEvent(this, movingobjectposition); // Craftbukkit - Call event
|
||||
if (movingobjectposition.entity != null && this.shooter != null) {
|
||||
movingobjectposition.entity.damageEntity(DamageSource.a(this, this.shooter).b(), 1.0F);
|
||||
}
|
||||
|
@ -30,3 +30,11 @@
|
||||
protected void b(NBTTagCompound nbttagcompound) {
|
||||
BlockPosition blockposition;
|
||||
NBTTagCompound nbttagcompound1;
|
||||
@@ -287,6 +308,7 @@
|
||||
}
|
||||
|
||||
protected void a(MovingObjectPosition movingobjectposition) {
|
||||
+ org.bukkit.craftbukkit.event.CraftEventFactory.callProjectileHitEvent(this, movingobjectposition); // Craftbukkit - Call event
|
||||
if (movingobjectposition.entity == null) {
|
||||
((WorldServer) this.world).a(EnumParticle.EXPLOSION_LARGE, this.locX, this.locY, this.locZ, 2, 0.2D, 0.2D, 0.2D, 0.0D, new int[0]);
|
||||
this.a(SoundEffects.gD, 1.0F, 1.0F);
|
||||
|
Loading…
Reference in New Issue
Block a user