Item in anvil

  • 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.

Aralwen

Active Member
May 26, 2017
164
14
18
Hello ! I try to put an item automatically in the first slot when opening an anvil

My research :

code_language.skript:
command /test:
    trigger:
        open anvil to the player
        wait 1 tick
        format slot 0 of player with name tag named "&fName" to be unstealable
 
code_language.skript:
on inventory click: # To get slot number.
    send "%clicked slot%"
    
    
command /test:
    trigger:
        open anvil to the player
        wait 1 tick
        set slot 0 of player current inventory to name tag named "&fName"
    
on inventory click:
    if inventory type of clicked inventory is "ANVIL": # requires skellet
        if clicked slot is 0:
            cancel event
            # Do Stuff
 
code_language.skript:
on inventory click: # To get slot number.
    send "%clicked slot%"
   
   
command /test:
    trigger:
        open anvil to the player
        wait 1 tick
        set slot 0 of player current inventory to name tag named "&fName"
   
on inventory click:
    if inventory type of clicked inventory is "ANVIL": # requires skellet
        if clicked slot is 0:
            cancel event
            # Do Stuff
Hello, doesn't work :/
 
Status
Not open for further replies.