Skip to content

Conversation

@Hexcein-moonsters
Copy link

Armor fix: removing an enchantment from the yml would normally make this armorchangeevent throw a massive error every 1s -- now doesn't give errors anymore

Dust fix: Magical Dust (Angel/Fixing) previously always returned early as it wrongfully compared item-data. This made you not able to apply the dust on a book. I'm assuming the official jar did not use the latest github version? Well now it is fixed
// this new and updated code will make it parse 'bookData' as the currentItem, and 'dustData' as the cursor item.
// Before, it always incorrectly compared bookData and dustData to null as both were created using the same item!
// And a single item cannot be both a book and both dust, so one is bound to be null.
// However with my commit it will compare the 2 different datacontainer items.

Please read my code comments for more info

Copy link
Member

@ryderbelserion ryderbelserion left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I do not like to hide an error that is actually a result of something you are not suppose to do, The enchantment file is static, and expects everything to be there.

I have something in mind for when an enchantment is missing from the configuration file, which I'll put into effect everywhere.

As for the issue with the PersistentDataContainer, You can make this a separate pull request, or retract your change with ArmorChangeEvent.

Thank you for the contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

resolution: awaiting response Awaiting a response.

Development

Successfully merging this pull request may close these issues.

2 participants