how to cancel item move

  • 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 comminuty!

    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.

dudle

Active Member
Jan 31, 2017
135
0
16
44
how can I deny the move of the items I have in my hotbar? I know how to do that in a gui, but not like in the hotbar. Any syntax please?
 
code_language.skript:
on tool change:
   cancel event
Maybe?
 
code_language.skript:
on inventory click:
    if name of player's current inventory is "name of gui":
        if clicked slot is 10:
            cancel event
        else if clicked item is stone:
            cancel event
 
code_language.skript:
on inventory click:
    if name of player's current inventory is "name of gui":
        if clicked slot is 10:
            cancel event
        else if clicked item is stone:
            cancel event
Iwant to cancel item move in player's inventory, and not in a gui they currently have opened.
 
how can I deny the move of the items I have in my hotbar? I know how to do that in a gui, but not like in the hotbar. Any syntax please?

I think he means offhand switch

code_language.skript:
On offhand move:
   Cancel event
[doublepost=1518592441,1518592211][/doublepost]
I think he means offhand switch

code_language.skript:
On offhand move:
   Cancel event

Or you take THE example of @ChisleLP but in stead of player's current inventory you use player's inventory
 
Status
Not open for further replies.