mirror of
https://github.com/PaperMC/Paper.git
synced 2025-08-31 12:23:51 -07:00
#718: Add consumed item, hand and consumeItem boolean to EntityShootBowEvent
By: Parker Hawke <hawkeboyz2@hotmail.com>
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
|
||||
entityarrow.shoot(d0, d1 + d3 * 0.20000000298023224D, d2, 1.6F, (float) (14 - this.world.getDifficulty().a() * 4));
|
||||
+ // CraftBukkit start
|
||||
+ org.bukkit.event.entity.EntityShootBowEvent event = org.bukkit.craftbukkit.event.CraftEventFactory.callEntityShootBowEvent(this, this.getItemInMainHand(), entityarrow, 0.8F);
|
||||
+ org.bukkit.event.entity.EntityShootBowEvent event = org.bukkit.craftbukkit.event.CraftEventFactory.callEntityShootBowEvent(this, this.getItemInMainHand(), null, entityarrow, EnumHand.MAIN_HAND, 0.8F, true);
|
||||
+ if (event.isCancelled()) {
|
||||
+ event.getProjectile().remove();
|
||||
+ return;
|
||||
|
Reference in New Issue
Block a user