You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Forestry Worktable (time limit and move recipe to start)
TiCon crafting stations (time limit and move recipe to start, if possible)
AE2
ASM patch for generic crafting table, and for 2x2 crafting grid
The text was updated successfully, but these errors were encountered:
public boolean injectMethod(String aMethodName, ClassWriter cw) {
MethodVisitor mv;
boolean didInject = false;
FMLRelaunchLog.log("[GT++ ASM] LWJGL Keybinding index out of bounds fix", Level.INFO,
"Injecting " + aMethodName + ".");
if (aMethodName.equals("getKeyName")) {
mv = cw.visitMethod(ACC_PUBLIC + ACC_STATIC + ACC_SYNCHRONIZED, "getKeyName", "(I)Ljava/lang/String;", null,
null);
mv.visitCode();
Label l0 = new Label();
mv.visitLabel(l0);
mv.visitLineNumber(49, l0);
mv.visitVarInsn(ILOAD, 0);
mv.visitMethodInsn(INVOKESTATIC, "gtPlusPlus/preloader/asm/transformers/ClassTransformer_LWJGL_Keyboard",
"getKeyName", "(I)Ljava/lang/String;", false);
mv.visitInsn(ARETURN);
Label l1 = new Label();
mv.visitLabel(l1);
mv.visitLocalVariable("key", "I", null, l0, l1, 0);
mv.visitMaxs(1, 1);
mv.visitEnd();
didInject = true;
}
FMLRelaunchLog.log("[GT++ ASM] LWJGL Keybinding index out of bounds fix", Level.INFO, "Method injection complete.");
return didInject;
}
While that kinda looks a tad ugly, it's all generated code..
from mv = to mv.visitEnd()
Just replaces the entire method with a static call to return mine instead.
LWJGL ain't getting any fixes, lol.
mv.visitLabel(l0);
mv.visitLineNumber(49, l0);
Are only required for the JVM to print correct stack information.. so you can skip it if you're lazy and writing by hand.
Forestry Worktable (time limit and move recipe to start)
TiCon crafting stations (time limit and move recipe to start, if possible)
AE2
ASM patch for generic crafting table, and for 2x2 crafting grid
The text was updated successfully, but these errors were encountered: