-
-
Notifications
You must be signed in to change notification settings - Fork 189
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
Backend: Add Kotlin mixins #1981
base: beta
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
worked for me
This pull request has conflicts with the base branch "beta". Please resolve those so we can test out your changes. |
# Conflicts: # src/main/java/at/hannibal2/skyhanni/mixins/hooks/GuiContainerHook.kt
Conflicts have been resolved! 🎉 |
This pull request has conflicts with the base branch "beta". Please resolve those so we can test out your changes. |
# Conflicts: # src/main/java/at/hannibal2/skyhanni/mixins/hooks/GuiContainerHook.kt
Conflicts have been resolved! 🎉 |
This pull request has conflicts with the base branch "beta". Please resolve those so we can test out your changes. |
What
This adds an annotation processor to allow for a new form of mixin creation called
KMixin
these allow for a more defined specified control of mixins, unlike normal mixins these are written in Kotlin only.The following is the specification of the current KMixin.
@KMixin
annotation or@KPseudoMixin
@KSelf
annotation along with a variable and the type of the class@KShadow
and then the name of the field and then the type@KShadow(ShadowKind.METHOD)
to shadow a method, to do this you must have the type be a function of the arguments and return of the method you want to shadow.@KStatic
annotation@KRedirectCall
annotation@KRedirectField
annotation, depending on the return type and the arguments it will determine if this is a redirect of a get or put field.@KInject
annotation.@KInjectAt
annotation.Note
More injectors can easily be added by adding a new
InjectorSerializer
to theInjectors.serializers
mapChangelog Technical Details