mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-21 03:59:43 +00:00
onUpdate is now static, disabled rail, water and lava updates to rework.
This commit is contained in:
parent
3c37dc446e
commit
ee989ef556
38 changed files with 329 additions and 367 deletions
|
|
@ -465,12 +465,16 @@ class Level{
|
|||
}
|
||||
}
|
||||
|
||||
public function fastSetBlockUpdate($x, $y, $z, $id, $meta, $updateBlocksAround = false){
|
||||
public function fastSetBlockUpdate($x, $y, $z, $id, $meta, $updateBlocksAround = false, $tiles = false){
|
||||
$this->level->setBlock($x, $y, $z, $id, $meta);
|
||||
$this->addBlockToSendQueue($x, $y, $z, $id, $meta);
|
||||
if($updateBlocksAround){
|
||||
$this->server->api->block->blockUpdateAround(new Position($x, $y, $z, $this), BLOCK_UPDATE_NORMAL, 1);
|
||||
}
|
||||
|
||||
if($tiles && ($t = $this->server->api->tile->getXYZ($this, $x, $y, $z)) != false){ //TODO rewrite
|
||||
$t->close();
|
||||
}
|
||||
}
|
||||
|
||||
public function onTick(PocketMinecraftServer $server, $currentTime){
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue