Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve mixin quality for Status Effect API #383

Open
wants to merge 3 commits into
base: 1.21
Choose a base branch
from

Conversation

OroArmor
Copy link
Member

Fixes a few crashes with this code. Should be fairly easy to backport to older versions if need be. I think some of the changes with StatusEffect -> Holder<StatusEffect> would need to be reverted.

@OroArmor OroArmor added bug Something isn't working library: entity Related to the entity library. t: refactor This proposes a refactor. s: tested This pull request has been tested and confirmed as working. labels Aug 23, 2024
…ity/effect/mixin/LivingEntityMixin.java

Co-authored-by: ix0rai <[email protected]>
@Mixin(LivingEntity.class)
// We want to make sure that our wrap operations are put before other mods, so that we wrap the vanilla call and not a mod's call.
// This is because we do not call the vanilla method, so any mod adding something will not be called.
@Mixin(value = LivingEntity.class, priority = 500)
Copy link
Member

Choose a reason for hiding this comment

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

it would probably be wise to set the default priority to around this number globally

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working library: entity Related to the entity library. s: tested This pull request has been tested and confirmed as working. t: refactor This proposes a refactor.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants