mirror of
https://gitlab.com/2009scape/rt4-client.git
synced 2025-12-12 09:30:22 -07:00
Refactored a bit of the connection process, added a GlobalConfig class to control behavior
This commit is contained in:
parent
ec83b1f868
commit
80c6ba05ff
94 changed files with 592 additions and 578 deletions
|
|
@ -89,26 +89,27 @@ public final class Static207 {
|
|||
public static int method3684() {
|
||||
try {
|
||||
if (Static82.anInt2231 == 0) {
|
||||
if (MonotonicClock.method5096() - 5000L < Static231.aLong174) {
|
||||
if (MonotonicClock.currentTimeMillis() - 5000L < Static231.aLong174) {
|
||||
return 0;
|
||||
}
|
||||
Static72.aClass212_3 = Static71.aClass213_3.method5120(Static143.aString4, Static208.anInt4784);
|
||||
Static15.aLong18 = MonotonicClock.method5096();
|
||||
System.out.println(Static208.worldListPort);
|
||||
Static72.aClass212_3 = Static71.signLink.openSocket(Static143.worldListHostname, Static208.worldListPort);
|
||||
Static15.aLong18 = MonotonicClock.currentTimeMillis();
|
||||
Static82.anInt2231 = 1;
|
||||
}
|
||||
if (Static15.aLong18 + 30000L < MonotonicClock.method5096()) {
|
||||
if (Static15.aLong18 + 30000L < MonotonicClock.currentTimeMillis()) {
|
||||
return Static10.method347(1000);
|
||||
}
|
||||
@Pc(82) int local82;
|
||||
@Pc(124) int local124;
|
||||
if (Static82.anInt2231 == 1) {
|
||||
if (Static72.aClass212_3.anInt5925 == 2) {
|
||||
if (Static72.aClass212_3.status == 2) {
|
||||
return Static10.method347(1001);
|
||||
}
|
||||
if (Static72.aClass212_3.anInt5925 != 1) {
|
||||
if (Static72.aClass212_3.status != 1) {
|
||||
return -1;
|
||||
}
|
||||
Static124.aClass95_2 = new BufferedSocket((Socket) Static72.aClass212_3.anObject6, Static71.aClass213_3);
|
||||
Static124.aClass95_2 = new BufferedSocket((Socket) Static72.aClass212_3.anObject6, Static71.signLink);
|
||||
Static6.aClass3_Sub15_Sub1_1.offset = 0;
|
||||
Static72.aClass212_3 = null;
|
||||
local82 = 0;
|
||||
|
|
@ -117,14 +118,14 @@ public final class Static207 {
|
|||
}
|
||||
Static6.aClass3_Sub15_Sub1_1.p1(255);
|
||||
Static6.aClass3_Sub15_Sub1_1.p4(local82);
|
||||
Static124.aClass95_2.method2830(Static6.aClass3_Sub15_Sub1_1.data, Static6.aClass3_Sub15_Sub1_1.offset);
|
||||
Static124.aClass95_2.write(Static6.aClass3_Sub15_Sub1_1.data, Static6.aClass3_Sub15_Sub1_1.offset);
|
||||
if (Static11.aClass62_1 != null) {
|
||||
Static11.aClass62_1.method3571();
|
||||
}
|
||||
if (Static147.aClass62_2 != null) {
|
||||
Static147.aClass62_2.method3571();
|
||||
}
|
||||
local124 = Static124.aClass95_2.method2828();
|
||||
local124 = Static124.aClass95_2.read();
|
||||
if (Static11.aClass62_1 != null) {
|
||||
Static11.aClass62_1.method3571();
|
||||
}
|
||||
|
|
@ -137,12 +138,12 @@ public final class Static207 {
|
|||
Static82.anInt2231 = 2;
|
||||
}
|
||||
if (Static82.anInt2231 == 2) {
|
||||
if (Static124.aClass95_2.method2831() < 2) {
|
||||
if (Static124.aClass95_2.available() < 2) {
|
||||
return -1;
|
||||
}
|
||||
Static116.anInt2961 = Static124.aClass95_2.method2828();
|
||||
Static116.anInt2961 = Static124.aClass95_2.read();
|
||||
Static116.anInt2961 <<= 0x8;
|
||||
Static116.anInt2961 += Static124.aClass95_2.method2828();
|
||||
Static116.anInt2961 += Static124.aClass95_2.read();
|
||||
Static82.anInt2231 = 3;
|
||||
Static141.anInt3469 = 0;
|
||||
Static229.aByteArray70 = new byte[Static116.anInt2961];
|
||||
|
|
@ -150,7 +151,7 @@ public final class Static207 {
|
|||
if (Static82.anInt2231 != 3) {
|
||||
return -1;
|
||||
}
|
||||
local82 = Static124.aClass95_2.method2831();
|
||||
local82 = Static124.aClass95_2.available();
|
||||
if (local82 < 1) {
|
||||
return -1;
|
||||
}
|
||||
|
|
@ -175,7 +176,7 @@ public final class Static207 {
|
|||
Static127.anInt3132 = 0;
|
||||
Static82.anInt2231 = 0;
|
||||
Static229.aByteArray70 = null;
|
||||
Static231.aLong174 = MonotonicClock.method5096();
|
||||
Static231.aLong174 = MonotonicClock.currentTimeMillis();
|
||||
return 0;
|
||||
} else {
|
||||
return Static10.method347(1002);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue