#How do i create menu accessible only when you have no items in inventory?
1 messages · Page 1 of 1 (latest)
use open requirement and the checkitem expansion ig
something like
open_requirement:
requirements:
item:
type: has item
material: dirt
amount: 1
oh no items
lol
still open requirement
u can use the checkitem expansion to check if every slot is empty
uf
idk tbh if there is a placeholder for that but i ll take a look later
i really really need this, i need arena where there will be no items
open_requirement:
requirements:
slots:
type: "=="
input: "%player_empty_slots%"
output: "36"
try this @neon summit
this checks how many empty slots a player has
36 is all empty [not armor/offhand] included
u need the player expansion btw
/papi ecloud download player
u need placeholderapi installed
and then do /papi reload
it's the most basic one 😛
well for offhand add another requirement that checks if %player_item_in_offhand% = AIR
and for the armor slots use the checkitem expansion to check if there is an item in the armor's slots
open_requirement:
requirements:
slots:
type: "=="
input: "%player_empty_slots%"
output: "36"
requirements:
slots:
type: has item
input: "%player_item_in_offhand%"
material: air
?
should it look like this? or....
nah
open_requirement:
requirements:
slots:
type: "=="
input: "%player_empty_slots%"
output: "36"
offhand:
type: "=="
input: "%player_item_in_offhand%"
material: "AIR"
try this
%player_armor_chestplate_data% ?
is this one right?
i mean do i have to uset this one placeholder
open_requirement:
requirements:
slots:
type: "=="
input: "%player_empty_slots%"
output: "36"
offhand:
type: "=="
input: "%player_item_in_offhand%"
output: "AIR"
helmet:
type: "=="
input: "%checkitem_inslot:39%"
output: "no"
chestplate:
type: "=="
input: "%checkitem_inslot:38%"
output: "no"
leggings:
type: "=="
input: "%checkitem_inslot:37%"
output: "no"
boots:
type: "=="
input: "%checkitem_inslot:36%"
output: "no"
try this @neon summit
but make sure to download the checkitem expansion /papi ecloud download checkitem and then /papi reload
dunno why... here's my menu
open_command:
- pvp
open_commands:
size: 9
open_requirement:
requirements:
slots:
type: "=="
input: "%player_empty_slots%"
output: "36"
offhand:
type: "=="
input: "%player_item_in_offhand%"
output: "AIR"
helmet:
type: "=="
input: "%checkitem_inslot:39%"
output: "no"
chestplate:
type: "=="
input: "%checkitem_inslot:38%"
output: "no"
leggings:
type: "=="
input: "%checkitem_inslot:37%"
output: "no"
boots:
type: "=="
input: "%checkitem_inslot:36%"
output: "no"
deny_commands:
- "[message] &c&lУ вас есть предметы в инвентаре!"
items:
1:
material: hdb-40370
data: 1
slot: 4
display_name: "&6Телепортация На Арену"
lore:
left_click_commands:
- '[console] warps pvp %player_name%'
- '[console] heal %player_name%' ```
and whats wrong with it
wait
i might be really dumb
give me a sec
cant i input deny_commands ?
wait
i actually cant use it at all
/pvp isnt working
it works for me? :/
i mean the gui opens
but the issue is smth else
gimme a sec
menu_title: '&6&lАрена'
open_command:
- pvp
size: 9
open_requirement:
requirements:
slots:
type: "=="
input: "%player_empty_slots%"
output: "36"
offhand:
type: "=="
input: "%player_item_in_offhand%"
output: "AIR"
helmet:
type: "=="
input: "%checkitem_inslot:39%"
output: "no"
chestplate:
type: "=="
input: "%checkitem_inslot:38%"
output: "no"
leggings:
type: "=="
input: "%checkitem_inslot:37%"
output: "no"
boots:
type: "=="
input: "%checkitem_inslot:36%"
output: "no"
deny_commands:
- "[message] &c&lУ вас есть предметы в инвентаре!"
items:
1:
material: hdb-40370
data: 1
slot: 4
display_name: "&6Телепортация На Арену"
lore:
left_click_commands:
- '[console] warps pvp %player_name%'
- '[console] heal %player_name%'
try this @neon summit
u had the open_commands: twice
algriht
it still has an issue give me a sec :/
menu_title: '&6&lАрена'
open_command:
- pvp
size: 9
open_requirement:
requirements:
slots:
type: string equals ignorecase
input: '%player_empty_slots%'
output: '36'
deny_commands:
- '[message] &c&lУ вас есть предметы в инвентаре! 1'
offhand:
type: string equals ignorecase
input: '%checkitem_inslot:40%'
output: 'no'
deny_commands:
- '[message] &c&lУ вас есть предметы в инвентаре! 2'
helmet:
type: string equals ignorecase
input: '%checkitem_inslot:39%'
output: 'no'
deny_commands:
- '[message] &c&lУ вас есть предметы в инвентаре! 3'
chestplate:
type: string equals ignorecase
input: '%checkitem_inslot:38%'
output: 'no'
deny_commands:
- '[message] &c&lУ вас есть предметы в инвентаре! 4'
leggings:
type: string equals ignorecase
input: '%checkitem_inslot:37%'
output: 'no'
deny_commands:
- '[message] &c&lУ вас есть предметы в инвентаре! 5'
boots:
type: string equals ignorecase
input: '%checkitem_inslot:36%'
output: 'no'
deny_commands:
- '[message] &c&lУ вас есть предметы в инвентаре! 6'
items:
1:
material: hdb-40370
data: 1
slot: 4
display_name: '&6Телепортация На Арену'
lore:
left_click_commands:
- '[console] warps pvp %player_name%'
- '[console] heal %player_name%'
this 99% works with no errors @neon summit
i added the deny commands per action so i can do the debugging
u can remove em if u want to
let me seee
also u can add register_commands: true
sorry that you have to do it for me
nope
i like doing things in dm :d
;-;
it breaks
every menu
ive done it with
no joke
its just not working
playin 1.19.3 let me see the version if you need it
menu_title: '&6&lАрена'
open_command:
- pvp
register_commands: true
size: 9
open_requirement:
requirements:
slots:
type: string equals ignorecase
input: '%player_empty_slots%'
output: '36'
deny_commands:
- '[message] &c&lУ вас есть предметы в инвентаре! 1'
offhand:
type: string equals ignorecase
input: '%checkitem_inslot:40%'
output: 'no'
deny_commands:
- '[message] &c&lУ вас есть предметы в инвентаре! 2'
helmet:
type: string equals ignorecase
input: '%checkitem_inslot:39%'
output: 'no'
deny_commands:
- '[message] &c&lУ вас есть предметы в инвентаре! 3'
chestplate:
type: string equals ignorecase
input: '%checkitem_inslot:38%'
output: 'no'
deny_commands:
- '[message] &c&lУ вас есть предметы в инвентаре! 4'
leggings:
type: string equals ignorecase
input: '%checkitem_inslot:37%'
output: 'no'
deny_commands:
- '[message] &c&lУ вас есть предметы в инвентаре! 5'
boots:
type: string equals ignorecase
input: '%checkitem_inslot:36%'
output: 'no'
deny_commands:
- '[message] &c&lУ вас есть предметы в инвентаре! 6'
items:
1:
material: hdb-40370
data: 1
slot: 4
display_name: '&6Телепортация На Арену'
lore:
left_click_commands:
- '[console] warps pvp %player_name%'
- '[console] heal %player_name%'
like that?
1.13.7
yep
one of my dev added it exactly like this
he managed dm in 1.16.5 version
well is there mby another plugin registered to the /pvp command?
its not only pvp thing
ive tried with lots of menus
now menu works just fine
ty!
np :d
:/
i have to finish some of the workbench wood crafts but its boring :/
need my help ?
nah its basically copy paste but still boring
what's why you need my help :/
cause what i m doing is boring
i m copying the name/lore of the item to the gui for every item
its mostly the display that needs to be done now for the already existed items
did you make chest recipe ?
yuh there only a few left wood related