13
0

Hotfix SchemSearch and Public Schems
Alle Prüfungen waren erfolgreich
SteamWarCI Build successful

Dieser Commit ist enthalten in:
Chaos 2022-02-03 23:01:37 +01:00
Ursprung 09c6d3fe79
Commit 7e17d5ab34

Datei anzeigen

@ -332,6 +332,7 @@ public class SchematicCommand extends SWCommand {
return true; return true;
}); });
player.sendMessage("§eSchematics §8(§e" + nodes.size() + "§8)"); player.sendMessage("§eSchematics §8(§e" + nodes.size() + "§8)");
int finalUserId = userId;
nodes.forEach(node -> { nodes.forEach(node -> {
String br = node.generateBreadcrumbs(user); String br = node.generateBreadcrumbs(user);
String displayName = br; String displayName = br;
@ -343,7 +344,7 @@ public class SchematicCommand extends SWCommand {
} }
TextComponent schematics = new TextComponent("§7" + displayName); TextComponent schematics = new TextComponent("§7" + displayName);
schematics.setHoverEvent(new HoverEvent(HoverEvent.Action.SHOW_TEXT, new ComponentBuilder("§eSchematic verwalten").create())); schematics.setHoverEvent(new HoverEvent(HoverEvent.Action.SHOW_TEXT, new ComponentBuilder("§eSchematic verwalten").create()));
schematics.setClickEvent(new ClickEvent(ClickEvent.Action.RUN_COMMAND, "/schem info " + br)); schematics.setClickEvent(new ClickEvent(ClickEvent.Action.RUN_COMMAND, "/schem info " + (finalUserId == 0 ? "public ":"") + br));
player.spigot().sendMessage(schematics); player.spigot().sendMessage(schematics);
}); });