# ============================================= # NBTsk v1.2 by Aidanete # ============================================= options: Prefix: [NBTSk] on load: send "{@Prefix} Preparing our storage for saved items" to console set {nbtsk.installed} to true on unload: send "{@Prefix} Our items stored again, bye!" to console command /ns [] []: trigger: if arg 1 is not set: message "{@Prefix} Type /ns help for a list of commands" else if arg 1 is "save": if arg 2 is not set: message "{@Prefix} You cannot save items without a name established" else: set {ns::%arg 2%} to player's tool message "{@Prefix} Sucessfully set item to id %arg 2%" else if arg 1 is "delete": if arg 2 is not set: message "{@Prefix} You cannot delete items without a name established" else if {ns::%arg 2%} is not set: message "{@Prefix} The item %arg 2% does not exist!" else: delete {ns::%arg 2%} message "{@Prefix} Sucessfully deleted item with id %arg 2%" else if arg 1 is "delall": if arg 2 is set: message "{@Prefix} Too many paramters!" else: delete {ns::*} message "{@Prefix} Sucessfully deleted all items" else if arg 1 is "list": if arg 2 is set: message "{@Prefix} Too many paramters!" else: message "All saved items" loop {ns::*}: message "%loop-index%" else if arg 1 is "give": if arg 2 is not set: message "{@Prefix} You cannot receive unnamed items!" else if {ns::%arg 2%} is not set: message "{@Prefix} The item %arg 2% does not exist!" else: give {ns::%arg 2%} to the player message "{@Prefix} Sucessfully received item with id %arg 2%" else if arg 1 is "help": if arg 2 is set: message "{@Prefix} Too many paramters!" else: message "Showing a complete list of commands" message "/ns help - Displays this text" message "/ns save (id) - Saves the item in player's hand as the id (id)" message "/ns delete (id) -Delete the item's saved with id (id)" message "/ns delall - Deletes all saved items" message "/ns give (id) - Adds to the player's inventory the item with id (id)" message "/ns list - Shows all ids" message "/ns give (id) - Adds to the player's inventory the item with id (id)" message "/ns saveblock (id) - Gives the block on the selection clipboard the id (id)" message "/ns wand - Give the selector tool for block saving" message "/ns reload - Reload the script, just debug" message "/ns test-syntax - Tells the syntax saved, just debug" else if arg 1 is "reload": make player execute command "/skript reload NBTSk" else if arg 1 is "test-syntax": if arg 2 is not set: message "{@Prefix} You cannot test the syntax of an unnamed id" else: message "{@Prefix} Syntax got: %{ns::%arg 2%}%" else if arg 1 is "wand": give 1 golden axe named "Block Saver" to the player message "{@Prefix} Leftclick on a block to store it. /ns saveblock (id) to store it" else if arg 1 is "saveblock": if arg 2 is not set: message "{@Prefix} You cannot save items without a name established" else: if {blocksaver::%player%} is not set: message "{@Prefix} You cannot save blocks if you don't have them in the seleciton" else: set {ns::%arg 2%} to {blocksaver::%player%} message "{@Prefix} Sucessfully saved block to id %arg 2%" else: message "{@Prefix} Unknown subcommand. Type /ns help to a full list of subcommands" on unload: delete {blocksaver::*} delete {nbtsk.installed} on break: player's tool is a golden axe named "Block Saver": cancel event set {blocksaver::%player%} to event-block message "{@Prefix} Saved item into selection clipboard. Save it with /ns saveblock (id)" # ======================================= # END OF FILE # =======================================