mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-06 17:59:48 +00:00
NBT is no longer needed to create an entity
it's still able to be provided, but shouldn't be needed in the majority of cases (constructor args and/or API methods should be sufficient).
This commit is contained in:
@ -29,7 +29,6 @@ use pocketmine\entity\projectile\Projectile;
|
||||
use pocketmine\event\entity\EntityShootBowEvent;
|
||||
use pocketmine\event\entity\ProjectileLaunchEvent;
|
||||
use pocketmine\item\enchantment\Enchantment;
|
||||
use pocketmine\nbt\tag\CompoundTag;
|
||||
use pocketmine\player\Player;
|
||||
use pocketmine\world\sound\BowShootSound;
|
||||
use function intdiv;
|
||||
@ -62,7 +61,7 @@ class Bow extends Tool{
|
||||
$player->getWorld(),
|
||||
($location->yaw > 180 ? 360 : 0) - $location->yaw,
|
||||
-$location->pitch
|
||||
), $player, $baseForce >= 1, new CompoundTag());
|
||||
), $player, $baseForce >= 1);
|
||||
$entity->setMotion($player->getDirectionVector());
|
||||
|
||||
$infinity = $this->hasEnchantment(Enchantment::INFINITY());
|
||||
|
Reference in New Issue
Block a user