mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-06-10 05:34:54 +00:00
Fixed Level PMF
This commit is contained in:
parent
afbde5c7ac
commit
6a13705970
@ -847,7 +847,7 @@ class Player{
|
||||
if($diff > 16 and $d["sendtime"] < $limit){
|
||||
$this->directDataPacket($d["id"], $d, $d["pid"]);
|
||||
++$this->packetStats[1];
|
||||
$this->lag[] = microtime(true) - $this->recovery[$count]["sendtime"];
|
||||
$this->lag[] = microtime(true) - $d["sendtime"];
|
||||
unset($this->recovery[$count]);
|
||||
}
|
||||
}
|
||||
|
@ -303,7 +303,7 @@ class PMFLevel extends PMF{
|
||||
$X = $x >> 4;
|
||||
$Z = $z >> 4;
|
||||
$Y = $y >> 4;
|
||||
if($X >= 32 or $Z >= 32 or $Y >= $this->levelData["height"] or $y < 0){
|
||||
if($x < 0 or $z < 0 or $X >= $this->levelData["width"] or $Z >= $this->levelData["width"] or $Y >= $this->levelData["height"] or $y < 0){
|
||||
return array(AIR, 0);
|
||||
}
|
||||
$index = $this->getIndex($X, $Z);
|
||||
|
Loading…
x
Reference in New Issue
Block a user