-
Notifications
You must be signed in to change notification settings - Fork 3
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
weeds #8
weeds #8
Conversation
@@ -108,7 +107,9 @@ | |||
case 1: { | |||
CropLoadCoreASM.cppASMlogger.info("Patching WeedingTrowel to accept custom Weeds"); | |||
String name = "onItemUseFirst"; | |||
String desc = !isObfuscated ? "(Lnet/minecraft/item/ItemStack;Lnet/minecraft/entity/player/EntityPlayer;Lnet/minecraft/world/World;IIIIFFF)Z" : "(Ladd;Lyz;Lahb;IIIIFFF)Z"; | |||
//String desc = !isObfuscated ? "(Lnet/minecraft/item/ItemStack;Lnet/minecraft/entity/player/EntityPlayer;Lnet/minecraft/world/World;IIIIFFF)Z" : "(Ladd;Lyz;Lahb;IIIIFFF)Z"; |
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.
This is the actual real change, without this commented out, the whole thing blows up IC2 (apparently because it replaces a deobfuscated name with an obfuscated one)
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.
Class names are deobfuscated regardless of environment. Using deobfuscated names never fails.
So the other if/then weren’t needed either? |
Method name checks are needed. Method desc checks are not needed. |
That of is course better be changed to mixin, because we have both ASM and mixins transforming TileCrop. (It's not impossible that this combination leads to crops breaking on Thermos). Anyway, this PR is ok, thanks for investigating the issue. |
They are if you’ve got multiple methods with the same name. Class names are obfuscated outside of dev, just depends when your ASM runs. |
Yeah, but the situation here is, croploadcore is trying to create a new invokestatic instruction instead of looking for an existing instruction. It doesn't care if deobf transformer has ran or not. At the end of transformation pipeline it'll always be deobfuscated, so it doesn't really matter if obfuscated names or deobf names are written. |
THIS NEEDS REVIEW!
By removing the obfuscation elvis/walrus it now loads and runs in dev AND prod.
But still not 100% certain that what I did is right.