Fix formatting issues due to bad IDE settings

This commit is contained in:
Shoghi Cervantes 2014-12-07 16:30:04 +01:00
parent bb82e7be50
commit 747f7685e7
191 changed files with 1315 additions and 1304 deletions

View File

@ -143,8 +143,8 @@ namespace pocketmine {
if($response = Utils::getURL("http://ip-api.com/json") if($response = Utils::getURL("http://ip-api.com/json")
and $ip_geolocation_data = json_decode($response, true) and $ip_geolocation_data = json_decode($response, true)
and $ip_geolocation_data['status'] != 'fail' and $ip_geolocation_data['status'] != 'fail'
and date_default_timezone_set($ip_geolocation_data['timezone'])) and date_default_timezone_set($ip_geolocation_data['timezone'])
{ ){
//Again, for redundancy. //Again, for redundancy.
ini_set("date.timezone", $ip_geolocation_data['timezone']); ini_set("date.timezone", $ip_geolocation_data['timezone']);
}else{ }else{
@ -192,8 +192,7 @@ namespace pocketmine {
//Detect the Time Zone string //Detect the Time Zone string
preg_match($regex, $string, $matches); preg_match($regex, $string, $matches);
if(!isset($matches[2])) if(!isset($matches[2])){
{
return false; return false;
} }
@ -251,6 +250,7 @@ namespace pocketmine {
/** /**
* @param string $offset In the format of +09:00, +02:00, -04:00 etc. * @param string $offset In the format of +09:00, +02:00, -04:00 etc.
*
* @return string * @return string
*/ */
function parse_offset($offset){ function parse_offset($offset){

View File

@ -20,6 +20,7 @@
*/ */
namespace pocketmine\block; namespace pocketmine\block;
use pocketmine\item\Item; use pocketmine\item\Item;

View File

@ -22,7 +22,6 @@
namespace pocketmine\block; namespace pocketmine\block;
abstract class Transparent extends Block{ abstract class Transparent extends Block{
public function isTransparent(){ public function isTransparent(){

View File

@ -90,7 +90,8 @@ class Trapdoor extends Transparent{
$this->y + 1, $this->y + 1,
$this->z + $f $this->z + $f
); );
}if(($damage & 0x03) === 2){ }
if(($damage & 0x03) === 2){
$bb->setBounds( $bb->setBounds(
$this->x + 1 - $f, $this->x + 1 - $f,
$this->y, $this->y,
@ -99,7 +100,8 @@ class Trapdoor extends Transparent{
$this->y + 1, $this->y + 1,
$this->z + 1 $this->z + 1
); );
}if(($damage & 0x03) === 3){ }
if(($damage & 0x03) === 3){
$bb->setBounds( $bb->setBounds(
$this->x, $this->x,
$this->y, $this->y,

View File

@ -131,6 +131,7 @@ class FallingSand extends Entity{
public function getBlock(){ public function getBlock(){
return $this->blockId; return $this->blockId;
} }
public function getDamage(){ public function getDamage(){
return $this->damage; return $this->damage;
} }

View File

@ -82,7 +82,6 @@ abstract class Projectile extends Entity{
} }
$tickDiff = max(1, $currentTick - $this->lastUpdate); $tickDiff = max(1, $currentTick - $this->lastUpdate);
$this->lastUpdate = $currentTick; $this->lastUpdate = $currentTick;

View File

@ -364,7 +364,6 @@ class PlayerInventory extends BaseInventory{
} }
/** /**
* @param int $index * @param int $index
* @param Player|Player[] $target * @param Player|Player[] $target

View File

@ -253,7 +253,6 @@ class McRegion extends BaseLevelProvider{
$chunk->setZ($chunkZ); $chunk->setZ($chunkZ);
if($this->getChunk($chunkX, $chunkZ, false) !== $chunk){ if($this->getChunk($chunkX, $chunkZ, false) !== $chunk){
$this->unloadChunk($chunkX, $chunkZ, false); $this->unloadChunk($chunkX, $chunkZ, false);
} }

View File

@ -122,7 +122,8 @@ class GenerationChunkManager implements ChunkManager{
$this->getChunk($chunkX, $chunkZ); $this->getChunk($chunkX, $chunkZ);
$this->generator->generateChunk($chunkX, $chunkZ); $this->generator->generateChunk($chunkX, $chunkZ);
$this->setChunkGenerated($chunkX, $chunkZ); $this->setChunkGenerated($chunkX, $chunkZ);
}catch(\Exception $e){} }catch(\Exception $e){
}
} }
public function populateChunk($chunkX, $chunkZ){ public function populateChunk($chunkX, $chunkZ){
@ -163,7 +164,8 @@ class GenerationChunkManager implements ChunkManager{
$chunk = $this->getChunk($chunkX, $chunkZ); $chunk = $this->getChunk($chunkX, $chunkZ);
$chunk->setGenerated(true); $chunk->setGenerated(true);
$this->changes["$chunkX:$chunkZ"] = $chunk; $this->changes["$chunkX:$chunkZ"] = $chunk;
}catch(\Exception $e){} }catch(\Exception $e){
}
} }
public function setChunkPopulated($chunkX, $chunkZ){ public function setChunkPopulated($chunkX, $chunkZ){
@ -171,7 +173,8 @@ class GenerationChunkManager implements ChunkManager{
$chunk = $this->getChunk($chunkX, $chunkZ); $chunk = $this->getChunk($chunkX, $chunkZ);
$chunk->setPopulated(true); $chunk->setPopulated(true);
$this->changes["$chunkX:$chunkZ"] = $chunk; $this->changes["$chunkX:$chunkZ"] = $chunk;
}catch(\Exception $e){} }catch(\Exception $e){
}
} }
protected function requestChunk($chunkX, $chunkZ){ protected function requestChunk($chunkX, $chunkZ){
@ -222,7 +225,8 @@ class GenerationChunkManager implements ChunkManager{
public function setBlockIdAt($x, $y, $z, $id){ public function setBlockIdAt($x, $y, $z, $id){
try{ try{
$this->getChunk($x >> 4, $z >> 4)->setBlockId($x & 0x0f, $y & 0x7f, $z & 0x0f, $id & 0xff); $this->getChunk($x >> 4, $z >> 4)->setBlockId($x & 0x0f, $y & 0x7f, $z & 0x0f, $id & 0xff);
}catch(\Exception $e){} }catch(\Exception $e){
}
} }
/** /**
@ -253,7 +257,8 @@ class GenerationChunkManager implements ChunkManager{
public function setBlockDataAt($x, $y, $z, $data){ public function setBlockDataAt($x, $y, $z, $data){
try{ try{
$this->getChunk($x >> 4, $z >> 4)->setBlockData($x & 0x0f, $y & 0x7f, $z & 0x0f, $data & 0x0f); $this->getChunk($x >> 4, $z >> 4)->setBlockData($x & 0x0f, $y & 0x7f, $z & 0x0f, $data & 0x0f);
}catch(\Exception $e){} }catch(\Exception $e){
}
} }
public function shutdown(){ public function shutdown(){

View File

@ -20,6 +20,7 @@
*/ */
namespace pocketmine\math; namespace pocketmine\math;
use pocketmine\level\MovingObjectPosition; use pocketmine\level\MovingObjectPosition;
class AxisAlignedBB{ class AxisAlignedBB{

View File

@ -42,6 +42,7 @@ use pocketmine\utils\Utils;
#ifndef COMPILE #ifndef COMPILE
use pocketmine\utils\Binary; use pocketmine\utils\Binary;
#endif #endif

View File

@ -25,6 +25,7 @@ namespace pocketmine\network\protocol;
#ifndef COMPILE #ifndef COMPILE
use pocketmine\utils\Binary; use pocketmine\utils\Binary;
#endif #endif
class AddMobPacket extends DataPacket{ class AddMobPacket extends DataPacket{

View File

@ -25,6 +25,7 @@ namespace pocketmine\network\protocol;
#ifndef COMPILE #ifndef COMPILE
use pocketmine\utils\Binary; use pocketmine\utils\Binary;
#endif #endif
class AddPlayerPacket extends DataPacket{ class AddPlayerPacket extends DataPacket{

View File

@ -25,6 +25,7 @@ namespace pocketmine\network\protocol;
#ifndef COMPILE #ifndef COMPILE
use pocketmine\utils\Binary; use pocketmine\utils\Binary;
#endif #endif
class SetEntityDataPacket extends DataPacket{ class SetEntityDataPacket extends DataPacket{

View File

@ -238,7 +238,8 @@ class Furnace extends Tile implements InventoryHolder, Container{
$this->namedtag->CookTime = new Short("CookTime", 0); $this->namedtag->CookTime = new Short("CookTime", 0);
} }
$ret = true; $ret = true;
}else{; }else{
;
if($this->getBlock()->getId() === Item::BURNING_FURNACE){ if($this->getBlock()->getId() === Item::BURNING_FURNACE){
$this->getLevel()->setBlock($this, Block::get(Item::FURNACE, $this->getBlock()->getDamage()), true); $this->getLevel()->setBlock($this, Block::get(Item::FURNACE, $this->getBlock()->getDamage()), true);
} }