AnvilGUI items invisiblle.

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: Minor
    • None
    • Affects Version/s: None
    • Environment:

      SpigotBuildTools, Maven, IntelliJ Ultimate.

    • 1.16.5
    • PlayerController
    • Yes

      I am trying to create a custom Anvil GUI for user input but when i call setItem(0, itemstack) it doesnt apear in the anvil gui.

      Inventory tmpinv = Bukkit.getServer().createInventory(usedBy, InventoryType.ANVIL, ChatColor.GREEN + "Enter Reason");
      //Switches old inventory with new
      PlayerManagerGuiHandler.getHandler().updateInventory(inventory, tmpinv);
      inventory = tmpinv;
      inventory.setItem(0, PlayerManagerGuiHandler.createGuiItem(Material.NAME_TAG, "Reason", "Enter your custom reason"));
      usedBy.openInventory(inventory);
      usedBy.updateInventory(); 

            Assignee:
            md_5
            Reporter:
            MondGnu
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: