mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-21 12:09:43 +00:00
player will not be able to move while sleeping
This commit is contained in:
parent
37b3c02396
commit
070755ba8e
1 changed files with 1 additions and 2 deletions
|
|
@ -1504,11 +1504,10 @@ class Player{
|
|||
}
|
||||
break;
|
||||
case ProtocolInfo::MOVE_PLAYER_PACKET:
|
||||
|
||||
if($this->spawned === false){
|
||||
break;
|
||||
}
|
||||
|
||||
if($this->isSleeping) break;
|
||||
if(($this->entity instanceof Entity) and $packet->messageIndex > $this->lastMovement){
|
||||
$this->lastMovement = $packet->messageIndex;
|
||||
$newPos = new Vector3($packet->x, $packet->y, $packet->z);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue