mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-23 21:19:44 +00:00
Unnecessary return/continue
This commit is contained in:
parent
e2dae67a1c
commit
d3f5386812
5 changed files with 5 additions and 10 deletions
|
|
@ -1037,7 +1037,6 @@ class Player{
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return;
|
|
||||||
reset_spawn_pos:
|
reset_spawn_pos:
|
||||||
$this->spawnPosition = $this->server->api->level->getDefault()->getSpawn();
|
$this->spawnPosition = $this->server->api->level->getDefault()->getSpawn();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1496,7 +1496,6 @@ class Entity extends Position
|
||||||
{
|
{
|
||||||
if($this->class === ENTITY_PLAYER){
|
if($this->class === ENTITY_PLAYER){
|
||||||
$this->player->teleport(new Vector3($this->x, $this->y, $this->z), false, false, true, false);
|
$this->player->teleport(new Vector3($this->x, $this->y, $this->z), false, false, true, false);
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -139,7 +139,6 @@ class Arrow extends Entity{
|
||||||
++$this->groundTicks;
|
++$this->groundTicks;
|
||||||
if($this->groundTicks >= 1200){ //TODO customizeable?
|
if($this->groundTicks >= 1200){ //TODO customizeable?
|
||||||
$this->close();
|
$this->close();
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
}else{
|
}else{
|
||||||
$this->inGround = false;
|
$this->inGround = false;
|
||||||
|
|
|
||||||
|
|
@ -162,7 +162,6 @@ function arguments($args){
|
||||||
}
|
}
|
||||||
|
|
||||||
$ret['input'][] = $arg;
|
$ret['input'][] = $arg;
|
||||||
continue;
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -45,7 +45,6 @@ class GrassBlock extends SolidBlock{
|
||||||
ServerAPI::request()->api->entity->drop(new Position($this->x+0.5, $this->y+1, $this->z+0.5, $this->level), BlockAPI::getItem(295,0,1));
|
ServerAPI::request()->api->entity->drop(new Position($this->x+0.5, $this->y+1, $this->z+0.5, $this->level), BlockAPI::getItem(295,0,1));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
public static function onRandomTick(Level $level, $x, $y, $z){
|
public static function onRandomTick(Level $level, $x, $y, $z){
|
||||||
if(!StaticBlock::getIsTransparent($level->level->getBlockID($x, $y + 1, $z)) && mt_rand(0, 2) == 1){
|
if(!StaticBlock::getIsTransparent($level->level->getBlockID($x, $y + 1, $z)) && mt_rand(0, 2) == 1){
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue