Permalink
Browse files

Base PHP7 work to make it "run" - READ NEXT LINES!

All plugins will need to bump the API if they want to use this.
NOTE THAT THIS IS NOT THE FINAL API 2.0.0 AND THAT THERE WILL BE MORE CHANGES.
To start updating, you might also want to read https://secure.php.net/manual/en/migration70.php and specifically https://secure.php.net/manual/en/migration70.incompatible.php

To compile PHP7 with some of the required dependencies, use https://gist.github.com/shoghicp/166ab26ce5cc7a390f45
ONLY LINUX IS TESTED, DO NOT ASK FOR OTHER PLATFORMS!

----- THIS VERSION IS NOT SUPPORTED -----

This version WILL crash randomly in unexpected places due to PHP7, pthreads, PocketMine or cosmic rays.

Handle with care, and store under direct sunlight for the best performance.
1 parent 244cef3 commit e137ac4c56b161b6e48a715f3176a084681b29b5 @shoghicp shoghicp committed Sep 10, 2015
Showing with 131 additions and 124 deletions.
  1. +12 −9 src/pocketmine/PocketMine.php
  2. +26 −19 src/pocketmine/Server.php
  3. +2 −4 src/pocketmine/Thread.php
  4. +2 −4 src/pocketmine/Worker.php
  5. +3 −1 src/pocketmine/command/CommandReader.php
  6. +1 −1 src/pocketmine/command/FormattedCommandAlias.php
  7. +1 −1 src/pocketmine/command/SimpleCommandMap.php
  8. +1 −1 src/pocketmine/command/defaults/GiveCommand.php
  9. +35 −41 src/pocketmine/item/Item.php
  10. +2 −2 src/pocketmine/item/ItemBlock.php
  11. +1 −1 src/pocketmine/level/Level.php
  12. +3 −3 src/pocketmine/level/format/anvil/Chunk.php
  13. +2 −2 src/pocketmine/level/format/leveldb/Chunk.php
  14. +3 −3 src/pocketmine/level/format/mcregion/Chunk.php
  15. +1 −1 src/pocketmine/level/format/mcregion/RegionLoader.php
  16. +2 −2 src/pocketmine/network/CompressBatchedTask.php
  17. +2 −2 src/pocketmine/network/Network.php
  18. +1 −1 src/pocketmine/network/RakLibInterface.php
  19. +1 −1 src/pocketmine/network/rcon/RCON.php
  20. +4 −2 src/pocketmine/network/rcon/RCONInstance.php
  21. +2 −2 src/pocketmine/network/upnp/UPnP.php
  22. +4 −4 src/pocketmine/plugin/PluginManager.php
  23. +2 −3 src/pocketmine/scheduler/AsyncPool.php
  24. +3 −1 src/pocketmine/scheduler/AsyncTask.php
  25. +1 −1 src/pocketmine/scheduler/AsyncWorker.php
  26. +1 −1 src/pocketmine/scheduler/FileWriteTask.php
  27. +1 −1 src/pocketmine/scheduler/SendUsageTask.php
  28. +4 −2 src/pocketmine/scheduler/ServerScheduler.php
  29. +1 −1 src/pocketmine/utils/Config.php
  30. +1 −1 src/pocketmine/utils/MainLogger.php
  31. +1 −1 src/raklib
  32. +1 −1 src/spl
  33. +4 −4 start.sh
