Help with giving someone a block on they can interact

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

ImKingGolden

Member
Aug 11, 2020
21
1
3
23
I'm a little lost and how i can give someone a block so only they can interact with that block and no one else (when its placed down). if anyone helps Thanks :emoji_grinning:
 
Are you talking about something like this?

Code:
command /specialstone:
    trigger:
        if player has permission "special.stone":
            give player 1 stone named "&aSpecial Stone"
on place stone:
    if name of player's held item contains "&aSpecial Stone":
        set {specialblock::%player's uuid%} to location of event-block
on break:
    if {specialblock::%player's uuid%} is location of event-block:
        delete {specialblock::%player's uuid%}
        send "&cYou removed your special stone!" to player
on right click on stone:
    if {specialblock::%player's uuid%} is location of event-block:
        cancel event
        send "&aWow! You clicked a block only you can use!" to player
        #code here
 
Status
Not open for further replies.