Merge branch 'master' of ssh://184.154.0.242:7999/min/mineplex
This commit is contained in:
commit
d125bf8e8e
@ -54,4 +54,9 @@ public abstract class Perk implements Listener
|
|||||||
{
|
{
|
||||||
//Null Default
|
//Null Default
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void registeredEvents()
|
||||||
|
{
|
||||||
|
// When listener has been registered
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -307,7 +307,7 @@ public class GameManager implements Listener
|
|||||||
event.GetGame().RegisterKits();
|
event.GetGame().RegisterKits();
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler
|
@EventHandler(priority = EventPriority.HIGH)
|
||||||
public void KitDeregister(GameStateChangeEvent event)
|
public void KitDeregister(GameStateChangeEvent event)
|
||||||
{
|
{
|
||||||
if (event.GetState() != GameState.Dead)
|
if (event.GetState() != GameState.Dead)
|
||||||
|
@ -11,6 +11,7 @@ namespace mineplex\plugin\gameengine\game\components\world;
|
|||||||
use mineplex\plugin\gameengine\arenas\Arena;
|
use mineplex\plugin\gameengine\arenas\Arena;
|
||||||
use mineplex\plugin\gameengine\game\components\world\event\WorldLoadFailEvent;
|
use mineplex\plugin\gameengine\game\components\world\event\WorldLoadFailEvent;
|
||||||
use mineplex\plugin\gameengine\game\components\world\event\WorldLoadSuccessEvent;
|
use mineplex\plugin\gameengine\game\components\world\event\WorldLoadSuccessEvent;
|
||||||
|
use mineplex\plugin\util\UtilArray;
|
||||||
use mineplex\plugin\util\UtilString;
|
use mineplex\plugin\util\UtilString;
|
||||||
use pocketmine\event\Listener;
|
use pocketmine\event\Listener;
|
||||||
use pocketmine\level\Position;
|
use pocketmine\level\Position;
|
||||||
@ -231,27 +232,35 @@ class WorldComponent implements Listener
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return Position[][]
|
||||||
|
*/
|
||||||
public function getTeams()
|
public function getTeams()
|
||||||
{
|
{
|
||||||
return $this->mapTeams;
|
return $this->mapTeams;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param $key
|
||||||
|
* @return int
|
||||||
|
*/
|
||||||
public function getSetting($key)
|
public function getSetting($key)
|
||||||
{
|
{
|
||||||
return $this->mapSettings[$key];
|
return $this->mapSettings[$key];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param $key
|
||||||
|
* @return Position[]
|
||||||
|
*/
|
||||||
public function getData($key)
|
public function getData($key)
|
||||||
{
|
{
|
||||||
return $this->mapData[$key];
|
if (UtilArray::hasKey($key, $this->mapData))
|
||||||
}
|
return $this->mapData[$key];
|
||||||
|
|
||||||
public function getPosition()
|
return [];
|
||||||
{
|
|
||||||
return $this->getTeams()[0][0];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
protected function strToPos($str)
|
protected function strToPos($str)
|
||||||
{
|
{
|
||||||
if (strlen($str) < 5)
|
if (strlen($str) < 5)
|
||||||
|
Loading…
Reference in New Issue
Block a user