Skip to content

Instantly share code, notes, and snippets.

View Unh0lyTigg's full-sized avatar

Robert Allen Unh0lyTigg

View GitHub Profile
@Unh0lyTigg
Unh0lyTigg / Window.java
Created August 5, 2015 20:15
What I use for window management in lwjgl3.
import static org.lwjgl.glfw.Callbacks.glfwSetCallback;
import static org.lwjgl.glfw.Callbacks.releaseAllCallbacks;
import static org.lwjgl.glfw.GLFW.GLFWCursorEnterCallback;
import static org.lwjgl.glfw.GLFW.GLFWCursorPosCallback;
import static org.lwjgl.glfw.GLFW.GLFWDropCallback;
import static org.lwjgl.glfw.GLFW.GLFWFramebufferSizeCallback;
import static org.lwjgl.glfw.GLFW.GLFWKeyCallback;
import static org.lwjgl.glfw.GLFW.GLFWMouseButtonCallback;
import static org.lwjgl.glfw.GLFW.GLFWScrollCallback;
import static org.lwjgl.glfw.GLFW.GLFWWindowCloseCallback;

Keybase proof

I hereby claim:

  • I am Unh0lyTigg on github.
  • I am unh0ly_tigg (https://keybase.io/unh0ly_tigg) on keybase.
  • I have a public key whose fingerprint is 46EA 5B6E 4A4D 7298 3A9A 7FD5 67EF 369E 1643 089A

To claim this, I am signing this object:

plugins {
id 'net.minecraftforge.gradle.forge' version '2.0.2'
}
sourceCompatibility = 1.7
targetCompatibility = 1.7
version = '1.7.10.1'
group = 'unh0lytigg.sttv'
archivesBaseName = 'SacreficeToTheVoid'
{
"forge_marker": 1,
"defaults": {
"textures": {
"center": "rp:blocks/pipe_standard_center",
"connection_side": "rp:blocks/pipe_standard_connection_side",
"connection_end": "rp:blocks/pipe_standard_connection_end",
"color_overlay": "rp:blocks/pipe_overlay_none"
},
"model": "rp:pipe_center",
apply plugin: 'java'
apply plugin: 'eclipse'
apply plugin: 'maven'
sourceCompatibility = 1.8
targetCompatibility = 1.8
version = '<ommited>'
group = '<ommited>'
archivesBaseName = '<ommited>'
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_60]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_60]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_60]
at java.lang.reflect.Method.invoke(Method.java:497) ~[?:1.8.0_60]
at net.minecraft.launchwrapper.Launch.launch(Launch.java:135) [launchwrapper-1.11.jar:?]
at net.minecraft.launchwrapper.Launch.main(Launch.java:28) [launchwrapper-1.11.jar:?]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_60]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_60]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_60]
[16:27:27] [main/INFO]: Extra: [--noCoreSearch, --tweakClass, xyz.unh0lytigg.jsoncrops.tweaker.JCTweaker]
[16:27:27] [main/INFO]: Running with arguments: [--userProperties, {}, --assetsDir, C:/Users/Robert/.gradle/caches/minecraft/assets, --assetIndex, 1.9, --accessToken{REDACTED}, --version, 1.9, --noCoreSearch, --tweakClass, xyz.unh0lytigg.jsoncrops.tweaker.JCTweaker]
[16:27:27] [main/INFO]: Loading tweak class name xyz.unh0lytigg.jsoncrops.tweaker.JCTweaker
[16:27:27] [main/INFO]: Using primary tweak class name xyz.unh0lytigg.jsoncrops.tweaker.JCTweaker
[16:27:27] [main/INFO]: Calling tweak class xyz.unh0lytigg.jsoncrops.tweaker.JCTweaker
Hello from JCTweaker
[16:27:27] [main/INFO]: Launching wrapped minecraft {net.minecraft.client.main.Main}
[16:27:27] [main/ERROR]: Unable to launch
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_60]
package xyz.unh0lytigg.jsoncrops.transformer.impl;
import java.util.*;
import java.util.concurrent.atomic.*;
import java.util.function.*;
import org.objectweb.asm.*;
import org.objectweb.asm.tree.*;
import xyz.unh0lytigg.jsoncrops.transformer.*;
LabelNode: -1 (F_NEW)
LineNumberNode: -1 (F_NEW): 511 / [unknown_label]
MethodInsnNode: 184 (INVOKESTATIC)
net.minecraft.client.renderer.GlStateManager.disableAlpha()V
LabelNode: -1 (F_NEW)
LineNumberNode: -1 (F_NEW): 512 / [unknown_label]
VarInsnNode: 25 (ALOAD)
this
VarInsnNode: 21 (ILOAD)
1
ClassNode node = createNode(basicClass);
boolean change = false;
for (MethodNode method : node.methods) {
if ("<init>".equals(method.name)) {
InsnList instructions = method.instructions;
AbstractInsnNode needle = instructions.getLast();
do {
needle = needle.getPrevious();
} while (needle.getOpcode() != RETURN);
MethodNode mn = new MethodNode();