-
Notifications
You must be signed in to change notification settings - Fork 1
Configuration
Daniel Norris edited this page Nov 30, 2021
·
5 revisions
Below you can find the example menu config:
Added option allow-natural-close
. When set to false it will only allow the player to exit the GUI upon clicking an item with %close%
inventory:
identifier: example_menu
name: Example
height: 2
close-commands: ['console:msg WELL DONE!', 'console:msg
Test', 'player:help', 'player:pay Envyful 1']
items:
one:
positionX: 0
positionY: 0
type: 447
amount: 1
name: This is an item name! §bBLUE
lore: [§bLore line 1!, §bLore line 2!]
commands: ['console:bc test', 'console:ban Test!']
requirement: 'testing.one'
else:
positionX: 0
positionY: 0
type: 3
amount: 1
name: 'Item name&c!'
lore: [§bLore line 1!, §bLore line 3!]
commands: ['console:bc test', 'console:ban Test!']
In the commands you can use any placeholders installed on your server for the ForgePlaceholderAPI.
If you want to force close the GUI for the player use %close%
You can add different types of requirements using the following format:
items:
one:
positionX: 0
positionY: 0
type: 'playerhead'
damage: 3
amount: 1
name: ''
lore: []
nbt:
one:
type: String
key: 'UIText'
value: 'Example Text'
two:
type: String
key: 'UIHoverText'
value: 'Example value'
commands: ['%close%']
requirements:
one:
type: 'code'
code: "'%forge_name%' == 'Envyful'"
two:
type: 'itemstack_in_inventory'
item_type: 'minecraft:stone'
amount: 1
name: 'Test'
damage: 0
lore: []
three:
type: 'itemstack_in_slot'
slot: 1
item_type: 'minecraft:stone'
amount: 1
name: 'Test'
damage: 0
lore: []
four:
type: 'permission'
permission: 'hello'
else:
positionX: 0
positionY: 0
type: 3
amount: 1
name: 'Item name&c!'
lore: [§bLore line 1!, §bLore line 3!]
commands: ['console:bc test', 'console:ban Test!']