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

Replace RunAroundLikeCrazyGoalMixin::tick overwrite with injects #4151

Merged
merged 1 commit into from
Nov 14, 2024

Conversation

nelind3
Copy link
Contributor

@nelind3 nelind3 commented Nov 14, 2024

Updated another outdated overwrite that I noticed while working on Loofah.

@aromaa
Copy link
Member

aromaa commented Nov 14, 2024

This should be easy to change to just use redirects instead and avoid the overwrite?

@nelind3
Copy link
Contributor Author

nelind3 commented Nov 14, 2024

Yea the reason i was even working on this is because I'm rewriting it like that since the overwrite is conflicting with Architechtury API on fabric. I can update this PR with the rewritten version once I finish that after dinner if wanted.

@aromaa
Copy link
Member

aromaa commented Nov 14, 2024

We would like to get rid of overwrites as much as possible.

@@ -42,6 +43,8 @@
@Mixin(Goal.class)
public abstract class GoalMixin implements GoalBridge {

@Shadow protected abstract int adjustedTickDelay(int $$0);
Copy link
Member

Choose a reason for hiding this comment

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

I'd recommend explicitly naming the method shadowed shadow$adjustedTickDelay so it's clearer

@nelind3 nelind3 changed the title Update RunAroundLikeCrazyGoalMixin::tick to match vanilla impl Replace RunAroundLikeCrazyGoalMixin::tick overwrite with injects Nov 14, 2024
@nelind3
Copy link
Contributor Author

nelind3 commented Nov 14, 2024

There we go now it's replacing the overwrites with injects instead

Copy link
Member

@aromaa aromaa left a comment

Choose a reason for hiding this comment

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

Added few nits, other than that LGTM.

Thank you again, these are very much appreciated :)

@nelind3
Copy link
Contributor Author

nelind3 commented Nov 14, 2024

There you go :)

@aromaa aromaa merged commit bc6baad into SpongePowered:api-12 Nov 14, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants