Add nbt without skstuff

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

Hackusater

Active Member
Aug 5, 2017
74
2
8
34
Hello, I am wondering if there is a way to add an nbt to an armorstand without using skstuff. (I am not looking for the console to send a command I am just wondering if it is possible without skstuff. If not then I will mark the thread as solved) Example:
code_language.skript:
add "{Invulnerable:1b}" to nbt of last spawned armor stand
 
I'm like 84% sure skript mirror could do it(it seems to do everything just about), but that's java and is way above my level currentlyx3
 
There are often different ways to do this, e.g. as Wynnevir said you could use skript-mirror to access the Bukkit API to set an entity's invulnerability, but if you specifically mean a way to merge an NBT string with an entity's NBT, no, there isn't a way without SkStuff as far as I know. Why would people even use SkStuff if you didn't need it to work with NBT?
 
SkStuff is required to use add NBT. Skript mirror can probably set an nbt to an armor stand when it is spawned in or something like that.
You dont need nbt to set an armorstand's invulnerability
Java:
armorStand.setInvulnerable(true);
this is java but shouldnt be too hard to convert to skript-mirror
 
  • Like
Reactions: St0medy
You dont need nbt to set an armorstand's invulnerability
Java:
armorStand.setInvulnerable(true);
this is java but shouldnt be too hard to convert to skript-mirror

Yes but, in java do that is simple but in sk turn it no

It is not as simple as it seems
 
You dont need nbt to set an armorstand's invulnerability
Java:
armorStand.setInvulnerable(true);
this is java but shouldn't be too hard to convert to skript-mirror
Well. I was using invulnerable as an example. I want to be able to do a lot of things (arms, name, equipped armor, position, etc) I just thought if I knew how to change the NBT I would be able to change all of these.


Yes but, in java do that is simple but in sk turn it no

It is not as simple as it seems
It is simple in sk mirror because it handles java not just english.
 
Last edited:
I know I probably can but I am asking if there is a way to edit the NBT. Thank you.
Of course theres a way but i highly recommend just using the armorstand's builtin methods to do it for you since nbt needs nms (which isnt a huge deal but makes your code version dependent). if youre gonna use nbt, i dont understand why youre not just using skstuff.
 
Status
Not open for further replies.