code cleanup
Signed-off-by: yaruma3341 <yaruma3341@gmail.com>
Dieser Commit ist enthalten in:
Ursprung
5c3890d438
Commit
6218235875
@ -78,13 +78,20 @@ public class SchematicCommand implements CommandExecutor {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if(args[0].equalsIgnoreCase("load")) {
|
if(args[0].equalsIgnoreCase("load")) {
|
||||||
if(CheckUtils.isSchematicNameAllowed(args[1])) {
|
if(!CheckUtils.isSchematicNameAllowed(args[1])) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDer angegebene Schematicname enthält verbotene Zeichen!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
Schematic schematic = Schematic.getSchemFromDB(args[1], player.getUniqueId());
|
Schematic schematic = Schematic.getSchemFromDB(args[1], player.getUniqueId());
|
||||||
|
|
||||||
if(schematic == null)
|
if(schematic == null)
|
||||||
schematic = Schematic.getSchemFromDB(args[1], 0); //public schematic
|
schematic = Schematic.getSchemFromDB(args[1], 0); //public schematic
|
||||||
|
|
||||||
if (schematic != null) {
|
if (schematic == null) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDie angegebene Schematic existiert nicht!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
Actor actor = SchematicSystem.getWorldEditPlugin().wrapCommandSender(player);
|
Actor actor = SchematicSystem.getWorldEditPlugin().wrapCommandSender(player);
|
||||||
@ -106,23 +113,24 @@ public class SchematicCommand implements CommandExecutor {
|
|||||||
} catch (IOException ex) {
|
} catch (IOException ex) {
|
||||||
ex.printStackTrace();
|
ex.printStackTrace();
|
||||||
}
|
}
|
||||||
|
|
||||||
return false;
|
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDie angegebene Schematic existiert nicht!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDer angegebene Schematicname enthält verbotene Zeichen!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if(args[0].equalsIgnoreCase("delete")) {
|
if(args[0].equalsIgnoreCase("delete")) {
|
||||||
if(CheckUtils.isSchematicNameAllowed(args[1])) {
|
if(!CheckUtils.isSchematicNameAllowed(args[1])) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDer angegebene Schematicname enthält verbotene Zeichen!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
Schematic schematic = Schematic.getSchemFromDB(args[1], player.getUniqueId());
|
Schematic schematic = Schematic.getSchemFromDB(args[1], player.getUniqueId());
|
||||||
if(schematic != null) {
|
if(schematic == null) {
|
||||||
if(WarkingUser.get(schematic.getSchemOwner()).getUUID().equals(player.getUniqueId())) {
|
player.sendMessage(SchematicSystem.PREFIX + "§cDiese Schematic existiert nicht!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(!WarkingUser.get(schematic.getSchemOwner()).getUUID().equals(player.getUniqueId())) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cZum Löschen musst du der Owner der Schematic sein!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
TextComponent message = new TextComponent("§6Möchtest du die Schematic wirklich löschen?");
|
TextComponent message = new TextComponent("§6Möchtest du die Schematic wirklich löschen?");
|
||||||
message.setBold(true);
|
message.setBold(true);
|
||||||
@ -136,25 +144,25 @@ public class SchematicCommand implements CommandExecutor {
|
|||||||
player.spigot().sendMessage(message);
|
player.spigot().sendMessage(message);
|
||||||
player.spigot().sendMessage(ja);
|
player.spigot().sendMessage(ja);
|
||||||
return false;
|
return false;
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cZum Löschen musst du der Owner der Schematic sein!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDiese Schematic existiert nicht!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDer angegebene Schematicname enthält verbotene Zeichen!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if(args[0].equalsIgnoreCase("savedelete")) {
|
if(args[0].equalsIgnoreCase("savedelete")) {
|
||||||
if(CheckUtils.isSchematicNameAllowed(args[1])) {
|
if(!CheckUtils.isSchematicNameAllowed(args[1])) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDer angegebene Schematicname enthält verbotene Zeichen!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
Schematic schematic = Schematic.getSchemFromDB(args[1], player.getUniqueId());
|
Schematic schematic = Schematic.getSchemFromDB(args[1], player.getUniqueId());
|
||||||
if(schematic != null) {
|
if(schematic == null) {
|
||||||
if(WarkingUser.get(schematic.getSchemOwner()).getUUID().equals(player.getUniqueId())) {
|
player.sendMessage(SchematicSystem.PREFIX + "§cDiese Schematic existiert nicht!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(!WarkingUser.get(schematic.getSchemOwner()).getUUID().equals(player.getUniqueId())) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cZum Löschen musst du der Owner der Schematic sein!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
File file = new File(SchematicSystem.SCHEM_DIR + player.getUniqueId() + "/" + args[1] + ".schematic");
|
File file = new File(SchematicSystem.SCHEM_DIR + player.getUniqueId() + "/" + args[1] + ".schematic");
|
||||||
file.delete();
|
file.delete();
|
||||||
schematic.remove();
|
schematic.remove();
|
||||||
@ -168,25 +176,21 @@ public class SchematicCommand implements CommandExecutor {
|
|||||||
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "Schematic §6" + args[1] + " §7gelöscht.");
|
player.sendMessage(SchematicSystem.PREFIX + "Schematic §6" + args[1] + " §7gelöscht.");
|
||||||
return false;
|
return false;
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cZum Löschen musst du der Owner der Schematic sein!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDiese Schematic existiert nicht!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDer angegebene Schematicname enthält verbotene Zeichen!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if(args[0].equalsIgnoreCase("save")) {
|
if(args[0].equalsIgnoreCase("save")) {
|
||||||
|
|
||||||
if(CheckUtils.isSchematicNameAllowed(args[1])) {
|
if(!CheckUtils.isSchematicNameAllowed(args[1])) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDer angegebene Schematicname enthält verbotene Zeichen!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
if(FaweAPI.wrapPlayer(player).getSession().getClipboard().getClipboard() != null) {
|
if(FaweAPI.wrapPlayer(player).getSession().getClipboard().getClipboard() == null) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDein Clipboard ist leer!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
Schematic schematic = Schematic.getSchemFromDB(args[1], player.getUniqueId());
|
Schematic schematic = Schematic.getSchemFromDB(args[1], player.getUniqueId());
|
||||||
if(schematic != null) {
|
if(schematic != null) {
|
||||||
if(schematic.getSchemType() != SchematicType.normal) {
|
if(schematic.getSchemType() != SchematicType.normal) {
|
||||||
@ -229,21 +233,21 @@ public class SchematicCommand implements CommandExecutor {
|
|||||||
player.sendMessage(SchematicSystem.PREFIX + "Schematic §6" + args[1] + " §7gespeichert!");
|
player.sendMessage(SchematicSystem.PREFIX + "Schematic §6" + args[1] + " §7gespeichert!");
|
||||||
}
|
}
|
||||||
|
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDein Clipboard ist leer!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
} catch (IOException ex) { ex.printStackTrace(); } catch (EmptyClipboardException ex) { ex.printStackTrace(); }
|
} catch (IOException ex) { ex.printStackTrace(); } catch (EmptyClipboardException ex) { ex.printStackTrace(); }
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDer angegebene Schematicname enthält verbotene Zeichen!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if(args[0].equalsIgnoreCase("getschemchangetype")) {
|
if(args[0].equalsIgnoreCase("getschemchangetype")) {
|
||||||
if(CheckUtils.isSchematicNameAllowed(args[1])) {
|
if(!CheckUtils.isSchematicNameAllowed(args[1])) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDer angegebene Schematicname enthält verbotene Zeichen!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
Schematic schematic = Schematic.getSchemFromDB(args[1], player.getUniqueId());
|
Schematic schematic = Schematic.getSchemFromDB(args[1], player.getUniqueId());
|
||||||
if(schematic != null) {
|
if(schematic == null) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDiese Schematic existiert nicht!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
TextComponent normal = new TextComponent("§7[§anormal§7]");
|
TextComponent normal = new TextComponent("§7[§anormal§7]");
|
||||||
normal.setClickEvent(new ClickEvent(ClickEvent.Action.RUN_COMMAND, "/schem changetype " + schematic.getSchemName() + " normal"));
|
normal.setClickEvent(new ClickEvent(ClickEvent.Action.RUN_COMMAND, "/schem changetype " + schematic.getSchemName() + " normal"));
|
||||||
|
|
||||||
@ -264,20 +268,20 @@ public class SchematicCommand implements CommandExecutor {
|
|||||||
player.spigot().sendMessage(miniwargear);
|
player.spigot().sendMessage(miniwargear);
|
||||||
player.spigot().sendMessage(airship);
|
player.spigot().sendMessage(airship);
|
||||||
player.spigot().sendMessage(warship);
|
player.spigot().sendMessage(warship);
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDiese Schematic existiert nicht!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDer angegebene Schematicname enthält verbotene Zeichen!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if(args[0].equalsIgnoreCase("getmoreinfo")) {
|
if(args[0].equalsIgnoreCase("getmoreinfo")) {
|
||||||
if(CheckUtils.isSchematicNameAllowed(args[1])) {
|
if(!CheckUtils.isSchematicNameAllowed(args[1])) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDer angegebene Schematicname enthält verbotene Zeichen!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
Schematic schematic = Schematic.getSchemFromDB(args[1], player.getUniqueId());
|
Schematic schematic = Schematic.getSchemFromDB(args[1], player.getUniqueId());
|
||||||
if(schematic != null) {
|
if(schematic == null) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDiese Schematic existiert nicht!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
List<CheckedSchematic> checkedSchematics = CheckedSchematic.getLastDeclined(player.getUniqueId());
|
List<CheckedSchematic> checkedSchematics = CheckedSchematic.getLastDeclined(player.getUniqueId());
|
||||||
for(CheckedSchematic checkedSchematic : checkedSchematics) {
|
for(CheckedSchematic checkedSchematic : checkedSchematics) {
|
||||||
if(checkedSchematic.getSchemName().equals(schematic.getSchemName()) &&
|
if(checkedSchematic.getSchemName().equals(schematic.getSchemName()) &&
|
||||||
@ -288,27 +292,27 @@ public class SchematicCommand implements CommandExecutor {
|
|||||||
player.sendMessage("§bGrund: " + checkedSchematic.getDeclineReason());
|
player.sendMessage("§bGrund: " + checkedSchematic.getDeclineReason());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDiese Schematic existiert nicht!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDer angegebene Schematicname enthält verbotene Zeichen!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
case 3:
|
case 3:
|
||||||
if(args[0].equalsIgnoreCase("info")) {
|
if(args[0].equalsIgnoreCase("info")) {
|
||||||
if(CheckUtils.isSchematicNameAllowed(args[1])) {
|
if(!CheckUtils.isSchematicNameAllowed(args[1])) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDer angegebene Schematicname enthält verbotene Zeichen!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
WarkingUser warkingUser = WarkingUser.get(Integer.valueOf(args[2]));
|
WarkingUser warkingUser = WarkingUser.get(Integer.valueOf(args[2]));
|
||||||
if(warkingUser.getUUID() == null) {
|
if(warkingUser.getUUID() == null) {
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDieser Benutzer hat keine Schematic mit diesem Namen!");
|
player.sendMessage(SchematicSystem.PREFIX + "§cDieser Benutzer hat keine Schematic mit diesem Namen!");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
Schematic schematic = Schematic.getSchemFromDB(args[1], warkingUser.getId());
|
Schematic schematic = Schematic.getSchemFromDB(args[1], warkingUser.getId());
|
||||||
if(schematic != null) {
|
if(schematic == null) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDiese Schematic existiert nicht!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
player.sendMessage("§6Name: §7" + schematic.getSchemName());
|
player.sendMessage("§6Name: §7" + schematic.getSchemName());
|
||||||
|
|
||||||
@ -360,14 +364,6 @@ public class SchematicCommand implements CommandExecutor {
|
|||||||
player.spigot().sendMessage(deleteSchematic);
|
player.spigot().sendMessage(deleteSchematic);
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDiese Schematic existiert nicht!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDer angegebene Schematicname enthält verbotene Zeichen!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if(args[0].equalsIgnoreCase("list")) {
|
if(args[0].equalsIgnoreCase("list")) {
|
||||||
@ -385,7 +381,11 @@ public class SchematicCommand implements CommandExecutor {
|
|||||||
|
|
||||||
if(args[0].equalsIgnoreCase("changetype")) {
|
if(args[0].equalsIgnoreCase("changetype")) {
|
||||||
Schematic schematic = Schematic.getSchemFromDB(args[1], player.getUniqueId());
|
Schematic schematic = Schematic.getSchemFromDB(args[1], player.getUniqueId());
|
||||||
if(schematic != null) {
|
if(schematic == null) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDiese Schematic existiert nicht!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
Clipboard clipboard;
|
Clipboard clipboard;
|
||||||
try {
|
try {
|
||||||
clipboard = FaweAPI.load(new File(SchematicSystem.SCHEM_DIR + player.getUniqueId() + "/" + args[1] + ".schematic")).getClipboard();
|
clipboard = FaweAPI.load(new File(SchematicSystem.SCHEM_DIR + player.getUniqueId() + "/" + args[1] + ".schematic")).getClipboard();
|
||||||
@ -481,17 +481,21 @@ public class SchematicCommand implements CommandExecutor {
|
|||||||
}
|
}
|
||||||
player.sendMessage("§8/schem changetype <Name> <airship/warship/miniwargear/wargear/normal>");
|
player.sendMessage("§8/schem changetype <Name> <airship/warship/miniwargear/wargear/normal>");
|
||||||
|
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDiese Schematic existiert nicht!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(args[0].equalsIgnoreCase("addmember")) {
|
if(args[0].equalsIgnoreCase("addmember")) {
|
||||||
if(CheckUtils.isSchematicNameAllowed(args[1])) {
|
if(!CheckUtils.isSchematicNameAllowed(args[1])) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDer angegebene Schematicname enthält verbotene Zeichen!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
Schematic schematic = Schematic.getSchemFromDB(args[1], player.getUniqueId());
|
Schematic schematic = Schematic.getSchemFromDB(args[1], player.getUniqueId());
|
||||||
if(schematic != null) {
|
if(schematic == null) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDiese Schematic existiert nicht!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
if(schematic.getSchemOwner() != WarkingUser.get(player.getUniqueId()).getId()) {
|
if(schematic.getSchemOwner() != WarkingUser.get(player.getUniqueId()).getId()) {
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDafür musst du der Owner der Schematic sein!");
|
player.sendMessage(SchematicSystem.PREFIX + "§cDafür musst du der Owner der Schematic sein!");
|
||||||
return false;
|
return false;
|
||||||
@ -521,29 +525,40 @@ public class SchematicCommand implements CommandExecutor {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDiese Schematic existiert nicht!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDer angegebene Schematicname enthält verbotene Zeichen!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if(args[0].equalsIgnoreCase("delmember")) {
|
if(args[0].equalsIgnoreCase("delmember")) {
|
||||||
if(CheckUtils.isSchematicNameAllowed(args[1])) {
|
if(!CheckUtils.isSchematicNameAllowed(args[1])) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDer angegebene Schematicname enthält verbotene Zeichen!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
Schematic schematic = Schematic.getSchemFromDB(args[1], player.getUniqueId());
|
Schematic schematic = Schematic.getSchemFromDB(args[1], player.getUniqueId());
|
||||||
if(schematic != null) {
|
if(schematic == null) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDiese Schematic existiert nicht!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
if(schematic.getSchemOwner() != WarkingUser.get(player.getUniqueId()).getId()) {
|
if(schematic.getSchemOwner() != WarkingUser.get(player.getUniqueId()).getId()) {
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDafür musst du der Owner der Schematic sein!");
|
player.sendMessage(SchematicSystem.PREFIX + "§cDafür musst du der Owner der Schematic sein!");
|
||||||
return false;
|
return false;
|
||||||
} else {
|
} else {
|
||||||
WarkingUser warkingUser = WarkingUser.get(args[2]);
|
WarkingUser warkingUser = WarkingUser.get(args[2]);
|
||||||
if(warkingUser.getUUID() != null) {
|
if(warkingUser.getUUID() == null) {
|
||||||
if(schematic.getSchemOwner() != warkingUser.getId()) {
|
player.sendMessage(SchematicSystem.PREFIX + "§cDieser Spieler existiert nicht!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(schematic.getSchemOwner() == warkingUser.getId()) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDu kannst dich nicht von deiner eigenen Schematic removen!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
SchematicMember schematicMember = SchematicMember.getSchemMemberFromDB(schematic.getSchemName(), WarkingUser.get(schematic.getSchemOwner()).getUUID(), warkingUser.getUUID());
|
SchematicMember schematicMember = SchematicMember.getSchemMemberFromDB(schematic.getSchemName(), WarkingUser.get(schematic.getSchemOwner()).getUUID(), warkingUser.getUUID());
|
||||||
if(schematicMember != null) {
|
if(schematicMember == null) {
|
||||||
|
player.sendMessage(SchematicSystem.PREFIX + "§cDieser Spieler ist nicht auf die Schematic geaddet!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
schematicMember.remove();
|
schematicMember.remove();
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "Der Spieler §6" + warkingUser.getUserName() + " §7hat keinen Zugriff mehr auf die Schematic §6" + schematic.getSchemName() + "§7.");
|
player.sendMessage(SchematicSystem.PREFIX + "Der Spieler §6" + warkingUser.getUserName() + " §7hat keinen Zugriff mehr auf die Schematic §6" + schematic.getSchemName() + "§7.");
|
||||||
@ -552,27 +567,6 @@ public class SchematicCommand implements CommandExecutor {
|
|||||||
if(target != null)
|
if(target != null)
|
||||||
target.sendMessage(SchematicSystem.PREFIX + "Du hast keinen Zugriff mehr auf die Schematic §6" + schematic.getSchemName() + "§7von §6" + WarkingUser.get(schematic.getSchemOwner()).getUserName() + "§7.");
|
target.sendMessage(SchematicSystem.PREFIX + "Du hast keinen Zugriff mehr auf die Schematic §6" + schematic.getSchemName() + "§7von §6" + WarkingUser.get(schematic.getSchemOwner()).getUserName() + "§7.");
|
||||||
return false;
|
return false;
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDieser Spieler ist nicht auf die Schematic geaddet!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDu kannst dich nicht von deiner eigenen Schematic removen!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDieser Spieler existiert nicht!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDiese Schematic existiert nicht!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
player.sendMessage(SchematicSystem.PREFIX + "§cDer angegebene Schematicname enthält verbotene Zeichen!");
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren