mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-04-22 00:33:59 +00:00
SubChunk: Fixed constant redefinition on worker threads when autoloading
this happens when workers inherit constants but not classes.
This commit is contained in:
parent
f8bfbc107d
commit
a02f422d85
@ -23,7 +23,11 @@ declare(strict_types=1);
|
||||
|
||||
namespace pocketmine\level\format;
|
||||
|
||||
define(__NAMESPACE__ . '\ZERO_NIBBLE_ARRAY', str_repeat("\x00", 2048));
|
||||
$name = __NAMESPACE__ . '\ZERO_NIBBLE_ARRAY';
|
||||
if(!defined($name)){
|
||||
define($name, str_repeat("\x00", 2048));
|
||||
}
|
||||
unset($name);
|
||||
|
||||
class SubChunk implements SubChunkInterface{
|
||||
protected $ids;
|
||||
|
Loading…
x
Reference in New Issue
Block a user