Added game start event to core, to be called inside arcade and handled inside core

This commit is contained in:
LCastr0 2017-04-07 14:06:44 -03:00
parent 45e3223962
commit 6a668004e0
6 changed files with 38 additions and 4 deletions

View File

@ -0,0 +1,33 @@
package mineplex.core.arcadeevents;
import org.bukkit.event.Event;
import org.bukkit.event.HandlerList;
public class CoreGameStartEvent extends Event
{
private static final HandlerList handlers = new HandlerList();
private GameType _gameType;
public CoreGameStartEvent(GameType gameType)
{
_gameType = gameType;
}
public GameType getGameType()
{
return _gameType;
}
public HandlerList getHandlers()
{
return handlers;
}
public static HandlerList getHandlerList()
{
return handlers;
}
}

View File

@ -1,4 +1,4 @@
package mineplex.core.gadget.gadgets.taunts; package mineplex.core.arcadeevents;
public enum GameType public enum GameType
{ {

View File

@ -5,7 +5,7 @@ import org.bukkit.event.Event;
import org.bukkit.event.HandlerList; import org.bukkit.event.HandlerList;
import mineplex.core.common.util.UtilTime; import mineplex.core.common.util.UtilTime;
import mineplex.core.gadget.gadgets.taunts.GameType; import mineplex.core.arcadeevents.GameType;
public class TauntCommandEvent extends Event public class TauntCommandEvent extends Event
{ {

View File

@ -18,6 +18,7 @@ import org.bukkit.event.player.PlayerJoinEvent;
import org.bukkit.event.player.PlayerPickupItemEvent; import org.bukkit.event.player.PlayerPickupItemEvent;
import org.bukkit.util.Vector; import org.bukkit.util.Vector;
import mineplex.core.arcadeevents.GameType;
import mineplex.core.common.Rank; import mineplex.core.common.Rank;
import mineplex.core.common.util.C; import mineplex.core.common.util.C;
import mineplex.core.common.util.F; import mineplex.core.common.util.F;

View File

@ -13,7 +13,7 @@ import org.bukkit.entity.Player;
import org.bukkit.event.EventHandler; import org.bukkit.event.EventHandler;
import mineplex.core.gadget.GadgetManager; import mineplex.core.gadget.GadgetManager;
import mineplex.core.gadget.gadgets.taunts.GameType; import mineplex.core.arcadeevents.GameType;
import mineplex.core.updater.UpdateType; import mineplex.core.updater.UpdateType;
import mineplex.core.updater.event.UpdateEvent; import mineplex.core.updater.event.UpdateEvent;

View File

@ -9,7 +9,7 @@ import mineplex.core.common.Rank;
import mineplex.core.common.util.UtilPlayer; import mineplex.core.common.util.UtilPlayer;
import mineplex.core.common.util.UtilTime; import mineplex.core.common.util.UtilTime;
import mineplex.core.gadget.event.TauntCommandEvent; import mineplex.core.gadget.event.TauntCommandEvent;
import mineplex.core.gadget.gadgets.taunts.GameType; import mineplex.core.arcadeevents.GameType;
import mineplex.minecraft.game.core.combat.CombatManager; import mineplex.minecraft.game.core.combat.CombatManager;
import nautilus.game.arcade.ArcadeManager; import nautilus.game.arcade.ArcadeManager;