Parse charm details in inventory array #99
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.
#98 added charm support to item inspection, however, there is currently no support for charms on items in the own inventory/storage units.
This PR adds charm detail parsing so the item objects are populated with a new
charm
property:charm
- If a charm (sometimes referred to as keychain) is attached to the item, this object contains details about the charm.charm_id
- The ID of the charmoffset_x
- Floatoffset_y
- Floatoffset_z
- Floatpattern
- The charm's pattern (1-100,000)The naming i chose is not consistent with the names in the
inspectItem
result, however as this is the case for most of the keys, i decided to go withcharm
for clarity.Let me know if you think we should go with a different naming scheme.
In the
inspectItem
result, an array is provided as it seems like there is technical support for multiple charms (possibly because the logic is copied from stickers). As of now, only a single charm is allowed so i decided against using an array of lenght one. If you think we should go with the array solution for possible future compatability, let me know.