mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-06-04 11:02:29 +00:00
Fixed T_DOUBLE_COLON
This commit is contained in:
parent
3e1ea23036
commit
ee7d84dfbd
@ -485,8 +485,8 @@ class Item{
|
||||
$meta = ((int) $b[1]) & 0xFFFF;
|
||||
}
|
||||
|
||||
if(defined(Item::class . T_DOUBLE_COLON . strtoupper($b[0]))){
|
||||
$item = self::get(constant(Item::class . T_DOUBLE_COLON . strtoupper($b[0])), $meta);
|
||||
if(defined(Item::class . "::" . strtoupper($b[0]))){
|
||||
$item = self::get(constant(Item::class . "::" . strtoupper($b[0])), $meta);
|
||||
if($item->getID() === self::AIR and strtoupper($b[0]) !== "AIR"){
|
||||
$item = self::get(((int) $b[0]) & 0xFFFF, $meta);
|
||||
}
|
||||
|
@ -95,12 +95,12 @@ class PluginDescription{
|
||||
}
|
||||
if(isset($plugin["load"])){
|
||||
$order = strtoupper($plugin["load"]);
|
||||
if(!defined(PluginLoadOrder::class . T_DOUBLE_COLON . $order)){
|
||||
if(!defined(PluginLoadOrder::class . "::" . $order)){
|
||||
trigger_error("Invalid PluginDescription load", E_USER_ERROR);
|
||||
|
||||
return;
|
||||
}else{
|
||||
$this->order = constant(PluginLoadOrder::class . T_DOUBLE_COLON . $order);
|
||||
$this->order = constant(PluginLoadOrder::class . "::" . $order);
|
||||
}
|
||||
}
|
||||
$this->authors = [];
|
||||
|
@ -676,8 +676,8 @@ class PluginManager{
|
||||
$ignoreCancelled = false;
|
||||
if(preg_match("/^[\t ]*\\* @priority[\t ]{1,}([a-zA-Z]{1,})$/m", (string) $method->getDocComment(), $matches) > 0){
|
||||
$matches[1] = strtoupper($matches[1]);
|
||||
if(defined(EventPriority::class . T_DOUBLE_COLON . $matches[1])){
|
||||
$priority = constant(EventPriority::class . T_DOUBLE_COLON . $matches[1]);
|
||||
if(defined(EventPriority::class . "::" . $matches[1])){
|
||||
$priority = constant(EventPriority::class . "::" . $matches[1]);
|
||||
}
|
||||
}
|
||||
if(preg_match("/^[\t ]*\\* @ignoreCancelled[\t ]{1,}([a-zA-Z]{1,})$/m", (string) $method->getDocComment(), $matches) > 0){
|
||||
|
Loading…
x
Reference in New Issue
Block a user