mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-08-31 15:31:07 +00:00
Fixed swimming and gliding for PlayerAuthInputPacket
This commit is contained in:
parent
d41f933e7b
commit
18e26d975b
@ -201,7 +201,14 @@ class InGamePacketHandler extends PacketHandler{
|
|||||||
if($sprinting !== null){
|
if($sprinting !== null){
|
||||||
$this->player->toggleSprint($sprinting);
|
$this->player->toggleSprint($sprinting);
|
||||||
}
|
}
|
||||||
//TODO: swimming, gliding
|
$swimming = $this->resolveOnOffInputFlags($packet, PlayerAuthInputFlags::START_SWIMMING, PlayerAuthInputFlags::STOP_SWIMMING);
|
||||||
|
if($swimming !== null){
|
||||||
|
$this->player->toggleSwim($swimming);
|
||||||
|
}
|
||||||
|
$gliding = $this->resolveOnOffInputFlags($packet, PlayerAuthInputFlags::START_GLIDING, PlayerAuthInputFlags::STOP_GLIDING);
|
||||||
|
if($gliding !== null){
|
||||||
|
$this->player->toggleGlide($gliding);
|
||||||
|
}
|
||||||
|
|
||||||
//TODO: this packet has WAYYYYY more useful information that we're not using
|
//TODO: this packet has WAYYYYY more useful information that we're not using
|
||||||
$this->player->handleMovement($newPos);
|
$this->player->handleMovement($newPos);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user