This commit is contained in:
Lucwousin
2019-10-31 16:57:45 +01:00
parent 8b7eaf23f1
commit e7a1983158
344 changed files with 41280 additions and 41078 deletions

View File

@@ -1,38 +1,30 @@
import java.io.IOException;
import java.net.Socket;
import java.net.URL;
import net.runelite.mapping.Export;
import net.runelite.mapping.Implements;
import net.runelite.mapping.ObfuscatedGetter;
import net.runelite.mapping.ObfuscatedName;
import net.runelite.mapping.ObfuscatedSignature;
@ObfuscatedName("kd")
@ObfuscatedName("kg")
@Implements("BufferedNetSocket")
public class BufferedNetSocket extends AbstractSocket {
@ObfuscatedName("w")
@ObfuscatedGetter(
intValue = 966969419
)
@Export("cacheGamebuild")
public static int cacheGamebuild;
@ObfuscatedName("z")
@ObfuscatedName("a")
@Export("socket")
Socket socket;
@ObfuscatedName("n")
@ObfuscatedName("t")
@ObfuscatedSignature(
signature = "Lkx;"
signature = "Lkl;"
)
@Export("source")
BufferedSource source;
@ObfuscatedName("v")
@ObfuscatedName("n")
@ObfuscatedSignature(
signature = "Lkv;"
signature = "Lkn;"
)
@Export("sink")
BufferedSink sink;
public BufferedNetSocket(Socket var1, int var2, int var3) throws IOException {
BufferedNetSocket(Socket var1, int var2, int var3) throws IOException {
this.socket = var1;
this.socket.setSoTimeout(30000);
this.socket.setTcpNoDelay(true);
@@ -42,10 +34,10 @@ public class BufferedNetSocket extends AbstractSocket {
this.sink = new BufferedSink(this.socket.getOutputStream(), var3);
}
@ObfuscatedName("z")
@ObfuscatedName("a")
@ObfuscatedSignature(
signature = "(B)V",
garbageValue = "-119"
signature = "(I)V",
garbageValue = "1632517280"
)
@Export("close")
public void close() {
@@ -59,50 +51,50 @@ public class BufferedNetSocket extends AbstractSocket {
this.source.close();
}
@ObfuscatedName("n")
@ObfuscatedName("t")
@ObfuscatedSignature(
signature = "(I)I",
garbageValue = "1784126558"
signature = "(B)I",
garbageValue = "0"
)
@Export("readUnsignedByte")
public int readUnsignedByte() throws IOException {
return this.source.readUnsignedByte();
}
@ObfuscatedName("v")
@ObfuscatedName("n")
@ObfuscatedSignature(
signature = "(B)I",
garbageValue = "3"
garbageValue = "-1"
)
@Export("available")
public int available() throws IOException {
return this.source.available();
}
@ObfuscatedName("u")
@ObfuscatedName("q")
@ObfuscatedSignature(
signature = "(II)Z",
garbageValue = "-336706705"
garbageValue = "1174929907"
)
@Export("isAvailable")
public boolean isAvailable(int var1) throws IOException {
return this.source.isAvailable(var1);
}
@ObfuscatedName("r")
@ObfuscatedName("v")
@ObfuscatedSignature(
signature = "([BIII)I",
garbageValue = "-2035668362"
garbageValue = "1681485484"
)
@Export("read")
public int read(byte[] var1, int var2, int var3) throws IOException {
return this.source.read(var1, var2, var3);
}
@ObfuscatedName("q")
@ObfuscatedName("c")
@ObfuscatedSignature(
signature = "([BIIB)V",
garbageValue = "-68"
signature = "([BIII)V",
garbageValue = "1989353375"
)
@Export("write")
public void write(byte[] var1, int var2, int var3) throws IOException {
@@ -112,44 +104,4 @@ public class BufferedNetSocket extends AbstractSocket {
protected void finalize() {
this.close();
}
@ObfuscatedName("z")
@ObfuscatedSignature(
signature = "(I)Z",
garbageValue = "2009022285"
)
@Export("loadWorlds")
static boolean loadWorlds() {
try {
if (class51.World_request == null) {
class51.World_request = Client.urlRequester.request(new URL(WorldMapSectionType.field150));
} else if (class51.World_request.isDone()) {
byte[] var0 = class51.World_request.getResponse();
Buffer var1 = new Buffer(var0);
var1.readInt();
World.World_count = var1.readUnsignedShort();
World.World_worlds = new World[World.World_count];
World var3;
for (int var2 = 0; var2 < World.World_count; var3.index = var2++) {
var3 = World.World_worlds[var2] = new World();
var3.id = var1.readUnsignedShort();
var3.properties = var1.readInt();
var3.host = var1.readStringCp1252NullTerminated();
var3.activity = var1.readStringCp1252NullTerminated();
var3.location = var1.readUnsignedByte();
var3.population = var1.readShort();
}
WorldMapData_0.sortWorlds(World.World_worlds, 0, World.World_worlds.length - 1, World.World_sortOption1, World.World_sortOption2);
class51.World_request = null;
return true;
}
} catch (Exception var4) {
var4.printStackTrace();
class51.World_request = null;
}
return false;
}
}