NBTExplorer icon indicating copy to clipboard operation
NBTExplorer copied to clipboard

Add --delete flag to aid trimming worlds

Open jkunkee opened this issue 5 years ago • 1 comments

When a new version of the game comes along, it is useful to be able to delete chunks based on some criteria, like InhabitedTime being 0.

This change adds a --delete flag to NBTUtil that deletes the node or nodes specified by --path. It also restructures how the nodes were iterated over to allow them to be deleted.

NBTUtil can then be wrapped in a script that reads the data from each chunk and calls NBTUtil --delete on the chunk if the criteria are met.

jkunkee avatar Jun 29 '20 00:06 jkunkee

I wrote a script to leverage this feature, but it's really slow (something like 1s/chunk): https://gist.github.com/jkunkee/71847e1565e2152cf4c1e42b6aa6cd9e

jkunkee avatar Jun 29 '20 18:06 jkunkee