Discord Thread Shulker Box Name

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

This thread came from the skUnity Discord. You can't reply to it here but if you join the skUnity Discord, you'll be able to post a reply there. The thread link is part of the thread's message.
Status
Not open for further replies.
actually I just just a string tag of the shulker box to something but it doesn't seem to be setting for some reason
code_language.skript:
vb
set {_shulker} to shulker box named {@name}
set string tag "refill" of nbt of {_shulker} to "true"
give {_shulker} to player

vb
on right click:
    event-block is any shulker box
    string tag "refill" of nbt of event-block is "true"
    send nbt of event-block

Posted by: tarna256 from the skUnity Discord.
 
you should use a byte tag

set byte tag "refill" of nbt of {_shulker} to 1

0 or 1
when you place a block, the nbt changes
nbt of blocks and items are different, and they arent persistant
you need an
on place
event to set the custom tag of the block

Posted by: minecraftman1013 from the skUnity Discord.
 
code_language.skript:
vb
command /shulker:
    permission: shulker.refill
    trigger:
        set {_shulker} to shulker box named {@name}
        set byte tag "refill" of nbt of {_shulker} to 1
        give {_shulker} to player

on place:
    byte tag "refill" of nbt of player's tool is 1
    wait 1 tick
    set byte tag "refill" of nbt of event-block to 1

on right click:
    byte tag "refill" of nbt of event-block is 1
    send nbt of event-block

Posted by: tarna256 from the skUnity Discord.
 
Status
Not open for further replies.