mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-06-07 12:18:46 +00:00
Player: fixed parameter name inconsistency
This commit is contained in:
parent
82f1c2766c
commit
419bb9eba6
@ -1812,16 +1812,16 @@ class Player extends Human implements CommandSender, ChunkListener, IPlayer{
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function toggleSwim(bool $swimming) : bool{
|
public function toggleSwim(bool $swim) : bool{
|
||||||
if($swimming === $this->swimming){
|
if($swim === $this->swimming){
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
$ev = new PlayerToggleSwimEvent($this, $swimming);
|
$ev = new PlayerToggleSwimEvent($this, $swim);
|
||||||
$ev->call();
|
$ev->call();
|
||||||
if($ev->isCancelled()){
|
if($ev->isCancelled()){
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
$this->setSwimming($swimming);
|
$this->setSwimming($swim);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user