Dieser Commit ist enthalten in:
Ursprung
63b4a8ca57
Commit
f7ce9950c7
@ -51,25 +51,25 @@ public class TeleporterListener extends BasicListener {
|
|||||||
return Bukkit.createInventory(null, InventoryType.HOPPER, "§6Teleporter");
|
return Bukkit.createInventory(null, InventoryType.HOPPER, "§6Teleporter");
|
||||||
});
|
});
|
||||||
swInventory.setItem(0, new SWItem(Material.WOODEN_AXE, "§eBaubereich").getItemStack(), clickType -> {
|
swInventory.setItem(0, new SWItem(Material.WOODEN_AXE, "§eBaubereich").getItemStack(), clickType -> {
|
||||||
player.teleport(bau);
|
teleport(bau, player);
|
||||||
Portals.getStack(player).clear();
|
|
||||||
});
|
});
|
||||||
swInventory.setItem(1, new SWItem(Material.MAGMA_CREAM, "§eSpawn").getItemStack(), clickType -> {
|
swInventory.setItem(1, new SWItem(Material.MAGMA_CREAM, "§eSpawn").getItemStack(), clickType -> {
|
||||||
player.teleport(spawn);
|
player.teleport(spawn);
|
||||||
Portals.getStack(player).clear();
|
|
||||||
});
|
});
|
||||||
swInventory.setItem(2, new SWItem(Material.BEACON, "§eTeamhalle").getItemStack(), clickType -> {
|
swInventory.setItem(2, new SWItem(Material.BEACON, "§eTeamhalle").getItemStack(), clickType -> {
|
||||||
player.teleport(team);
|
player.teleport(team);
|
||||||
Portals.getStack(player).clear();
|
|
||||||
});
|
});
|
||||||
swInventory.setItem(3, new SWItem(Material.MAP, "§eMap").getItemStack(), clickType -> {
|
swInventory.setItem(3, new SWItem(Material.MAP, "§eMap").getItemStack(), clickType -> {
|
||||||
player.teleport(map);
|
player.teleport(map);
|
||||||
Portals.getStack(player).clear();
|
|
||||||
});
|
});
|
||||||
swInventory.setItem(4, new SWItem(Material.CLOCK, "§eArenen").getItemStack(), clickType -> {
|
swInventory.setItem(4, new SWItem(Material.CLOCK, "§eArenen").getItemStack(), clickType -> {
|
||||||
player.teleport(arenen);
|
teleport(arenen, player);
|
||||||
Portals.getStack(player).clear();
|
|
||||||
});
|
});
|
||||||
swInventory.open();
|
swInventory.open();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void teleport(Location location, Player player) {
|
||||||
|
player.teleport(location);
|
||||||
|
Portals.getStack(player).clear();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren