mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-07-29 14:15:47 +00:00
Player: Disallow modifying NBT of tiles inside spawn protection
This commit is contained in:
parent
a5e87484d9
commit
590826b9bd
@ -2874,7 +2874,7 @@ class Player extends Human implements CommandSender, ChunkLoader, IPlayer{
|
||||
$this->resetCraftingGridType();
|
||||
|
||||
$pos = new Vector3($packet->x, $packet->y, $packet->z);
|
||||
if($pos->distanceSquared($this) > 10000){
|
||||
if($pos->distanceSquared($this) > 10000 or $this->level->checkSpawnProtection($this, $pos)){
|
||||
return true;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user