mixin-cheatsheet
mixin-cheatsheet copied to clipboard
SpongePowered Mixin Cheat Sheet
Mixin Cheatsheet
What mixins should you use, for what purpose, and how exactly do they affect the code?
Note: the method modifications listed in these documents are what the code effectively does, not what the modified bytecode will actually look like. Mixin generates additional methods in the target classes that are inlined here.
Table of Contents
Injectors
-
@Inject
-
@Inject
, cancellable -
@Inject
, locals -
@Redirect
-
@Overwrite
-
@ModifyArg
-
@ModifyArgs
- ~~
@ModifyConstant
~~ -
@ModifyVariable
Non-Injectors
-
@Invoker
-
@Accessor
-
@Shadow
-
@Shadow
, final -
@Shadow
, anonymous class -
@At
-
@Unique
Other helpful docs
- Changing your mixin's priority
- Mixing into classes that may not exist at runtime