Clicked Item (Skellett)

  • Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the community!

    Now, what are you waiting for? Join the community now!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

Status
Not open for further replies.

inavir

Member
May 1, 2017
10
0
0
Hello,

I'm having issues with the clicked item expression. I think the root of the issue is that it is an item type. Is it possible to convert item types to an item stack with skript? I am mostly following the example provided in the documentation, but it gives me an error, which is why I changed it slightly. I'm using version skript version 2.2-dev30b (bensku) on paper 1.12.1.

code_language.skript:
on inventory click:
  broadcast "%clicked item%" # works
  # broadcast "%name of clicked item%" ERROR: clicked item is neither an item stack, a slot, a living entity, a player, or an inventory
  set {_item} to clicked item
  if name of {_item} is set:
    broadcast "%{_item}%" # <none>
    broadcast "%name of {_item}%" # <none>

Any advice is greatly appreciated!
 
display name of clicked item
code_language.skript:
on inventory click:
  broadcast "%clicked item%" # works
  broadcast "%display name of clicked item%"

This gives the same error (clicked item is neither an item stack, a slot, a living entity, a player, or an inventory)
 
i work a lot with gui and i never has a problem with it. So maybe update your Skellett?

*Edit:

btw i use

code_language.skript:
"%name of clicked item%"
 
It might be disabled check your skellett configs
[doublepost=1503254739,1502674731][/doublepost]I just tested this im having the same results
 
Status
Not open for further replies.