Promote some constructors

This commit is contained in:
Dylan K. Taylor
2022-05-17 22:34:58 +01:00
parent 8e767da29e
commit d4b7f66e15
30 changed files with 144 additions and 218 deletions

View File

@ -29,13 +29,12 @@ use pocketmine\player\Player;
* Called when a player requests a different viewing distance than the current one.
*/
class PlayerViewDistanceChangeEvent extends PlayerEvent{
protected int $newDistance;
protected int $oldDistance;
public function __construct(Player $player, int $oldDistance, int $newDistance){
public function __construct(
Player $player,
protected int $oldDistance,
protected int $newDistance
){
$this->player = $player;
$this->oldDistance = $oldDistance;
$this->newDistance = $newDistance;
}
/**