13
0

Things
Alle Prüfungen waren erfolgreich
SteamWarCI Build successful

Dieser Commit ist enthalten in:
zOnlyKroks 2022-03-26 16:17:41 +01:00
Ursprung bc39fa4473
Commit b0444cbe8e

Datei anzeigen

@ -56,7 +56,7 @@ public class TeleporterListener extends BasicListener{
player.openInventory(inventory); player.openInventory(inventory);
} }
@EventHandler(priority = EventPriority.HIGH) @EventHandler
public void handlePlayerInventoryInteract(InventoryClickEvent event) { public void handlePlayerInventoryInteract(InventoryClickEvent event) {
Player player = (Player) event.getWhoClicked(); Player player = (Player) event.getWhoClicked();
ItemStack item = event.getCurrentItem(); ItemStack item = event.getCurrentItem();
@ -64,6 +64,8 @@ public class TeleporterListener extends BasicListener{
if(item == null) if(item == null)
return; return;
if(event.getClickedInventory().getContents() != inventory.getContents()) return;
if(item.getType() == Material.MAGMA_CREAM) { if(item.getType() == Material.MAGMA_CREAM) {
player.teleport(spawn); player.teleport(spawn);
}else if(item.getType() == Material.BEACON) { }else if(item.getType() == Material.BEACON) {