@@ -143,9 +143,8 @@ function dummy(){
//Logger has a dependency on timezone, so we'll set it to UTC until we can get the actual timezone.
date_default_timezone_set("UTC");
- var_dump("LOAD LOGGER");
+
$logger = new MainLogger(\pocketmine\DATA . "server.log", \pocketmine\ANSI);
- var_dump("LOGGER LOADED");
if(!ini_get("date.timezone")){
if(($timezone = detect_system_timezone()) and date_default_timezone_set($timezone)){
@@ -320,7 +319,11 @@ function kill($pid){
case "mac":
case "linux":
default:
- exec("kill -9 " . ((int) $pid) . " > /dev/null 2>&1");
+ if(function_exists("posix_kill")){
+ posix_kill($pid, SIGKILL);
+ }else{
+ exec("kill -9 " . ((int)$pid) . " > /dev/null 2>&1");
+ }
}
}
@@ -394,8 +397,8 @@ function cleanPath($path){
if(substr_count($pthreads_version, ".") < 2){
$pthreads_version = "0.$pthreads_version";
}
- if(version_compare($pthreads_version, "2.0.9") < 0){
- $logger->critical("pthreads >= 2.0.9 is required, while you have $pthreads_version.");
+ if(version_compare($pthreads_version, "3.0.0") < 0){
+ $logger->critical("pthreads >= 3.0.0 is required, while you have $pthreads_version.");
++$errors;
}
@@ -418,13 +421,13 @@ function cleanPath($path){
++$errors;
}
- if(!extension_loaded("sqlite3")){
- $logger->critical("Unable to find the SQLite3 extension.");
+ if(!extension_loaded("yaml")){
+ $logger->critical("Unable to find the YAML extension.");
@matcracker
matcracker Sep 10, 2015 Contributor

Why do you exchange sqlite with yaml? This isn't the same thing?

@shoghicp
shoghicp Sep 10, 2015 Member

check below, it was just swapped. done at different weeks :P

@matcracker
matcracker Sep 10, 2015 Contributor

True.. >.< Now I understand xD Nice work shoghi 👍

++$errors;
}
- if(!extension_loaded("yaml")){
- $logger->critical("Unable to find the YAML extension.");
+ if(!extension_loaded("sqlite3")){
+ $logger->critical("Unable to find the SQLite3 extension.");
++$errors;
}
@@ -132,6 +132,9 @@ class Server{
/** @var Server */
private static $instance = null;
+ /** @var \Threaded */
+ private static $sleeper = null;
+
/** @var BanList */
private $banByName = null;
@@ -754,7 +757,7 @@ public function getOfflinePlayerData($name){
$nbt->readCompressed(file_get_contents($path . "$name.dat"));
return $nbt->getData();
- }catch(\Exception $e){ //zlib decode error / corrupt data
+ }catch(\Throwable $e){ //zlib decode error / corrupt data
rename($path . "$name.dat", $path . "$name.dat.bak");
$this->logger->notice($this->getLanguage()->translateString("pocketmine.data.playerCorrupted", [$name]));
}
@@ -871,7 +874,7 @@ public function saveOfflinePlayerData($name, CompoundTag $nbtTag, $async = false
}else{
file_put_contents($this->getDataPath() . "players/" . strtolower($name) . ".dat", $nbt->writeCompressed());
}
- }catch(\Exception $e){
+ }catch(\Throwable $e){
$this->logger->critical($this->getLanguage()->translateString("pocketmine.data.saveError", [$name, $e->getMessage()]));
if(\pocketmine\DEBUG > 1 and $this->logger instanceof MainLogger){
$this->logger->logException($e);
@@ -1080,7 +1083,7 @@ public function loadLevel($name){
try{
$level = new Level($this, $name, $path, $provider);
- }catch(\Exception $e){
+ }catch(\Throwable $e){
$this->logger->error($this->getLanguage()->translateString("pocketmine.level.loadError", [$name, $e->getMessage()]));
if($this->logger instanceof MainLogger){
@@ -1140,7 +1143,7 @@ public function generateLevel($name, $seed = null, $generator = null, $options =
$level->initLevel();
$level->setTickRate($this->baseTickRate);
- }catch(\Exception $e){
+ }catch(\Throwable $e){
$this->logger->error($this->getLanguage()->translateString("pocketmine.level.generateError", [$name, $e->getMessage()]));
if($this->logger instanceof MainLogger){
$this->logger->logException($e);
@@ -1436,10 +1439,18 @@ public function getCommandAliases(){
/**
* @return Server
*/
- public static function getInstance(){
+ public static function getInstance() : Server{
return self::$instance;
}
+ public static function microSleep(int $microseconds){
+ Server::$sleeper->synchronized(function(int $ms){
+ var_dump("Sleeping $ms");
+ Server::$sleeper->wait($ms);
+ var_dump("Finished sleep $ms");
+ }, $microseconds);
+ }
+
/**
* @param \ClassLoader $autoloader
* @param \ThreadedLogger $logger
@@ -1449,6 +1460,7 @@ public static function getInstance(){
*/
public function __construct(\ClassLoader $autoloader, \ThreadedLogger $logger, $filePath, $dataPath, $pluginPath){
self::$instance = $this;
+ self::$sleeper = \ThreadedFactory::create();
$this->autoloader = $autoloader;
$this->logger = $logger;
@@ -1627,7 +1639,6 @@ public function __construct(\ClassLoader $autoloader, \ThreadedLogger $logger, $
register_shutdown_function([$this, "crashDump"]);
$this->queryRegenerateTask = new QueryRegenerateEvent($this, 5);
-
$this->network->registerInterface(new RakLibInterface($this));
$this->pluginManager->loadPlugins($this->pluginPath);
@@ -1986,11 +1997,6 @@ public function reload(){
* Shutdowns the server correctly
*/
public function shutdown(){
- if($this->isRunning){
- $killer = new ServerKiller(90);
- $killer->start();
- $killer->detach();
- }
$this->isRunning = false;
}
@@ -2040,7 +2046,7 @@ public function forceShutdown(){
$this->getLogger()->debug("Closing console");
$this->console->shutdown();
- $this->console->detach();
+ $this->console->kill();
$this->getLogger()->debug("Stopping network interfaces");
foreach($this->network->getInterfaces() as $interface){
@@ -2051,8 +2057,9 @@ public function forceShutdown(){
$this->memoryManager->doObjectCleanup();
gc_collect_cycles();
- }catch(\Exception $e){
+ }catch(\Throwable $e){
$this->logger->emergency("Crashed while crashing, killing process");
+ $this->logger->emergency(get_class($e) . ": ". $e->getMessage());
@kill(getmypid());
}
@@ -2110,7 +2117,7 @@ public function handleSignal($signo){
}
}
- public function exceptionHandler(\Exception $e, $trace = null){
+ public function exceptionHandler(\Throwable $e, $trace = null){
if($e === null){
return;
}
@@ -2165,7 +2172,7 @@ public function crashDump(){
$this->logger->emergency($this->getLanguage()->translateString("pocketmine.crash.create"));
try{
$dump = new CrashDump($this);
- }catch(\Exception $e){
+ }catch(\Throwable $e){
$this->logger->critical($this->getLanguage()->translateString("pocketmine.crash.error", $e->getMessage()));
return;
}
@@ -2225,7 +2232,7 @@ private function tickProcessor(){
if($next > microtime(true)){
try{
time_sleep_until($next);
- }catch(\Exception $e){
+ }catch(\Throwable $e){
//Sometimes $next is less than the current time. High load?
}
}
@@ -2344,7 +2351,7 @@ private function checkTickUpdates($currentTick, $tickTime){
$level->tickRateCounter = $level->getTickRate();
}
}
- }catch(\Exception $e){
+ }catch(\Throwable $e){
$this->logger->critical($this->getLanguage()->translateString("pocketmine.level.tickError", [$level->getName(), $e->getMessage()]));
if(\pocketmine\DEBUG > 1 and $this->logger instanceof MainLogger){
$this->logger->logException($e);
@@ -2439,7 +2446,7 @@ public function handlePacket($address, $port, $payload){
if(strlen($payload) > 2 and substr($payload, 0, 2) === "\xfe\xfd" and $this->queryHandler instanceof QueryHandler){
$this->queryHandler->handle($address, $port, $payload);
}
- }catch(\Exception $e){
+ }catch(\Throwable $e){
if(\pocketmine\DEBUG > 1){
if($this->logger instanceof MainLogger){
$this->logger->logException($e);
@@ -2497,7 +2504,7 @@ private function tick(){
if($this->queryHandler !== null){
$this->queryHandler->regenerateInfo();
}
- }catch(\Exception $e){
+ }catch(\Throwable $e){
if($this->logger instanceof MainLogger){
$this->logger->logException($e);
}
@@ -51,7 +51,7 @@ public function registerClassLoader(){
}
}
- public function start($options = PTHREADS_INHERIT_ALL){
+ public function start(int $options = PTHREADS_INHERIT_ALL){
ThreadManager::getInstance()->add($this);
if(!$this->isRunning() and !$this->isJoined() and !$this->isTerminated()){
@@ -70,16 +70,14 @@ public function start($options = PTHREADS_INHERIT_ALL){
public function quit(){
if($this->isRunning()){
$this->kill();
- $this->detach();
}elseif(!$this->isJoined()){
if(!$this->isTerminated()){
$this->join();
}else{
$this->kill();
- $this->detach();
}
}else{
- $this->detach();
+ $this->kill();
}
ThreadManager::getInstance()->remove($this);
@@ -51,7 +51,7 @@ public function registerClassLoader(){
}
}
- public function start($options = PTHREADS_INHERIT_ALL){
+ public function start(int $options = PTHREADS_INHERIT_ALL){
ThreadManager::getInstance()->add($this);
if(!$this->isRunning() and !$this->isJoined() and !$this->isTerminated()){
@@ -71,16 +71,14 @@ public function quit(){
if($this->isRunning()){
$this->unstack();
$this->kill();
- $this->detach();
}elseif(!$this->isJoined()){
if(!$this->isTerminated()){
$this->join();
}else{
$this->kill();
- $this->detach();
}
}else{
- $this->detach();
+ $this->kill();
}
ThreadManager::getInstance()->remove($this);
@@ -86,7 +86,9 @@ public function run(){
if(($line = $this->readLine()) !== ""){
$this->buffer[] = preg_replace("#\\x1b\\x5b([^\\x1b]*\\x7e|[\\x40-\\x50])#", "", $line);
}elseif(!$this->shutdown and (microtime(true) - $lastLine) <= 0.1){ //Non blocking! Sleep to save CPU
- usleep(10000);
+ $this->synchronized(function(){
+ $this->wait(10000);
+ });
}
$lastLine = microtime(true);
@@ -46,7 +46,7 @@ public function execute(CommandSender $sender, $commandLabel, array $args){
foreach($this->formatStrings as $formatString){
try{
$commands[] = $this->buildCommand($formatString, $args);
- }catch(\Exception $e){
+ }catch(\Throwable $e){
if($e instanceof \InvalidArgumentException){
$sender->sendMessage(TextFormat::RED . $e->getMessage());
}else{
@@ -193,7 +193,7 @@ public function dispatch(CommandSender $sender, $commandLine){
$target->timings->startTiming();
try{
$target->execute($sender, $sentCommandLabel, $args);
- }catch(\Exception $e){
+ }catch(\Throwable $e){
$sender->sendMessage(new TranslationContainer(TextFormat::RED . "%commands.generic.exception"));
$this->server->getLogger()->critical($this->server->getLanguage()->translateString("pocketmine.command.exception", [$commandLine, (string) $target, $e->getMessage()]));
$logger = $sender->getServer()->getLogger();
@@ -66,7 +66,7 @@ public function execute(CommandSender $sender, $currentAlias, array $args){
$data = implode(" ", array_slice($args, 3));
try{
$tags = NBT::parseJSON($data);
- }catch (\Exception $ex){
+ }catch (\Throwable $ex){
$exception = $ex;
}
Oops, something went wrong.

20 comments on commit e137ac4

@shoghicp
Member

Forgot to say that Weakref is not supported, so if you try to use permissions, attachments or metadata it'll crash (although you should be happy that it did not crash until that point!)

@MattWAnderson

Thanks for this "Experimental" Just as an FYI for anyone else looking to install this. On CentOS I needed to install bison as well as the expected GCC.

@shoghicp
Member

@HostingItAll Yeah, this requires more stuff as this is building from the git sources instead of the packaged version.

I've also updated the compile script with a new version + last branch commit 922e9d9

@Guillaume351

@shoghicp Does it stil crash after a few seconds ? Or only if we do something that is Weakref related ?

@shoghicp
Member

seems to work okayish
I generated terrain for a few minutes and did not crash, I had to bump the limits because I was not using 100% CPU there, now I can't catch up with the generation :(

@Reddigirl

Could you just give us a working PHP7 PocketMine bin directory? 😄 And an updated start.sh :D

@iVertx
iVertx commented on e137ac4 Sep 11, 2015

Here, on ubuntu 12.04 LTS 64 bits, i'm getting the "zend_mm_heap corrupted" error after few seconds, no mather if i join on the server or if I simply wait for that to happen

Maybe a opcache related issue?

@PEMapModder
Collaborator

@Reddigirl this is not a forum.

@MattWAnderson

@reddigirl It isn't to the point where it would be for general consumption. :)

zend_mm_heap corrupted is also what I am experiencing on CentOS 6.5 x64. I have been able to start the server with no customization, run the client & join the world. Crashing happens within 30 seconds. Tested setting opcache to not be enabled via the phpconfig file same results.

When joining with client I am unable to select any blocks.

@64FF00
Contributor
64FF00 commented on e137ac4 Sep 11, 2015

@shoghicp 'Store under direct sunlight for the best performance' 👍

@shoghicp
Member

@HostingItAll test the new compile.sh and latest commit.

@MattWAnderson

Latest compile:

Build 19:

[15:03:05] [Server thread/CRITICAL]: Unable to find the Weakref extension.

[15:03:05] [Server thread/CRITICAL]: Please use the installer provided on the homepage, or recompile PHP again.

Build 18:

[15:00:30] [Server thread/CRITICAL]: ParseError: "syntax error, unexpected ')'" (EXCEPTION) in "/src/pocketmine/utils/BinaryStream__64bit" at line 197

[15:00:30] [Server thread/EMERGENCY]: An unrecoverable error has occurred and the server has crashed. Creating a crash dump

[15:00:30] [Server thread/EMERGENCY]: Please upload the "/home/tcagame/Admin/732/CrashDump_Fri_Sep_11-15.00.30-UTC_2015.log" file to the Crash Archive and submit the link to the Bug Reporting page. Give as much info as you can.

[15:00:30] [Server thread/EMERGENCY]: Crashed while crashing, killing process

[15:00:30] [Server thread/EMERGENCY]: Error: Call to a member function disablePlugins() on null

ERROR DUMP:
PocketMine-MP Crash Dump Fri Sep 11 15:01:56 UTC 2015

Error: syntax error, unexpected ')'
File: /src/pocketmine/utils/BinaryStream__64bit
Line: 197
Type: notice

Code:
[188] public function getUUID(){
[189] return UUID::fromBinary($this->get(16));
[190] }
[191]
[192] public function putUUID(UUID $uuid){
[193] $this->buffer .= $uuid->toBinary();
[194] }
[195]
[196] public function getSlot(){
[197] $id = \true);
[198]
[199] if($id <= 0){
[200] return Item::get(0, 0, 0);
[201] }
[202]
[203] $cnt = \ord($this->get(1));
[204]
[205] $data = \unpack("n", $this->get(2))[1];
[206]
[207] $nbtLen = \unpack("n", $this->get(2))[1];

Backtrace:
#0 /src/pocketmine/network/protocol/DataPacket(41): spl_autoload_call(string pocketmine\utils\BinaryStream)
#1 /src/spl/BaseClassLoader(128): include(string phar:///home/tcagame/Admin/732/PocketMine-MP.phar/src/pocketmine/network/protocol/DataPacket.php)
#2 (): BaseClassLoader->loadClass(string pocketmine\network\protocol\DataPacket)
#3 /src/pocketmine/network/protocol/LoginPacket__64bit(36): spl_autoload_call(string pocketmine\network\protocol\DataPacket)
#4 /src/spl/BaseClassLoader(128): include(string phar:///home/tcagame/Admin/732/PocketMine-MP.phar/src/pocketmine/network/protocol/LoginPacket__64bit.php)
#5 (): BaseClassLoader->loadClass(string pocketmine\network\protocol\LoginPacket)
#6 /src/pocketmine/network/Network__64bit(222): spl_autoload_call(string pocketmine\network\protocol\LoginPacket)
#7 /src/pocketmine/network/Network__64bit(308): pocketmine\network\Network->registerPacket(integer 143, string pocketmine\network\protocol\LoginPacket)
#8 /src/pocketmine/network/Network__64bit(125): pocketmine\network\Network->registerPackets(boolean)
#9 /src/pocketmine/Server__64bit(1600): pocketmine\network\Network->__construct(pocketmine\Server object)
#10 /src/pocketmine/PocketMine(465): pocketmine\Server->__construct(pocketmine\CompatibleClassLoader object, pocketmine\utils\MainLogger object, string phar:///home/tcagame/Admin/732/PocketMine-MP.phar/, string /home/tcagame/Admin/732/, string /home/tcagame/Admin/732/plugins/)
#11 (1): require(string phar:///home/tcagame/Admin/732/PocketMine-MP.phar/src/pocketmine/PocketMine.php)

PocketMine-MP version: 1.6dev #18 [Protocol 34; API 2.0.0]
Git commit: 0000000000000000000000000000000000000000
uname -a: Linux Zulu.HostingItAll.com 3.10.23-xxxx-std-ipv6-64 #1 SMP Tue Mar 18 14:48:24 CET 2014 x86_64
PHP Version: 7.0.0RC2
Zend version: 3.0.0-dev
OS : Linux, linux

----------------------REPORT THE DATA BELOW THIS LINE-----------------------

===BEGIN CRASH DUMP===
eNrtWm1v20a2/isDpUDtC1ESJVm21XWwWTfZDZA0vnWCAlsVxogcSqzJGZYztKwW+e/3OWeGEq04
bW5TYPdDgqARh2fO25yX5wz7W8/lperN4+k0Pj+bnMazfq+Q1j2va1P35r/13LbC6542Lk9Ur98r
lbVyRUt2q528F4oo+6LR6r5SiVOp+Pr4axBmTVG8yAuirNayng+Hw7Up1dAlciXx77O0zPXwdDIe
XpnkVrnXuVbR66sBEQ9tnQwrXgaRGjYuL+zwH7mW9fba1UqWNzez6TJ3oK5IlpfzyduwpQABzD4/
7fdcLWHa/Mfek5E4ZKGV25j6dljVxpnEFMNvpZNXkt4fTePjubBVcSMbZwoj05tEFsWRdXWuV2LP
ZLFgRRaLribH0OFJ7OWBx/Af0qpLeN6+AiNVH8XjM3DPdVI0qdrx/FxH/o455EpWaiyOIPlAn+gp
GcgLjxkY+C4WLePFYs+ZuU7+2LWvzCrXfks4p6PJ7FNd/McaTP/jzv7QwJ3TT/4ap3ckMNvZR73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r2
dj7+5rR/cn4f9yf3k/74m/ibFJ3YV60jVys8oMJcnI3ECvFt/dP05Jgvt9W9U5ocYul71CX60MNP
NRRFD1eq5JDG/lLkTk38t6XwPedX/7GpQ7VMAG3WD9foAlWnsj5YDf8LUXepqYuHK1leIPoP1tzB
h6ZVevBcHhCskfD89Y2+iP1sw6e4KT+WS3/9+3AHsOS2cgcOcJKsOBB2ffXq0HMAhAfctnAefwwL
v8QJXsZj8qKI+PPUaDo6xc+vXiICTtXpODufnY+W8fT8TMZLjA2ncjY5TSYTeTaJk1E6zmYnJ+Ir
8L5as2PpiyFLNza/P1AozP7hW1yMpe9VFubWAxPXpTnwneUktI8YlD9cc+ZWaXSng9PaSv6aEg/G
g1iS7F/zip9jKOOj6N/UCN5ccSMKm2fkmhfPe+/f/x+vpO1b
===END CRASH DUMP===

@shoghicp
Member

you are not using the source, but a .phar

@MattWAnderson

Correct, the latest (19) on Jenkins.

I grabbed the SPL and Raklib from build 19 and used the pocketmine from the 0.12 branch and receive:

[16:16:17] [Server thread/CRITICAL]: Unable to find the Weakref extension.

[16:16:17] [Server thread/CRITICAL]: Please use the installer provided on the homepage, or recompile PHP again.

@shoghicp
Member

@HostingItAll don't use jenkins. run from source, and php7 branch

@MattWAnderson

Server runs on that branch, still issues with choosing blocks.using php7 Build and Raklib & spl from the jenkins build using src.

I plan to leave it running to see, let me know if you want me to test anything directly.

pretty basic for info:

[16:23:46] [Server thread/INFO]: /seed: %pocketmine.command.seed.description

[16:23:46] [Server thread/INFO]: /setworldspawn: %pocketmine.command.setworldspawn.description

[16:23:46] [Server thread/INFO]: /spawnpoint: %pocketmine.command.spawnpoint.description

[16:23:46] [Server thread/INFO]: /stop: %pocketmine.command.stop.description

[16:23:46] [Server thread/INFO]: /tell: %pocketmine.command.tell.description

[16:23:46] [Server thread/INFO]: /time: %pocketmine.command.time.description

[16:23:46] [Server thread/INFO]: /timings: %pocketmine.command.timings.description

[16:23:46] [Server thread/INFO]: /tp: %pocketmine.command.tp.description

[16:23:46] [Server thread/INFO]: /version: %pocketmine.command.version.description

[16:23:46] [Server thread/INFO]: /whitelist: %pocketmine.command.whitelist.description

[16:23:48] [Server thread/INFO]: commands.players.list

[16:23:48] [Server thread/INFO]:

[16:25:11] [Server thread/INFO]: pocketmine.player.logIn

[16:25:28] [Server thread/INFO]: %multiplayer.player.joined

[16:25:50] [Server thread/INFO]: %multiplayer.player.left

[16:25:50] [Server thread/INFO]: pocketmine.player.logOut

@shoghicp
Member

@HostingItAll This doesn't fix anything. this is the php7 branch, nothing else. Also seems like you did not do git submodule update --init

@iVertx
iVertx commented on e137ac4 Sep 11, 2015

↑ *submodule

Yep, I got that working few minutes after making my comment, I just forget to run the source instead of the phar...

Tree things that I noted on the server after some tests:

  • Many people already said that but creative items can't be picked-up from inventory, an basic issue
  • MCPE Light updates issue still there, some levels heavy modified by world editors haven't a properly light population, and due to the high speed of chunk loading now, the client freezes constantly while updating lights... Can be solved setting a low view distance but that isn't the point, maybe a pocketmine function for auto-correction of level's light population can solve that, but this is an issue for another branch.
  • And some blocks of old levels are bugged or being interpreted bad from mcpe client, for example trapdors that aren't on the right position

Just a question, I've made a plugin that uses an interface for inheriting with some classes, should now I use scalar type hints on that classes or just on interface or on both for a good performance? Just a small doubt...

@shoghicp
Member

@iVertx As I said, this doesn't introduce bugfixes, it's just PHP7 support.

I'll be working on scalar type hints through all the core later and do tests with them :)

@iVertx
iVertx commented on e137ac4 Sep 11, 2015

Alright, thank you!

Please sign in to comment.