X

NOTICE

Are you sure you want to report this?

We've split up the commands, scripting and mods, and add ons category! Please be sure you get your thread in the right place.

89

Edit Player NBT

11 Comments

Post a new comment:

Please sign in to leave a comment.

  • 0
    Comment actions Permalink

    To clear up any confusion, when I say "it might have been rejected before" I mean that maybe the Mojang team had thought of it and rejected it, I did make sure to check for identical posts and rejected ideas similar to this before posting and found nothing.

  • 0
    Pe brito commented
    Comment actions Permalink

    I'd like to see this feature in the game too, but there's a reason why it'll very likely never become reality.
    If you change the player's health through survival elements, such as instant damage, the game will be notified of that, and update health bars, scoreboard objectives, etc.
    If you change it through NBT, there's no way of telling the game when it happens, unless it updates everything whenever you change a tiny bit of data. This could lead to performance issues, or desynchronization between the client (the players' devices) and the server.
    That's only my explanation, though. It might be inaccurate, but why wouldn't they add that feature then?

  • 0
    Demonfox50 commented
    Comment actions Permalink

    I mean a players nbt is actually handled by client so it wouldn't link correctly to server but if the player data was handled by the server than it would probably fix a lot of minecraft's client to server de-sync issues but what issues this would create is unclear.

  • 0
    deathconekul commented
    Comment actions Permalink

    I agree that the reason why you cannot do it already is likely due to desynchronization between client and server.

    Maybe allow nbt editing of just the inventory at the very least, as that would open up a lot more possibilities for maps/datapacks, such as changing the lore of an item in the player's inventory while keeping the stack size, and not having to cycle through all 64 of the possible stack sizes to use /replaceitem

  • 0
    poolcool02 commented
    Comment actions Permalink

    The desynchronization problem could simply be fixed by them making it sync when such a command is ran, sure when used too much it would cause lag but I do not see that as much of a problem, overuse any command and it will cause lag, also server plugins edit NBT data all the time, however they are doing it they have it work just fine, Mojang could do the same thing.

  • 1
    Comment actions Permalink

    Dinnerbone said "The whole idea behind editing NBT isn't that you're editing the entity, or the item, or the block - you're saving it, editing the save data, and loading it again. NBT isn't what we are using in memory, we have more efficient in-memory structures for things. It's 100% just save data." and modifying player data would have to kick the player out then reconnect them. 

  • 0
    poolcool02 commented
    Comment actions Permalink

    My point is that server plugins can do it, so Mojang could find a way to do it too

  • 0
    Comment actions Permalink

    Wow, a suggestion in this category that isn't bad (seriously kids stop asking for /fly and other fraction server crap!),

    this would be great for custom games (pvp, pve, adventure, etc.)! this deserves more votes.
    and maybe just things like heath, damage, speed, maybe even custom values!

  • 0
    Shadow Blitz commented
    Comment actions Permalink

    the issue with destroying the player and disconnecting could be solved by creating a copy of that player and then setting the net id to it and THEN destroy the old player in the same frame.

    and then you have edited player nbt data.

  • 0
    Comment actions Permalink

    This would be great! /data merge entity @p {Motion:[0.0,1.0,0.0]} would be amazing!

  • 0
    jello hex commented
    Comment actions Permalink

    Even if the tags we could modify were restricted to things like fire ticks, inventory, etc. it would be worth it. We don't need to be able to set our flying speed and stuff.