Skip to content

Create menu.

broken1arrow edited this page Jun 24, 2022 · 8 revisions

Setup for ether have all menus in single file or one menu in every file.

Menus:
  # Menu name, need to be unique.
  Main_Menu:
    # menu size
    Menu_Size: 36
    # menu title
    Menu_Title: "&1Main menu"
    # slots you want to use to add fill items inside (used intern in the plugin).
    FillSpace: 9-35
    # max amount of item on the page (if you not fill all slots and wants more pages).
    Max_Amount_Of_Items: 13
    # if it shall update buttons when menu open (my menu API have this suport).
    Update_Buttons: true
    # Time when shall update the buttons.
    Update_buttons_delay: 5
    # menu key for all items in the menu (don´t change this name).
    Open_requirement:
      Requirement:
    Menu_Items:
      # button/item name, need to be unique.
      menu_button_1: 
        # the item type you can also use placeholders.
        Icon: STONE
        Slot: 1

Setup for one menu option 1.

If you set up one menu in the file.

Menus:
  # menu size
  Menu_Size: 36
  # menu title
  Menu_Title: "&1Main menu"
  # slots you want to use to add items inside (used intern in the plugin).
  FillSpace: 9-35
  # max amount of item on the page (if you not fill all slots and wants more pages).
  Max_Amount_Of_Items: 13
  # if it shall update buttons when menu open (my menu API have this suport).
  Update_Buttons: true
  # Time when shall update the buttons.
  Update_buttons_delay: 5
  Open_requirement:
    Requirement: 
  Menu_Items:
    # button/item name, need to be unique. 
    menu_button_1: 
      # the item type you can also use placeholders.
      Icon: STONE
      Slot: 1   

Setup for one menu option 2.

If you set up one menu in the file.

Menus:
  # menu size
  Menu_Size: 36
  # menu title
  Menu_Title: "&1Main menu"
  # slots you want to use to add items inside (used intern in the plugin).
  FillSpace: 9-35
  # max amount of item on the page (if you not fill all slots and wants more pages).
  Max_Amount_Of_Items: 13
  # if it shall update buttons when menu open (my menu API have this suport).
  Update_Buttons: true
  # Time when shall update the buttons.
  Update_buttons_delay: 5
  Open_requirement:
    Requirement:  
Menu_Items:
  # button/item name, need to be unique. 
  menu_button_1: 
    # the item type you can also use placeholders.
    Icon: STONE
    Slot: 1   

Menu Size

Size of the inventory.

Menu_Size: 54

Menu Title

Size of the inventory. Translations of colors depend on implementation of this api.

Menu_Title: "title"

Sound

Set sound when open inventory (depend on implementation of this api). look here for all sound types

Sound: BLOCK_NOTE_BLOCK_BASEDRUM

Menu type

Type of inventory. If not set it will be chest. Look here for all types.

Menu_Type: chest

Open requirement

Requirement player need to open menu. check requirements here.

Open_requirement:
  Requirement:
    # you can set several requirements but every one
    # need to be unique named.
    require_name:
      # check Requirements tab.
  # stop on first requirement some return true.
  stop_at_success: true
  # number of requirement some need return true.
  # only works if optional_requirement is set to true.
  minimum_requirement: 1
  # only works with click requirement and open.
  deny_commands:
    - "[ACTION] your command or message here" 

Depend on implementation of this api

Fill space

Depending if this will be used or not. you can use it for tell buttons some shall be filled auto (inside your plugin if you want to parse a list of something (material,spawn egg or other things)) or to allow some slots for add/remove items.

FillSpace: 9-35

Update buttons

If you want all buttons be updated when menu is open.

Update_Buttons: true

Update buttons delay

Time between every update in seconds.

Update_buttons_delay: 5
Clone this wiki locally