mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-06 17:59:48 +00:00
Modernize property declarations in src/world/particle
This commit is contained in:
@ -29,12 +29,7 @@ use pocketmine\network\mcpe\protocol\LevelEventPacket;
|
||||
use pocketmine\network\mcpe\protocol\types\ParticleIds;
|
||||
|
||||
class ItemBreakParticle implements Particle{
|
||||
/** @var Item */
|
||||
private $item;
|
||||
|
||||
public function __construct(Item $item){
|
||||
$this->item = $item;
|
||||
}
|
||||
public function __construct(private Item $item){}
|
||||
|
||||
public function encode(Vector3 $pos) : array{
|
||||
return [LevelEventPacket::standardParticle(ParticleIds::ITEM_BREAK, ($this->item->getId() << 16) | $this->item->getMeta(), $pos)];
|
||||
|
Reference in New Issue
Block a user