mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-21 12:09:43 +00:00
Merge pull request #930 from beN39sGroup/master
This commit is contained in:
parent
1cb711d32d
commit
b66f34b308
6 changed files with 56 additions and 62 deletions
|
|
@ -101,6 +101,7 @@ class LavaBlock extends LiquidBlock{
|
|||
$down = $this->getSide(0);
|
||||
|
||||
$from = $this->getFrom();
|
||||
//출처가 있거나 이 자체가 출처이면
|
||||
if($from !== null || $level == 0x00)
|
||||
{
|
||||
if($level !== 0x07)
|
||||
|
|
@ -130,17 +131,33 @@ class LavaBlock extends LiquidBlock{
|
|||
}
|
||||
else
|
||||
{
|
||||
//Extend Request for Left Lavas
|
||||
//Extend Remove for Left Lavas
|
||||
for($side = 2; $side <= 5; ++$side)
|
||||
{
|
||||
$sb = $this->getSide($side);
|
||||
if($sb instanceof LavaBlock)
|
||||
{
|
||||
$tlevel = $sb->meta & 0x07;
|
||||
if($tlevel != 0x00)
|
||||
{
|
||||
$this->level->setBlock($sb, new AirBlock(), false, false, true);
|
||||
}
|
||||
}
|
||||
$b = $this->getSide(0)->getSide($side);
|
||||
ServerAPI::request()->api->block->scheduleBlockUpdate(new Position($sb, 0, 0, $this->level), 40, BLOCK_UPDATE_NORMAL);
|
||||
ServerAPI::request()->api->block->scheduleBlockUpdate(new Position($b, 0, 0, $this->level), 40, BLOCK_UPDATE_NORMAL);
|
||||
if($b instanceof LavaBlock)
|
||||
{
|
||||
$tlevel = $b->meta & 0x07;
|
||||
if($tlevel != 0x00)
|
||||
{
|
||||
$this->level->setBlock($b, new AirBlock(), false, false, true);
|
||||
}
|
||||
}
|
||||
//ServerAPI::request()->api->block->scheduleBlockUpdate(new Position($b, 0, 0, $this->level), 10, BLOCK_UPDATE_NORMAL);
|
||||
}
|
||||
//출처가 제거된 경우 이 블록 제거
|
||||
$this->level->setBlock($this, new AirBlock(), false, false, true);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -141,12 +141,27 @@ class WaterBlock extends LiquidBlock{
|
|||
for($side = 2; $side <= 5; ++$side)
|
||||
{
|
||||
$sb = $this->getSide($side);
|
||||
if($sb instanceof WaterBlock)
|
||||
{
|
||||
$tlevel = $sb->meta & 0x07;
|
||||
if($tlevel != 0x00)
|
||||
{
|
||||
$this->level->setBlock($sb, new AirBlock(), false, false, true);
|
||||
}
|
||||
}
|
||||
$b = $this->getSide(0)->getSide($side);
|
||||
ServerAPI::request()->api->block->scheduleBlockUpdate(new Position($sb, 0, 0, $this->level), 10, BLOCK_UPDATE_NORMAL);
|
||||
ServerAPI::request()->api->block->scheduleBlockUpdate(new Position($b, 0, 0, $this->level), 10, BLOCK_UPDATE_NORMAL);
|
||||
if($b instanceof WaterBlock)
|
||||
{
|
||||
$tlevel = $b->meta & 0x07;
|
||||
if($tlevel != 0x00)
|
||||
{
|
||||
$this->level->setBlock($b, new AirBlock(), false, false, true);
|
||||
}
|
||||
}
|
||||
//ServerAPI::request()->api->block->scheduleBlockUpdate(new Position($b, 0, 0, $this->level), 10, BLOCK_UPDATE_NORMAL);
|
||||
}
|
||||
$this->level->setBlock($this, new AirBlock(), false, false, true);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue