Add /warp feature #55
@ -561,6 +561,8 @@ WARP_MATERIAL_CHOOSE=Material auswählen
|
|||||||
WARP_GUI_NAME=Warps
|
WARP_GUI_NAME=Warps
|
||||||
WARP_GUI_NO=§cHier giebt es noch keine Warps
|
WARP_GUI_NO=§cHier giebt es noch keine Warps
|
||||||
WARP_GUI_DISTANCE=§7Distanz: §e{0} §7Blöcke
|
WARP_GUI_DISTANCE=§7Distanz: §e{0} §7Blöcke
|
||||||
|
WARP_GUI_LCLICK=§7Links klicken zum teleportieren
|
||||||
|
WARP_GUI_RCLICK=§7Rechts klicken zum editieren
|
||||||
WARP_LIST_PREVIOUS_PAGE=§eVorherige Seite
|
WARP_LIST_PREVIOUS_PAGE=§eVorherige Seite
|
||||||
WARP_LIST_PAGE=§e Seite ({0}/{1}) »»
|
WARP_LIST_PAGE=§e Seite ({0}/{1}) »»
|
||||||
WARP_LIST_NEXT_PAGE=§eNächste Seite
|
WARP_LIST_NEXT_PAGE=§eNächste Seite
|
||||||
|
@ -24,6 +24,7 @@ import de.steamwar.bausystem.Permission;
|
|||||||
import de.steamwar.inventory.SWInventory;
|
import de.steamwar.inventory.SWInventory;
|
||||||
import de.steamwar.inventory.SWItem;
|
import de.steamwar.inventory.SWItem;
|
||||||
import de.steamwar.inventory.SWListInv;
|
import de.steamwar.inventory.SWListInv;
|
||||||
|
import lombok.experimental.UtilityClass;
|
||||||
import org.bukkit.Material;
|
import org.bukkit.Material;
|
||||||
import org.bukkit.entity.Player;
|
import org.bukkit.entity.Player;
|
||||||
|
|
||||||
@ -31,6 +32,7 @@ import java.util.ArrayList;
|
|||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
@UtilityClass
|
||||||
public class WarpGui {
|
public class WarpGui {
|
||||||
|
|
||||||
public static void openGui(Player player) {
|
public static void openGui(Player player) {
|
||||||
@ -42,7 +44,11 @@ public class WarpGui {
|
|||||||
BauSystem.MESSAGE.parse("WARP_LOC_X", player, (int) warp.getLocation().getX()),
|
BauSystem.MESSAGE.parse("WARP_LOC_X", player, (int) warp.getLocation().getX()),
|
||||||
BauSystem.MESSAGE.parse("WARP_LOC_Y", player, (int) warp.getLocation().getY()),
|
BauSystem.MESSAGE.parse("WARP_LOC_Y", player, (int) warp.getLocation().getY()),
|
||||||
BauSystem.MESSAGE.parse("WARP_LOC_Z", player, (int) warp.getLocation().getZ()),
|
BauSystem.MESSAGE.parse("WARP_LOC_Z", player, (int) warp.getLocation().getZ()),
|
||||||
BauSystem.MESSAGE.parse("WARP_GUI_DISTANCE", player, (int) warp.getLocation().distance(player.getLocation()))),
|
BauSystem.MESSAGE.parse("WARP_GUI_DISTANCE", player, (int) warp.getLocation().distance(player.getLocation())),
|
||||||
|
"",
|
||||||
|
BauSystem.MESSAGE.parse("WARP_GUI_LCLICK", player),
|
||||||
|
BauSystem.MESSAGE.parse("WARP_GUI_RCLICK", player)
|
||||||
|
),
|
||||||
false,
|
false,
|
||||||
clickType -> {
|
clickType -> {
|
||||||
}
|
}
|
||||||
@ -84,7 +90,7 @@ public class WarpGui {
|
|||||||
public static void changeMaterial(Player player, Warp warp) {
|
public static void changeMaterial(Player player, Warp warp) {
|
||||||
List<SWListInv.SWListEntry<Material>> materials = new ArrayList<>();
|
List<SWListInv.SWListEntry<Material>> materials = new ArrayList<>();
|
||||||
for (Material value : Material.values()) {
|
for (Material value : Material.values()) {
|
||||||
if (value.isLegacy() || value.isAir()) continue;
|
if (value.isLegacy() || value.isAir() || !value.isBlock() || !value.isItem()) continue;
|
||||||
materials.add(new SWListInv.SWListEntry<>(new SWItem(value, "§e" + value.name()), value));
|
materials.add(new SWListInv.SWListEntry<>(new SWItem(value, "§e" + value.name()), value));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren