Addon Sk-NBeeT

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

ShaneBee

Supporter +
Addon Developer
Sep 7, 2017
2,247
241
73
Vancouver, Canada
RESOURCE PAGE
Sk-NBeeT.png
[doublepost=1546561979,1543785086][/doublepost]UPDATE
Small Changes [1.2.2]
[doublepost=1546641368][/doublepost]UPDATE
Some New Stuff [1.2.3]
Some fun new stuff including
"Item with NBT" - You can now directly give a player an item with NBT or even use this in GUIs without the need for adding NBT to a variable
"Skull Owner of Block" - You can set the owner of a Skull that has been placed on the ground/wall. (I know this isn't really NBT related but I know a fair bit of people looking for this and I think only Skellett has an option for this)
[doublepost=1546895965][/doublepost]UPDATE
ADDED:
  • Entity NoClip State (Expression) - I know this really isn't NBT related but I added it anyways
  • Spawn Entity with NBT (Effect) - You can now directly spawn an entity with NBT
CHANGED:
  • Just some small stuff under the hook. If you are using a BETA version you will see a warning message in the console, just so you know
[doublepost=1547224864][/doublepost]Big Rewrite [2.0.0]

Sk-NBeeT series 2 is a big re-write adding support for older versions of Spigot all in one jar file.
Doing this will give me the ability to update this add-on and keep it working for many different Spigot versions, rather than dropping support for past Spigot versions as new ones come out

ADDED:
  • Object NBT - Item/Entity/Tile-Entity has now been merged into one new expression.
  • NMS Classes - Classes for each NMS revision number, allowing one single plugin to work across several Spigot versions.
CHANGED:
  • Some small changes to patterns in some expressions
REMOVED:
  • Item NBT Expression (In favor of the new Object NBT expression)
  • Entity NBT Expression (In favor of the new Object NBT expression)
  • Tile-Entity NBT Expression (In favor of the new Object NBT expression)
  • Skull Owner Expression (Due to some odd differences between the BukkitAPI 1.12 -> 1.13, I have removed this for now)
 
Code:
    set {_firework} to "firework" parsed as entity type
    add "{LifeTime:2}" to entity-nbt of {_firework}
    broadcast "%{_firework}'s entity-nbt%"

Nbt is empty after setting it and nothing is changing.
 
Code:
    set {_firework} to "firework" parsed as entity type
    add "{LifeTime:2}" to entity-nbt of {_firework}
    broadcast "%{_firework}'s entity-nbt%"

Nbt is empty after setting it and nothing is changing.
Thats probably because entity type and entity are 2 different things.
I don't think you can add NBT to an entity type, since the entity has yet to exist
 
!add "{Glowing:1}" to player's nbt
After using this code
I'm going to be sent to the coordinate 0, 0, 0.

This server is running Paper version git-Paper-1613 (MC: 1.12.2) (Implementing API version 1.12.2-R0.1-SNAPSHOT)
Skript 2.3.6
 
For some reason dealing with a player's NBT doesn't seem to work. Im not entirely sure why.
You can look at the open source code for 'SkStuff'.
Modifying a player's data using SkStuff will not be transmitted
 
Is it possible to delete an entity based on NBT?
Im not sure I understand the question.

NBT is data saved to an entity. I don't think you can get an entity based on an NBT string, unless the NBT string contains their UUID, which you could possibly grab the Entity from the UUID and remove/kill the entity.
 
Oh, ok.
So I think I need to loop all entities and then check each entity nbt tag.
Thanks.