Particle::encode() now always returns ClientboundPacket[]

This commit is contained in:
Dylan K. Taylor
2020-10-31 15:51:17 +00:00
parent 5a320f22b7
commit 66edf5a165
38 changed files with 73 additions and 76 deletions

View File

@ -36,7 +36,7 @@ class ItemBreakParticle implements Particle{
$this->item = $item;
}
public function encode(Vector3 $pos){
return LevelEventPacket::standardParticle(ParticleIds::ITEM_BREAK, ($this->item->getId() << 16) | $this->item->getMeta(), $pos);
public function encode(Vector3 $pos) : array{
return [LevelEventPacket::standardParticle(ParticleIds::ITEM_BREAK, ($this->item->getId() << 16) | $this->item->getMeta(), $pos)];
}
}