Forked from Deamon5550/gist:6ecac09683eb7dd56492
Last active
August 29, 2015 14:11
-
-
Save gabizou/92bd3fd9739c1cb3b712 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
interface ItemType | |
{ | |
int getMaxDamage(); | |
} | |
class net.minecraft.src.Item | |
{ | |
... | |
int getMaxDamage() //becomes func_24925_a | |
{ | |
return this.maxDamage; | |
} | |
... | |
} | |
@Mixin(Item.class) | |
@Implements(@Interface(iface = ItemType.class, prefix = "sp$")) | |
abstract class MixinItemType | |
{ | |
@Shadow | |
public abstract int getMaxDamage(); | |
public int sp$getMaxDamage() | |
{ | |
return getMaxDamage(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment