Skip to content

Commit 806d88e

Browse files
committed
Player: fixed suspicious ground state check
fixes #3552 and #3553 for non-spectator-gamemode situations this would've caused problems if setHasBlockCollision(false) was used in other game modes
1 parent 2d0dd72 commit 806d88e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/player/Player.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1304,7 +1304,7 @@ public function getXpDropAmount() : int{
13041304
}
13051305

13061306
protected function checkGroundState(float $wantedX, float $wantedY, float $wantedZ, float $dx, float $dy, float $dz) : void{
1307-
if($this->gamemode === GameMode::SPECTATOR){
1307+
if(!$this->blockCollision){
13081308
$this->onGround = false;
13091309
}else{
13101310
$bb = clone $this->boundingBox;

0 commit comments

Comments
 (0)