gradle: add properties and modify injected-client (#1145)

* add implementation for getItemCount

* Ignore build directory in project root

* save injector results as class files

* package injected-client for shading into client

* auto-updating properties

* fix run task

* shade injected-client into jar
This commit is contained in:
ThatGamerBlue
2019-07-27 20:02:57 +01:00
committed by Ganom
parent 207c65c325
commit 2ba1c7f80b
14 changed files with 209 additions and 172 deletions

View File

@@ -26,6 +26,9 @@ package net.runelite.injector;
import java.io.File;
import java.io.IOException;
import com.google.common.io.Files;
import net.runelite.asm.ClassFile;
import net.runelite.asm.ClassGroup;
import net.runelite.deob.util.JarUtil;
@@ -69,7 +72,13 @@ public class Injector
private void save(File out) throws IOException
{
JarUtil.saveJar(vanilla, out);
out.mkdirs();
for (ClassFile cf : vanilla.getClasses())
{
File f = new File(out, cf.getClassName() + ".class");
byte[] data = JarUtil.writeClass(vanilla, cf);
Files.write(data, f);
}
}