Improved the CustomItem meta checks#47
Merged
Merged
Conversation
…em for similarity.
…e settings already they will just be loaded as is. If it isn't it will clear them, to make sure they are configured correctly.
…it will use the MetaSettings directly.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The custom checks are now 100% modular.
For each saved (and registered) CustomItem you can set so called NBT checks, that can replace the default check or extend it.
By default the CustomItem will use a single check with the key
wolfyutilities:customitem_tag, which will just check for the namespaced key of the item.There must at least one check, if you don't set one the default one is used.
To add different checks you need to configure the config of the item or add them via the API.
It uses a new field in the config called
nbtCheckswith a childchecks, that is the actual the array that contains the checks.You are also able to code and register your own checks (inside your plugins
onLoad()).There isn't any wiki page for it you would have to look at the other checks and see how they are registered.