mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-07-01 07:39:57 +00:00
Fixed handlerPriority order
This commit is contained in:
parent
755cafa600
commit
89a0e84404
@ -106,6 +106,7 @@ abstract class BaseEvent{
|
|||||||
static::$handlers[$identifier] = $handler;
|
static::$handlers[$identifier] = $handler;
|
||||||
if(!isset(static::$handlerPriority[(int) $priority])){
|
if(!isset(static::$handlerPriority[(int) $priority])){
|
||||||
static::$handlerPriority[(int) $priority] = array();
|
static::$handlerPriority[(int) $priority] = array();
|
||||||
|
krsort(static::$handlerPriority);
|
||||||
}
|
}
|
||||||
static::$handlerPriority[(int) $priority][$identifier] = $handler;
|
static::$handlerPriority[(int) $priority][$identifier] = $handler;
|
||||||
return true;
|
return true;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user