Dieser Commit ist enthalten in:
Ursprung
73cca7675c
Commit
cd401a389e
@ -432,7 +432,8 @@ public class SchematicCommand extends SWCommand {
|
||||
@Register("move")
|
||||
public void move(Player player, SchematicNode node, @Mapper("dirStringMapper") String name) {
|
||||
SteamwarUser user = getUser(player);
|
||||
if (node.getOwner() != user.getId()) {
|
||||
NodeMember member = NodeMember.getNodeMember(node.getId(), user.getId());
|
||||
if (node.getOwner() != user.getId() && member == null) {
|
||||
player.sendMessage(SchematicSystem.PREFIX + "§cDu kannst nur deine eigenen Schems verschieben.");
|
||||
return;
|
||||
}
|
||||
@ -445,6 +446,7 @@ public class SchematicCommand extends SWCommand {
|
||||
String[] layers = name.split("/");
|
||||
if (invalidSchemName(player, layers)) return;
|
||||
SchematicNode newNode = mkdirs(layers, user, 0);
|
||||
if(node.getOwner() == user.getId()) {
|
||||
if(SchematicNode.getAllParentsOfNode(newNode).contains(node)) {
|
||||
player.sendMessage(SchematicSystem.PREFIX + "§cDas gibt nur Fehler, vertrau mir.");
|
||||
return;
|
||||
@ -454,6 +456,9 @@ public class SchematicCommand extends SWCommand {
|
||||
result.sendError(player);
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
member.setParentNode(newNode == null ? null : node.getId());
|
||||
}
|
||||
}
|
||||
player.sendMessage(SchematicSystem.PREFIX + "§7Die Schematic ist nun unter §e" + node.generateBreadcrumbs(user) + " §7zu finden");
|
||||
}
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren