Hotfix message and auto abort
Signed-off-by: Lixfel <agga-games@gmx.de>
Dieser Commit ist enthalten in:
Ursprung
d6690736a4
Commit
445bbc6824
@ -1,6 +1,9 @@
|
||||
package de.steamwar.bungeecore.listeners;
|
||||
|
||||
import de.steamwar.bungeecore.Bauserver;
|
||||
import de.steamwar.bungeecore.BungeeCore;
|
||||
import de.steamwar.bungeecore.Servertype;
|
||||
import de.steamwar.bungeecore.Subserver;
|
||||
import de.steamwar.bungeecore.commands.CheckCommand;
|
||||
import de.steamwar.bungeecore.sql.Schematic;
|
||||
import de.steamwar.bungeecore.sql.SchematicType;
|
||||
@ -34,9 +37,16 @@ public class CheckListener extends BasicListener {
|
||||
@EventHandler
|
||||
public void onServerSwitch(ServerSwitchEvent e){
|
||||
ProxiedPlayer player = e.getPlayer();
|
||||
if(CheckCommand.isChecking(player))
|
||||
if(CheckCommand.isChecking(player)){
|
||||
Subserver server = Subserver.getSubserver(player.getServer().getInfo());
|
||||
if(
|
||||
server == null ||
|
||||
server.getType() != Servertype.BAUSERVER ||
|
||||
((Bauserver)server).getOwner() != player.getUniqueId()
|
||||
)
|
||||
CheckCommand.abort(player);
|
||||
}
|
||||
}
|
||||
|
||||
@EventHandler
|
||||
public void onPlayerDisconnect(PlayerDisconnectEvent e){
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren