More accurate Buffer naming, renamed allocation arrays

This commit is contained in:
Pazaz 2022-06-15 13:20:22 -04:00
parent 5e66d3ba01
commit c5ef44dfcb
58 changed files with 891 additions and 896 deletions

View file

@ -86,17 +86,17 @@ public final class AnimFrame {
if ((attributes & 0x1) == 0) {
tempX[len] = defaultValue;
} else {
tempX[len] = (short) buffer.gSmart1or2s();
tempX[len] = (short) buffer.gsmart();
}
if ((attributes & 0x2) == 0) {
tempY[len] = defaultValue;
} else {
tempY[len] = (short) buffer.gSmart1or2s();
tempY[len] = (short) buffer.gsmart();
}
if ((attributes & 0x4) == 0) {
tempZ[len] = defaultValue;
} else {
tempZ[len] = (short) buffer.gSmart1or2s();
tempZ[len] = (short) buffer.gsmart();
}
tempFlags[len] = (byte) (attributes >>> 3 & 0x3);
if (type == 2) {

View file

@ -141,7 +141,7 @@ public final class BasType {
@Pc(306) int bodyId = arg1.g1();
this.modelRotateTranslate[bodyId] = new int[6];
for (@Pc(314) int type = 0; type < 6; type++) {
this.modelRotateTranslate[bodyId][type] = arg1.g2s();
this.modelRotateTranslate[bodyId][type] = arg1.g2b();
}
} else if (opcode == 29) {
this.anInt1038 = arg1.g1();
@ -152,13 +152,13 @@ public final class BasType {
} else if (opcode == 32) {
this.anInt1040 = arg1.g2();
} else if (opcode == 33) {
this.anInt1064 = arg1.g2s();
this.anInt1064 = arg1.g2b();
} else if (opcode == 34) {
this.anInt1065 = arg1.g1();
} else if (opcode == 35) {
this.anInt1063 = arg1.g2();
} else if (opcode == 36) {
this.anInt1041 = arg1.g2s();
this.anInt1041 = arg1.g2b();
} else if (opcode == 37) {
this.anInt1032 = arg1.g1();
} else if (opcode == 38) {

View file

@ -1,83 +1,191 @@
package rt4;
import java.math.BigInteger;
import org.openrs2.deob.annotation.OriginalArg;
import org.openrs2.deob.annotation.OriginalClass;
import org.openrs2.deob.annotation.OriginalMember;
import org.openrs2.deob.annotation.Pc;
import java.math.BigInteger;
// Buffer access nomenclature:
// Endianness (optional)
// (none) - big (DCBA)
// i - "inverse" (little) (ABCD)
// m - "middle" (CDAB) - not an authentic name, no clue on original
// im - "inverse-middle" (reverse) (BADC) - not an authentic name, jagex may call this "_alt3"
// Operation
// g - get
// p - put
// rsadec - Decrypt RSA
// tinydec - Decrypt XTEA
// Type
// bytes or special type i.e. 8, VarLong, Bytes, jstr, ...
// Endianness (optional)
// (none) - Big Endian
// le - Little Endian
// me - "Middle" Endian, only used with ints
// rme - "Reverse-Middle" Endian, only used with ints
// Signedness
// (none) - Unsigned
// s - Signed
// # of bytes or special type i.e. 8, VarLong, Float, jstr, ...
// Signedness (optional)
// (none) - unsigned
// b / s - "byte" / signed (both allow overflow) - jagex mixed usage i.e. gsmarts and g1b...
// Transformation (optional)
// (none) - no change
// add - add 128 to the lowest byte
// sub - subtract lowest byte from 128
// neg - negate, only used on bytes
// Rev - reverse, only used on byte arrays
// Types:
// 1 - byte
// 2 - short
// 3 - medium
// 4 - int
// 8 - long
// Float - 4-byte float
// Smart1or2 - byte if below 128, short otherwise, holds exactly half the capacity (0-128, 0-32768)
// Bytes - byte array
// jstr - Jagex string (null terminated)
// VarLong - variable long
// VarInt - variable int
// Crc32 - checksum
@OriginalClass("client!wa")
public class Buffer extends Node {
@OriginalMember(owner = "client!wi", name = "X", descriptor = "[[B")
public static final byte[][] allocatedMin = new byte[1000][];
@OriginalMember(owner = "client!bb", name = "t", descriptor = "[[B")
public static final byte[][] allocatedMid = new byte[250][];
@OriginalMember(owner = "client!dc", name = "db", descriptor = "[[B")
public static final byte[][] allocatedMax = new byte[50][];
@OriginalMember(owner = "client!ja", name = "j", descriptor = "I")
public static int allocatedMinCount = 0;
@OriginalMember(owner = "client!ug", name = "r", descriptor = "I")
public static int allocatedMidCount = 0;
@OriginalMember(owner = "client!sd", name = "T", descriptor = "I")
public static int allocatedMaxCount = 0;
@OriginalMember(owner = "client!wa", name = "y", descriptor = "[B")
public byte[] data;
public byte[] data;
@OriginalMember(owner = "client!wa", name = "T", descriptor = "I")
public int offset;
@OriginalMember(owner = "client!wa", name = "T", descriptor = "I")
public int offset;
@OriginalMember(owner = "client!wa", name = "<init>", descriptor = "(I)V")
public Buffer(@OriginalArg(0) int size) {
this.data = Static228.allocate(size);
this.offset = 0;
}
@OriginalMember(owner = "client!wa", name = "<init>", descriptor = "([B)V")
public Buffer(@OriginalArg(0) byte[] src) {
this.offset = 0;
this.data = src;
}
@OriginalMember(owner = "client!si", name = "a", descriptor = "(BLclient!na;)I")
public static int getStringLength(@OriginalArg(1) JagString arg0) {
return arg0.length() + 1;
@OriginalMember(owner = "client!wa", name = "<init>", descriptor = "(I)V")
public Buffer(@OriginalArg(0) int size) {
this.data = allocate(size);
this.offset = 0;
}
@OriginalMember(owner = "client!nf", name = "a", descriptor = "(II[BB)I")
public static int crc32(@OriginalArg(0) int arg0, @OriginalArg(1) int arg1, @OriginalArg(2) byte[] arg2) {
@Pc(5) int local5 = -1;
for (@Pc(15) int local15 = arg0; local15 < arg1; local15++) {
local5 = local5 >>> 8 ^ HuffmanCodec.anIntArray175[(local5 ^ arg2[local15]) & 0xFF];
}
return ~local5;
@OriginalMember(owner = "client!wa", name = "<init>", descriptor = "([B)V")
public Buffer(@OriginalArg(0) byte[] src) {
this.offset = 0;
this.data = src;
}
@OriginalMember(owner = "client!sh", name = "a", descriptor = "(II)[B")
public static synchronized byte[] allocate(@OriginalArg(1) int length) {
@Pc(22) byte[] data;
if (length == 100 && allocatedMinCount > 0) {
data = allocatedMin[--allocatedMinCount];
allocatedMin[allocatedMinCount] = null;
return data;
} else if (length == 5000 && allocatedMidCount > 0) {
data = allocatedMid[--allocatedMidCount];
allocatedMid[allocatedMidCount] = null;
return data;
} else if (length == 30000 && allocatedMaxCount > 0) {
data = allocatedMax[--allocatedMaxCount];
allocatedMax[allocatedMaxCount] = null;
return data;
} else {
return new byte[length];
}
}
@OriginalMember(owner = "client!nf", name = "a", descriptor = "(II[BB)I")
public static int crc32(@OriginalArg(0) int offset, @OriginalArg(1) int size, @OriginalArg(2) byte[] src) {
@Pc(5) int crc = -1;
for (@Pc(15) int i = offset; i < size; i++) {
crc = crc >>> 8 ^ HuffmanCodec.crctable[(crc ^ src[i]) & 0xFF];
}
return ~crc;
}
@OriginalMember(owner = "client!fk", name = "a", descriptor = "([BIZ)I")
public static int crc32(@OriginalArg(0) byte[] arg0, @OriginalArg(1) int arg1) {
return crc32(0, arg1, arg0);
public static int crc32(@OriginalArg(0) byte[] src, @OriginalArg(1) int size) {
return crc32(0, size, src);
}
@OriginalMember(owner = "client!wa", name = "c", descriptor = "(BI)I")
public final int addcrc(@OriginalArg(1) int off) {
@Pc(16) int checksum = crc32(off, this.offset, this.data);
this.p4(checksum);
return checksum;
}
@OriginalMember(owner = "client!wa", name = "a", descriptor = "([IIII)V")
public final void tinydec(@OriginalArg(0) int[] key, @OriginalArg(3) int len) {
@Pc(6) int start = this.offset;
this.offset = 5;
@Pc(16) int blocks = (len - 5) / 8;
for (@Pc(18) int i = 0; i < blocks; i++) {
@Pc(23) int sum = 0xc6ef3720;
@Pc(27) int v0 = this.g4();
@Pc(31) int v1 = this.g4();
@Pc(33) int rounds = 32;
while (rounds-- > 0) {
v1 -= key[sum >>> 11 & 0x3] + sum ^ v0 + (v0 >>> 5 ^ v0 << 4);
sum -= 0x9e3779b9;
v0 -= (v1 >>> 5 ^ v1 << 4) + v1 ^ key[sum & 0x3] + sum;
}
this.offset -= 8;
this.p4(v0);
this.p4(v1);
}
this.offset = start;
}
@OriginalMember(owner = "client!wa", name = "a", descriptor = "(Ljava/math/BigInteger;Ljava/math/BigInteger;I)V")
public final void rsaenc(@OriginalArg(0) BigInteger exp, @OriginalArg(1) BigInteger mod) {
@Pc(2) int len = this.offset;
this.offset = 0;
@Pc(8) byte[] plaintextBytes = new byte[len];
this.gdata(len, plaintextBytes);
@Pc(23) BigInteger plaintext = new BigInteger(plaintextBytes);
@Pc(28) BigInteger ciphertext = plaintext.modPow(exp, mod);
@Pc(38) byte[] ciphertextBytes = ciphertext.toByteArray();
this.offset = 0;
this.p1(ciphertextBytes.length);
this.pdata(ciphertextBytes, ciphertextBytes.length);
}
// get (read) methods
@OriginalMember(owner = "client!wa", name = "p", descriptor = "(B)I")
public final int g1() {
return this.data[this.offset++] & 0xFF;
}
@OriginalMember(owner = "client!wa", name = "g", descriptor = "(B)I")
public final int g1add() {
return this.data[this.offset++] - 128 & 0xFF;
}
@OriginalMember(owner = "client!wa", name = "g", descriptor = "(Z)I")
public final int g1neg() {
return -this.data[this.offset++] & 0xFF;
}
@OriginalMember(owner = "client!wa", name = "d", descriptor = "(Z)B")
public final byte g1b() {
return this.data[this.offset++];
}
@OriginalMember(owner = "client!wa", name = "c", descriptor = "(Z)I")
public final int g1sub() {
return 128 - this.data[this.offset++] & 0xFF;
}
@OriginalMember(owner = "client!wa", name = "n", descriptor = "(I)B")
public final byte g1badd() {
return (byte) (this.data[this.offset++] - 128);
}
@OriginalMember(owner = "client!wa", name = "i", descriptor = "(B)B")
public final byte g1bneg() {
return (byte) -this.data[this.offset++];
}
@OriginalMember(owner = "client!wa", name = "b", descriptor = "(Z)B")
public final byte g1bsub() {
return (byte) (128 - this.data[this.offset++]);
}
@OriginalMember(owner = "client!wa", name = "c", descriptor = "(I)I")
@ -86,170 +194,98 @@ public class Buffer extends Node {
return ((this.data[this.offset - 2] & 0xFF) << 8) + (this.data[this.offset - 1] & 0xFF);
}
@OriginalMember(owner = "client!wa", name = "b", descriptor = "(II)V")
public final void p4(@OriginalArg(1) int value) {
this.data[this.offset++] = (byte) (value >> 24);
this.data[this.offset++] = (byte) (value >> 16);
this.data[this.offset++] = (byte) (value >> 8);
this.data[this.offset++] = (byte) value;
@OriginalMember(owner = "client!wa", name = "g", descriptor = "(I)I")
public final int g2add() {
this.offset += 2;
return ((this.data[this.offset - 2] & 0xFF) << 8) + (this.data[this.offset - 1] - 128 & 0xFF);
}
@OriginalMember(owner = "client!wa", name = "a", descriptor = "(IIJ)V")
public final void pVarLong(@OriginalArg(1) int size, @OriginalArg(2) long value) {
@Pc(2) int bytes = size - 1;
if (bytes < 0 || bytes > 7) {
throw new IllegalArgumentException();
@OriginalMember(owner = "client!wa", name = "l", descriptor = "(B)I")
public final int g2b() {
this.offset += 2;
@Pc(27) int value = ((this.data[this.offset - 2] & 0xFF) << 8) + (this.data[this.offset - 1] & 0xFF);
if (value > 32767) {
value -= 0x10000;
}
for (@Pc(27) int shift = bytes * 8; shift >= 0; shift -= 8) {
this.data[this.offset++] = (byte) (value >> shift);
}
}
@OriginalMember(owner = "client!wa", name = "a", descriptor = "(JI)V")
public final void p8(@OriginalArg(0) long value) {
this.data[this.offset++] = (byte) (value >> 56);
this.data[this.offset++] = (byte) (value >> 48);
this.data[this.offset++] = (byte) (value >> 40);
this.data[this.offset++] = (byte) (value >> 32);
this.data[this.offset++] = (byte) (value >> 24);
this.data[this.offset++] = (byte) (value >> 16);
this.data[this.offset++] = (byte) (value >> 8);
this.data[this.offset++] = (byte) value;
}
@OriginalMember(owner = "client!wa", name = "d", descriptor = "(B)I")
public final int gVarInt() {
@Pc(12) byte b = this.data[this.offset++];
@Pc(24) int value = 0;
while (b < 0) {
value = (b & 0x7F | value) << 7;
b = this.data[this.offset++];
}
return b | value;
}
@OriginalMember(owner = "client!wa", name = "c", descriptor = "(II)V")
public final void p4len(@OriginalArg(1) int len) {
this.data[this.offset - len - 4] = (byte) (len >> 24);
this.data[this.offset - len - 3] = (byte) (len >> 16);
this.data[this.offset - len - 2] = (byte) (len >> 8);
this.data[this.offset - len - 1] = (byte) len;
}
@OriginalMember(owner = "client!wa", name = "d", descriptor = "(II)V")
public final void p1sub(@OriginalArg(1) int value) {
this.data[this.offset++] = (byte) (128 - value);
}
@OriginalMember(owner = "client!wa", name = "a", descriptor = "(ILclient!na;)V")
public final void pjstr(@OriginalArg(1) JagString value) {
this.offset += value.encodeString(this.data, this.offset, value.length());
this.data[this.offset++] = 0;
return value;
}
@OriginalMember(owner = "client!wa", name = "d", descriptor = "(I)I")
public final int g2sadd() {
public final int g2badd() {
this.offset += 2;
@Pc(34) int value = ((this.data[this.offset - 2] & 0xFF) << 8) + (this.data[this.offset - 1] - 128 & 0xFF);
if (value > 32767) {
value -= 65536;
value -= 0x10000;
}
return value;
}
@OriginalMember(owner = "client!wa", name = "i", descriptor = "(I)I")
public final int ig2() {
this.offset += 2;
return ((this.data[this.offset - 1] & 0xFF) << 8) + (this.data[this.offset - 2] & 0xFF);
}
@OriginalMember(owner = "client!wa", name = "m", descriptor = "(B)I")
public final int ig2b() {
this.offset += 2;
@Pc(38) int value = (this.data[this.offset - 2] & 0xFF) + ((this.data[this.offset - 1] & 0xFF) << 8);
if (value > 32767) {
value -= 0x10000;
}
return value;
}
@OriginalMember(owner = "client!wa", name = "k", descriptor = "(B)I")
public final int ig2add() {
this.offset += 2;
return ((this.data[this.offset - 1] & 0xFF) << 8) + (this.data[this.offset - 2] - 128 & 0xFF);
}
@OriginalMember(owner = "client!wa", name = "m", descriptor = "(I)I")
public final int ig2badd() {
this.offset += 2;
@Pc(34) int value = ((this.data[this.offset - 1] & 0xFF) << 8) + (this.data[this.offset - 2] - 128 & 0xFF);
if (value > 32767) {
value -= 0x10000;
}
return value;
}
@OriginalMember(owner = "client!wa", name = "n", descriptor = "(B)I")
public final int g3() {
this.offset += 3;
return ((this.data[this.offset - 3] & 0xFF) << 16) + ((this.data[this.offset - 2] << 8 & 0xFF00) + (this.data[this.offset - 1] & 0xFF));
}
@OriginalMember(owner = "client!wa", name = "h", descriptor = "(B)I")
public final int ig3() {
this.offset += 3;
return (((this.data[this.offset - 1] & 0xFF) << 16) + (this.data[this.offset - 2] & 0xFF) << 8) + (this.data[this.offset - 3] & 0xFF);
}
@OriginalMember(owner = "client!wa", name = "e", descriptor = "(I)I")
public final int g4() {
this.offset += 4;
return ((this.data[this.offset - 4] & 0xFF) << 24) + ((this.data[this.offset - 3] & 0xFF) << 16) + ((this.data[this.offset - 2] & 0xFF) << 8) + (this.data[this.offset - 1] & 0xFF);
}
@OriginalMember(owner = "client!wa", name = "b", descriptor = "(Z)B")
public final byte g1sub() {
return (byte) (128 - this.data[this.offset++]);
@OriginalMember(owner = "client!wa", name = "l", descriptor = "(I)I")
public final int ig4() {
this.offset += 4;
return ((this.data[this.offset - 1] & 0xFF) << 24) + ((this.data[this.offset - 2] & 0xFF) << 16) + ((this.data[this.offset - 3] & 0xFF) << 8) + (this.data[this.offset - 4] & 0xFF);
}
@OriginalMember(owner = "client!wa", name = "f", descriptor = "(B)Lclient!na;")
public final JagString gjstrFast() {
if (this.data[this.offset] == 0) {
this.offset++;
return null;
} else {
return this.gjstr();
}
@OriginalMember(owner = "client!wa", name = "o", descriptor = "(B)I")
public final int mg4() {
this.offset += 4;
return ((this.data[this.offset - 3] & 0xFF) << 24) + ((this.data[this.offset - 4] & 0xFF) << 16) + ((this.data[this.offset - 1] & 0xFF) << 8) + (this.data[this.offset - 2] & 0xFF);
}
@OriginalMember(owner = "client!wa", name = "g", descriptor = "(B)I")
public final int g1add() {
return this.data[this.offset++] - 128 & 0xFF;
}
@OriginalMember(owner = "client!wa", name = "a", descriptor = "(BI)V")
public final void p1(@OriginalArg(1) int value) {
this.data[this.offset++] = (byte) value;
}
@OriginalMember(owner = "client!wa", name = "a", descriptor = "([BIII)V")
public final void pBytes(@OriginalArg(0) byte[] src, @OriginalArg(2) int len) {
for (@Pc(7) int i = 0; i < len; i++) {
this.data[this.offset++] = src[i];
}
}
@OriginalMember(owner = "client!wa", name = "c", descriptor = "(Z)I")
public final int g1ssub() {
return 128 - this.data[this.offset++] & 0xFF;
}
@OriginalMember(owner = "client!wa", name = "h", descriptor = "(B)I")
public final int g3le() {
this.offset += 3;
return (((this.data[this.offset - 1] & 0xFF) << 16) + (this.data[this.offset - 2] & 0xFF) << 8) + (this.data[this.offset - 3] & 0xFF);
}
@OriginalMember(owner = "client!wa", name = "f", descriptor = "(I)J")
public final long g8() {
@Pc(11) long low = (long) this.g4() & 0xFFFFFFFFL;
@Pc(18) long high = (long) this.g4() & 0xFFFFFFFFL;
return high + (low << 32);
}
@OriginalMember(owner = "client!wa", name = "e", descriptor = "(II)V")
public final void p4le(@OriginalArg(0) int value) {
this.data[this.offset++] = (byte) value;
this.data[this.offset++] = (byte) (value >> 8);
this.data[this.offset++] = (byte) (value >> 16);
this.data[this.offset++] = (byte) (value >> 24);
}
@OriginalMember(owner = "client!wa", name = "g", descriptor = "(I)I")
public final int g2sub() {
this.offset += 2;
return ((this.data[this.offset - 2] & 0xFF) << 8) + (this.data[this.offset - 1] - 128 & 0xFF);
}
@OriginalMember(owner = "client!wa", name = "f", descriptor = "(II)V")
public final void p4me(@OriginalArg(1) int value) {
this.data[this.offset++] = (byte) (value >> 16);
this.data[this.offset++] = (byte) (value >> 24);
this.data[this.offset++] = (byte) value;
this.data[this.offset++] = (byte) (value >> 8);
}
@OriginalMember(owner = "client!wa", name = "d", descriptor = "(Z)B")
public final byte g1s() {
return this.data[this.offset++];
}
@OriginalMember(owner = "client!wa", name = "h", descriptor = "(I)Lclient!na;")
public final JagString gjstr2() {
@Pc(10) byte version = this.data[this.offset++];
if (version != 0) {
throw new IllegalStateException("Bad version number in gjstr2");
}
@Pc(32) int off = this.offset;
while (this.data[this.offset++] != 0) {
}
return JagString.decodeString(this.data, this.offset - off - 1, off);
@OriginalMember(owner = "client!wa", name = "k", descriptor = "(I)I")
public final int img4() {
this.offset += 4;
return ((this.data[this.offset - 2] & 0xFF) << 24) + ((this.data[this.offset - 1] & 0xFF) << 16) + ((this.data[this.offset - 4] & 0xFF) << 8) + (this.data[this.offset - 3] & 0xFF);
}
@OriginalMember(owner = "client!wa", name = "a", descriptor = "(FB)V")
@ -261,83 +297,46 @@ public class Buffer extends Node {
this.data[this.offset++] = (byte) (valueInt >> 24);
}
@OriginalMember(owner = "client!wa", name = "i", descriptor = "(B)B")
public final byte g1sneg() {
return (byte) -this.data[this.offset++];
@OriginalMember(owner = "client!wa", name = "f", descriptor = "(I)J")
public final long g8() {
@Pc(11) long low = (long) this.g4() & 0xFFFFFFFFL;
@Pc(18) long high = (long) this.g4() & 0xFFFFFFFFL;
return high + (low << 32);
}
@OriginalMember(owner = "client!wa", name = "a", descriptor = "(II[BB)V")
public final void gBytes(@OriginalArg(1) int len, @OriginalArg(2) byte[] dest) {
for (@Pc(8) int i = 0; i < len; i++) {
dest[i] = this.data[this.offset++];
// range: -16384 to 16383
@OriginalMember(owner = "client!wa", name = "p", descriptor = "(I)I")
public final int gsmart() {
@Pc(11) int value = this.data[this.offset] & 0xFF;
return value < 128 ? this.g1() - 64 : this.g2() - 0xc000;
}
@OriginalMember(owner = "client!wa", name = "f", descriptor = "(Z)I")
public final int gsmarts() {
@Pc(17) int value = this.data[this.offset] & 0xFF;
return value >= 128 ? this.g2() - 0x8000 : this.g1();
}
@OriginalMember(owner = "client!wa", name = "j", descriptor = "(B)I")
public final int gVarSmart() {
@Pc(14) int value = this.gsmarts();
@Pc(16) int value2 = 0;
while (value == 32767) {
value = this.gsmarts();
value2 += 32767;
}
return value2 + value;
}
@OriginalMember(owner = "client!wa", name = "a", descriptor = "(IB)V")
public final void p2leadd(@OriginalArg(0) int value) {
this.data[this.offset++] = (byte) (value + 128);
this.data[this.offset++] = (byte) (value >> 8);
}
@OriginalMember(owner = "client!wa", name = "i", descriptor = "(I)I")
public final int g2le() {
this.offset += 2;
return ((this.data[this.offset - 1] & 0xFF) << 8) + (this.data[this.offset - 2] & 0xFF);
}
@OriginalMember(owner = "client!wa", name = "g", descriptor = "(II)V")
public final void pSmart1or2(@OriginalArg(1) int value) {
if (value >= 0 && value < 128) {
this.p1(value);
} else if (value >= 0 && value < 0x8000) {
this.p2(value + 0x8000);
} else {
throw new IllegalArgumentException();
@OriginalMember(owner = "client!wa", name = "d", descriptor = "(B)I")
public final int gVarInt() {
@Pc(12) byte b = this.data[this.offset++];
@Pc(24) int value = 0;
while (b < 0) {
value = (b & 0x7F | value) << 7;
b = this.data[this.offset++];
}
}
@OriginalMember(owner = "client!wa", name = "b", descriptor = "(BI)V")
public final void p1len(@OriginalArg(1) int length) {
this.data[this.offset - length - 1] = (byte) length;
}
@OriginalMember(owner = "client!wa", name = "a", descriptor = "([IIII)V")
public final void decryptXtea(@OriginalArg(0) int[] key, @OriginalArg(3) int len) {
@Pc(6) int start = this.offset;
this.offset = 5;
@Pc(16) int blocks = (len - 5) / 8;
for (@Pc(18) int i = 0; i < blocks; i++) {
@Pc(23) int sum = -957401312;
@Pc(27) int v0 = this.g4();
@Pc(31) int v1 = this.g4();
@Pc(33) int rounds = 32;
while (rounds-- > 0) {
v1 -= key[sum >>> 11 & 0x3] + sum ^ v0 + (v0 >>> 5 ^ v0 << 4);
sum -= -1640531527;
v0 -= (v1 >>> 5 ^ v1 << 4) + v1 ^ key[sum & 0x3] + sum;
}
this.offset -= 8;
this.p4(v0);
this.p4(v1);
}
this.offset = start;
}
@OriginalMember(owner = "client!wa", name = "h", descriptor = "(II)V")
public final void pVarInt(@OriginalArg(1) int value) {
if ((value & 0xFFFFFF80) != 0) {
if ((-16384 & value) != 0) {
if ((value & 0xFFE00000) != 0) {
if ((value & 0xF0000000) != 0) {
this.p1(value >>> 28 | 0x80);
}
this.p1(value >>> 21 | 0x80);
}
this.p1(value >>> 14 | 0x80);
}
this.p1(value >>> 7 | 0x80);
}
this.p1(value & 0x7F);
return b | value;
}
@OriginalMember(owner = "client!wa", name = "i", descriptor = "(II)J")
@ -353,44 +352,97 @@ public class Buffer extends Node {
return value;
}
@OriginalMember(owner = "client!wa", name = "j", descriptor = "(B)I")
public final int gVarSmart() {
@Pc(14) int value = this.gSmart1or2();
@Pc(16) int value2 = 0;
while (value == 32767) {
value = this.gSmart1or2();
value2 += 32767;
@OriginalMember(owner = "client!wa", name = "a", descriptor = "(II[BB)V")
public final void gdata(@OriginalArg(1) int len, @OriginalArg(2) byte[] dest) {
for (@Pc(8) int i = 0; i < len; i++) {
dest[i] = this.data[this.offset++];
}
return value2 + value;
}
@OriginalMember(owner = "client!wa", name = "a", descriptor = "(II[BI)V")
public final void gBytesRev(@OriginalArg(1) int offset, @OriginalArg(2) byte[] dest) {
public final void igdata(@OriginalArg(1) int offset, @OriginalArg(2) byte[] dest) {
for (@Pc(12) int i = offset - 1; i >= 0; i--) {
dest[i] = this.data[this.offset++];
}
}
@OriginalMember(owner = "client!wa", name = "j", descriptor = "(II)V")
public final void p4rme(@OriginalArg(0) int value) {
this.data[this.offset++] = (byte) (value >> 8);
this.data[this.offset++] = (byte) value;
this.data[this.offset++] = (byte) (value >> 24);
this.data[this.offset++] = (byte) (value >> 16);
}
@OriginalMember(owner = "client!wa", name = "e", descriptor = "(Z)Lclient!na;")
public final JagString gjstr() {
@Pc(12) int start = this.offset;
while (this.data[this.offset++] != 0) {
}
while (this.data[this.offset++] != 0) ;
return JagString.decodeString(this.data, this.offset - start - 1, start);
}
@OriginalMember(owner = "client!wa", name = "f", descriptor = "(Z)I")
public final int gSmart1or2() {
@Pc(17) int value = this.data[this.offset] & 0xFF;
return value >= 128 ? this.g2() - 0x8000 : this.g1();
@OriginalMember(owner = "client!wa", name = "h", descriptor = "(I)Lclient!na;")
public final JagString gjstr2() {
@Pc(10) byte version = this.data[this.offset++];
if (version != 0) {
throw new IllegalStateException("Bad version number in gjstr2");
}
@Pc(32) int off = this.offset;
while (this.data[this.offset++] != 0) ;
return JagString.decodeString(this.data, this.offset - off - 1, off);
}
@OriginalMember(owner = "client!wa", name = "f", descriptor = "(B)Lclient!na;")
public final JagString fastgjstr() {
if (this.data[this.offset] == 0) {
this.offset++;
return null;
} else {
return this.gjstr();
}
}
@OriginalMember(owner = "client!si", name = "a", descriptor = "(BLclient!na;)I")
public static int gjstrlen(@OriginalArg(1) JagString str) {
return str.length() + 1;
}
// put (write) methods
@OriginalMember(owner = "client!wa", name = "a", descriptor = "(BI)V")
public final void p1(@OriginalArg(1) int value) {
this.data[this.offset++] = (byte) value;
}
@OriginalMember(owner = "client!wa", name = "m", descriptor = "(II)V")
public final void p1add(@OriginalArg(0) int value) {
this.data[this.offset++] = (byte) (value + 128);
}
@OriginalMember(owner = "client!wa", name = "d", descriptor = "(II)V")
public final void p1sub(@OriginalArg(1) int value) {
this.data[this.offset++] = (byte) (128 - value);
}
@OriginalMember(owner = "client!wa", name = "b", descriptor = "(BI)V")
public final void psize1(@OriginalArg(1) int length) {
this.data[this.offset - length - 1] = (byte) length;
}
@OriginalMember(owner = "client!wa", name = "o", descriptor = "(II)V")
public final void p2(@OriginalArg(1) int value) {
this.data[this.offset++] = (byte) (value >> 8);
this.data[this.offset++] = (byte) value;
}
@OriginalMember(owner = "client!wa", name = "l", descriptor = "(II)V")
public final void p2add(@OriginalArg(0) int value) {
this.data[this.offset++] = (byte) (value >> 8);
this.data[this.offset++] = (byte) (value + 128);
}
@OriginalMember(owner = "client!wa", name = "n", descriptor = "(II)V")
public final void ip2(@OriginalArg(1) int value) {
this.data[this.offset++] = (byte) value;
this.data[this.offset++] = (byte) (value >> 8);
}
@OriginalMember(owner = "client!wa", name = "a", descriptor = "(IB)V")
public final void ip2add(@OriginalArg(0) int value) {
this.data[this.offset++] = (byte) (value + 128);
this.data[this.offset++] = (byte) (value >> 8);
}
@OriginalMember(owner = "client!wa", name = "k", descriptor = "(II)V")
@ -400,128 +452,53 @@ public class Buffer extends Node {
this.data[this.offset++] = (byte) value;
}
@OriginalMember(owner = "client!wa", name = "k", descriptor = "(I)I")
public final int g4rme() {
this.offset += 4;
return ((this.data[this.offset - 2] & 0xFF) << 24) + ((this.data[this.offset - 1] & 0xFF) << 16) + ((this.data[this.offset - 4] & 0xFF) << 8) + (this.data[this.offset - 3] & 0xFF);
}
@OriginalMember(owner = "client!wa", name = "k", descriptor = "(B)I")
public final int g2leadd() {
this.offset += 2;
return ((this.data[this.offset - 1] & 0xFF) << 8) + (this.data[this.offset - 2] - 128 & 0xFF);
}
@OriginalMember(owner = "client!wa", name = "l", descriptor = "(I)I")
public final int g4le() {
this.offset += 4;
return ((this.data[this.offset - 1] & 0xFF) << 24) + ((this.data[this.offset - 2] & 0xFF) << 16) + ((this.data[this.offset - 3] & 0xFF) << 8) + (this.data[this.offset - 4] & 0xFF);
}
@OriginalMember(owner = "client!wa", name = "l", descriptor = "(II)V")
public final void p2add(@OriginalArg(0) int value) {
@OriginalMember(owner = "client!wa", name = "b", descriptor = "(II)V")
public final void p4(@OriginalArg(1) int value) {
this.data[this.offset++] = (byte) (value >> 24);
this.data[this.offset++] = (byte) (value >> 16);
this.data[this.offset++] = (byte) (value >> 8);
this.data[this.offset++] = (byte) (value + 128);
this.data[this.offset++] = (byte) value;
}
@OriginalMember(owner = "client!wa", name = "b", descriptor = "(IB)V")
public final void p4le2(@OriginalArg(0) int value) {
@OriginalMember(owner = "client!wa", name = "e", descriptor = "(II)V")
public final void ip4(@OriginalArg(0) int value) {
this.data[this.offset++] = (byte) value;
this.data[this.offset++] = (byte) (value >> 8);
this.data[this.offset++] = (byte) (value >> 16);
this.data[this.offset++] = (byte) (value >> 24);
}
@OriginalMember(owner = "client!wa", name = "g", descriptor = "(Z)I")
public final int g1neg() {
return -this.data[this.offset++] & 0xFF;
}
// duplicate function:
// @OriginalMember(owner = "client!wa", name = "b", descriptor = "(IB)V")
// public final void ip4(@OriginalArg(0) int value) {
// this.data[this.offset++] = (byte) value;
// this.data[this.offset++] = (byte) (value >> 8);
// this.data[this.offset++] = (byte) (value >> 16);
// this.data[this.offset++] = (byte) (value >> 24);
// }
@OriginalMember(owner = "client!wa", name = "l", descriptor = "(B)I")
public final int g2s() {
this.offset += 2;
@Pc(27) int value = ((this.data[this.offset - 2] & 0xFF) << 8) + (this.data[this.offset - 1] & 0xFF);
if (value > 32767) {
value -= 0x10000;
}
return value;
}
@OriginalMember(owner = "client!wa", name = "m", descriptor = "(I)I")
public final int g2lesadd() {
this.offset += 2;
@Pc(34) int value = ((this.data[this.offset - 1] & 0xFF) << 8) + (this.data[this.offset - 2] - 128 & 0xFF);
if (value > 32767) {
value -= 0x10000;
}
return value;
}
@OriginalMember(owner = "client!wa", name = "n", descriptor = "(I)B")
public final byte p1sub() {
return (byte) (this.data[this.offset++] - 128);
}
@OriginalMember(owner = "client!wa", name = "m", descriptor = "(II)V")
public final void p1a(@OriginalArg(0) int value) {
this.data[this.offset++] = (byte) (value + 128);
}
@OriginalMember(owner = "client!wa", name = "m", descriptor = "(B)I")
public final int g2les() {
this.offset += 2;
@Pc(38) int value = (this.data[this.offset - 2] & 0xFF) + ((this.data[this.offset - 1] & 0xFF) << 8);
if (value > 32767) {
value -= 0x10000;
}
return value;
}
@OriginalMember(owner = "client!wa", name = "c", descriptor = "(BI)I")
public final int pCrc32(@OriginalArg(1) int off) {
@Pc(16) int checksum = crc32(off, this.offset, this.data);
this.p4(checksum);
return checksum;
}
@OriginalMember(owner = "client!wa", name = "n", descriptor = "(B)I")
public final int g3() {
this.offset += 3;
return ((this.data[this.offset - 3] & 0xFF) << 16) + ((this.data[this.offset - 2] << 8 & 0xFF00) + (this.data[this.offset - 1] & 0xFF));
}
@OriginalMember(owner = "client!wa", name = "n", descriptor = "(II)V")
public final void p2le(@OriginalArg(1) int value) {
@OriginalMember(owner = "client!wa", name = "f", descriptor = "(II)V")
public final void mp4(@OriginalArg(1) int value) {
this.data[this.offset++] = (byte) (value >> 16);
this.data[this.offset++] = (byte) (value >> 24);
this.data[this.offset++] = (byte) value;
this.data[this.offset++] = (byte) (value >> 8);
}
// range: -16384 to 16383
@OriginalMember(owner = "client!wa", name = "p", descriptor = "(I)I")
public final int gSmart1or2s() {
@Pc(11) int value = this.data[this.offset] & 0xFF;
return value < 128 ? this.g1() - 64 : this.g2() - 0xc000;
@OriginalMember(owner = "client!wa", name = "j", descriptor = "(II)V")
public final void imp4(@OriginalArg(0) int value) {
this.data[this.offset++] = (byte) (value >> 8);
this.data[this.offset++] = (byte) value;
this.data[this.offset++] = (byte) (value >> 24);
this.data[this.offset++] = (byte) (value >> 16);
}
// reverse "middle-endian"
@OriginalMember(owner = "client!wa", name = "o", descriptor = "(B)I")
public final int g4me() {
this.offset += 4;
return ((this.data[this.offset - 3] & 0xFF) << 24) + ((this.data[this.offset - 4] & 0xFF) << 16) + ((this.data[this.offset - 1] & 0xFF) << 8) + (this.data[this.offset - 2] & 0xFF);
}
@OriginalMember(owner = "client!wa", name = "a", descriptor = "(Ljava/math/BigInteger;Ljava/math/BigInteger;I)V")
public final void encryptRsa(@OriginalArg(0) BigInteger exp, @OriginalArg(1) BigInteger mod) {
@Pc(2) int len = this.offset;
this.offset = 0;
@Pc(8) byte[] plaintextBytes = new byte[len];
this.gBytes(len, plaintextBytes);
@Pc(23) BigInteger plaintext = new BigInteger(plaintextBytes);
@Pc(28) BigInteger ciphertext = plaintext.modPow(exp, mod);
@Pc(38) byte[] ciphertextBytes = ciphertext.toByteArray();
this.offset = 0;
this.p1(ciphertextBytes.length);
this.pBytes(ciphertextBytes, ciphertextBytes.length);
@OriginalMember(owner = "client!wa", name = "c", descriptor = "(II)V")
public final void psize4(@OriginalArg(1) int len) {
this.data[this.offset - len - 4] = (byte) (len >> 24);
this.data[this.offset - len - 3] = (byte) (len >> 16);
this.data[this.offset - len - 2] = (byte) (len >> 8);
this.data[this.offset - len - 1] = (byte) len;
}
@OriginalMember(owner = "client!wa", name = "a", descriptor = "(IF)V")
@ -533,14 +510,68 @@ public class Buffer extends Node {
this.data[this.offset++] = (byte) floatInt;
}
@OriginalMember(owner = "client!wa", name = "p", descriptor = "(B)I")
public final int g1() {
return this.data[this.offset++] & 0xFF;
}
@OriginalMember(owner = "client!wa", name = "o", descriptor = "(II)V")
public final void p2(@OriginalArg(1) int value) {
@OriginalMember(owner = "client!wa", name = "a", descriptor = "(JI)V")
public final void p8(@OriginalArg(0) long value) {
this.data[this.offset++] = (byte) (value >> 56);
this.data[this.offset++] = (byte) (value >> 48);
this.data[this.offset++] = (byte) (value >> 40);
this.data[this.offset++] = (byte) (value >> 32);
this.data[this.offset++] = (byte) (value >> 24);
this.data[this.offset++] = (byte) (value >> 16);
this.data[this.offset++] = (byte) (value >> 8);
this.data[this.offset++] = (byte) value;
}
@OriginalMember(owner = "client!wa", name = "h", descriptor = "(II)V")
public final void pVarInt(@OriginalArg(1) int value) {
if ((value & 0xffffff80) != 0) {
if ((value & 0xffffc000) != 0) {
if ((value & 0xFFE00000) != 0) {
if ((value & 0xF0000000) != 0) {
this.p1(value >>> 28 | 0x80);
}
this.p1(value >>> 21 | 0x80);
}
this.p1(value >>> 14 | 0x80);
}
this.p1(value >>> 7 | 0x80);
}
this.p1(value & 0x7F);
}
@OriginalMember(owner = "client!wa", name = "a", descriptor = "(IIJ)V")
public final void pVarLong(@OriginalArg(1) int size, @OriginalArg(2) long value) {
@Pc(2) int bytes = size - 1;
if (bytes < 0 || bytes > 7) {
throw new IllegalArgumentException();
}
for (@Pc(27) int shift = bytes * 8; shift >= 0; shift -= 8) {
this.data[this.offset++] = (byte) (value >> shift);
}
}
@OriginalMember(owner = "client!wa", name = "a", descriptor = "(ILclient!na;)V")
public final void pjstr(@OriginalArg(1) JagString value) {
this.offset += value.encodeString(this.data, this.offset, value.length());
this.data[this.offset++] = 0;
}
@OriginalMember(owner = "client!wa", name = "a", descriptor = "([BIII)V")
public final void pdata(@OriginalArg(0) byte[] src, @OriginalArg(2) int len) {
for (@Pc(7) int i = 0; i < len; i++) {
this.data[this.offset++] = src[i];
}
}
@OriginalMember(owner = "client!wa", name = "g", descriptor = "(II)V")
public final void psmarts(@OriginalArg(1) int value) {
if (value >= 0 && value < 128) {
this.p1(value);
} else if (value >= 0 && value < 0x8000) {
this.p2(value + 0x8000);
} else {
throw new IllegalArgumentException("psmarts out of range: " + value);
}
}
}

View file

@ -104,14 +104,14 @@ public class ClientProt {
Protocol.outboundBuffer.p1isaac(77);
Protocol.outboundBuffer.p1(local13 + local13 + 3);
}
Protocol.outboundBuffer.p1a(Keyboard.pressedKeys[Keyboard.KEY_CTRL] ? 1 : 0);
Protocol.outboundBuffer.p1add(Keyboard.pressedKeys[Keyboard.KEY_CTRL] ? 1 : 0);
Protocol.outboundBuffer.p2(Camera.originX + local23);
Protocol.outboundBuffer.p2add(Camera.originZ + local27);
LoginManager.mapFlagZ = PathFinder.queueZ[0];
LoginManager.mapFlagX = PathFinder.queueX[0];
for (@Pc(126) int local126 = 1; local126 < local13; local126++) {
arg0--;
Protocol.outboundBuffer.p1a(PathFinder.queueX[arg0] - local23);
Protocol.outboundBuffer.p1add(PathFinder.queueX[arg0] - local23);
Protocol.outboundBuffer.p1sub(PathFinder.queueZ[arg0] - local27);
}
}
@ -141,19 +141,19 @@ public class ClientProt {
PathFinder.findPath(PlayerList.self.movementQueueZ[0], 0, 1, false, 0, local28.movementQueueX[0], 1, 0, 2, local28.movementQueueZ[0], PlayerList.self.movementQueueX[0]);
if (arg0 == 1) {
Protocol.outboundBuffer.p1isaac(68);
Protocol.outboundBuffer.p2leadd(PlayerList.ids[local15]);
Protocol.outboundBuffer.ip2add(PlayerList.ids[local15]);
} else if (arg0 == 4) {
Protocol.outboundBuffer.p1isaac(180);
Protocol.outboundBuffer.p2leadd(PlayerList.ids[local15]);
Protocol.outboundBuffer.ip2add(PlayerList.ids[local15]);
} else if (arg0 == 5) {
Protocol.outboundBuffer.p1isaac(4);
Protocol.outboundBuffer.p2le(PlayerList.ids[local15]);
Protocol.outboundBuffer.ip2(PlayerList.ids[local15]);
} else if (arg0 == 6) {
Protocol.outboundBuffer.p1isaac(133);
Protocol.outboundBuffer.p2le(PlayerList.ids[local15]);
Protocol.outboundBuffer.ip2(PlayerList.ids[local15]);
} else if (arg0 == 7) {
Protocol.outboundBuffer.p1isaac(114);
Protocol.outboundBuffer.p2leadd(PlayerList.ids[local15]);
Protocol.outboundBuffer.ip2add(PlayerList.ids[local15]);
}
break;
}
@ -499,10 +499,10 @@ public class ClientProt {
}
if (Static56.aClass13_12 != null && Static36.method938(Static40.aClass13_14) != null) {
Protocol.outboundBuffer.p1isaac(79);
Protocol.outboundBuffer.p4me(Static40.aClass13_14.id);
Protocol.outboundBuffer.p2le(Static56.aClass13_12.createdComponentId);
Protocol.outboundBuffer.mp4(Static40.aClass13_14.id);
Protocol.outboundBuffer.ip2(Static56.aClass13_12.createdComponentId);
Protocol.outboundBuffer.p4(Static56.aClass13_12.id);
Protocol.outboundBuffer.p2le(Static40.aClass13_14.createdComponentId);
Protocol.outboundBuffer.ip2(Static40.aClass13_14.createdComponentId);
}
} else if ((VarpDomain.anInt2952 == 1 || MiniMenu.method4640(MiniMenu.size - 1)) && MiniMenu.size > 2) {
Static226.method3901();
@ -519,7 +519,7 @@ public class ClientProt {
@OriginalMember(owner = "client!aa", name = "a", descriptor = "(IZI)V")
public static void method10(@OriginalArg(0) int arg0, @OriginalArg(2) int arg1) {
Protocol.outboundBuffer.p1isaac(132);
Protocol.outboundBuffer.p4rme(arg1);
Protocol.outboundBuffer.p2le(arg0);
Protocol.outboundBuffer.imp4(arg1);
Protocol.outboundBuffer.ip2(arg0);
}
}

View file

@ -46,7 +46,7 @@ public class ClientScriptList {
}
}
local42.offset = 0;
local12.name = local42.gjstrFast();
local12.name = local42.fastgjstr();
local12.opcodes = new int[local70];
local12.stringOperands = new JagString[local70];
local107 = 0;

View file

@ -569,8 +569,8 @@ public final class Component {
this.type = arg0.g1();
this.anInt530 = arg0.g1();
this.clientCode = arg0.g2();
this.baseX = arg0.g2s();
this.baseY = arg0.g2s();
this.baseX = arg0.g2b();
this.baseY = arg0.g2b();
this.baseWidth = arg0.g2();
this.baseHeight = arg0.g2();
this.dynamicWidthValue = 0;
@ -654,8 +654,8 @@ public final class Component {
for (local364 = 0; local364 < 20; local364++) {
@Pc(371) int local371 = arg0.g1();
if (local371 == 1) {
this.anIntArray41[local364] = arg0.g2s();
this.anIntArray47[local364] = arg0.g2s();
this.anIntArray41[local364] = arg0.g2b();
this.anIntArray47[local364] = arg0.g2b();
this.anIntArray36[local364] = arg0.g4();
} else {
this.anIntArray36[local364] = -1;
@ -734,8 +734,8 @@ public final class Component {
}
this.textAntiMacro = arg0.g1() == 1;
this.color = arg0.g4();
this.anInt512 = arg0.g2s();
this.anInt516 = arg0.g2s();
this.anInt512 = arg0.g2b();
this.anInt516 = arg0.g2b();
local175 = arg0.g1();
if (local175 == 1) {
local164 |= 0x40000000;
@ -1004,14 +1004,14 @@ public final class Component {
buffer.gjstr();
}
this.clientCode = buffer.g2();
this.baseX = buffer.g2s();
this.baseY = buffer.g2s();
this.baseX = buffer.g2b();
this.baseY = buffer.g2b();
this.baseWidth = buffer.g2();
this.baseHeight = buffer.g2();
this.dynamicWidthValue = buffer.g1s();
this.dynamicHeightValue = buffer.g1s();
this.yMode = buffer.g1s();
this.xMode = buffer.g1s();
this.dynamicWidthValue = buffer.g1b();
this.dynamicHeightValue = buffer.g1b();
this.yMode = buffer.g1b();
this.xMode = buffer.g1b();
this.layer = buffer.g2();
if (this.layer == 65535) {
this.layer = -1;
@ -1043,8 +1043,8 @@ public final class Component {
if (this.modelId == 65535) {
this.modelId = -1;
}
this.anInt495 = buffer.g2s();
this.anInt481 = buffer.g2s();
this.anInt495 = buffer.g2b();
this.anInt481 = buffer.g2b();
this.modelXAngle = buffer.g2();
this.modelYAngle = buffer.g2();
this.modelYOffset = buffer.g2();
@ -1102,8 +1102,8 @@ public final class Component {
} else {
this.anIntArray46[local497] = local471;
}
this.aByteArray8[local497] = buffer.g1s();
this.aByteArray7[local497] = buffer.g1s();
this.aByteArray8[local497] = buffer.g1b();
this.aByteArray7[local497] = buffer.g1b();
local471 = buffer.g1();
}
}

View file

@ -174,11 +174,11 @@ public class CreateManager {
local8.p2(arg5);
local8.p2(arg1);
local8.p4((int) (Math.random() * 9.9999999E7D));
local8.encryptRsa(GlobalConfig.RSA_EXPONENT, GlobalConfig.RSA_MODULUS);
local8.rsaenc(GlobalConfig.RSA_EXPONENT, GlobalConfig.RSA_MODULUS);
Protocol.outboundBuffer.offset = 0;
Protocol.outboundBuffer.p1(36);
Protocol.outboundBuffer.p1(local8.offset);
Protocol.outboundBuffer.pBytes(local8.data, local8.offset);
Protocol.outboundBuffer.pdata(local8.data, local8.offset);
reply = -3;
step = 1;
loops = 0;

View file

@ -76,9 +76,9 @@ public final class Environment {
this.anInt3530 = -50;
this.anInt3528 = -60;
} else {
this.anInt3530 = arg0.g2s();
this.anInt3528 = arg0.g2s();
this.anInt3527 = arg0.g2s();
this.anInt3530 = arg0.g2b();
this.anInt3528 = arg0.g2b();
this.anInt3527 = arg0.g2b();
}
if ((local7 & 0x20) == 0) {
this.anInt3525 = FogManager.anInt3922;

View file

@ -107,7 +107,7 @@ public class FriendsList {
@OriginalMember(owner = "client!ni", name = "a", descriptor = "(ILclient!na;I)V")
public static void setRank(@OriginalArg(1) JagString arg0, @OriginalArg(2) int arg1) {
Protocol.outboundBuffer.p1isaac(188);
Protocol.outboundBuffer.p1a(arg1);
Protocol.outboundBuffer.p1add(arg1);
Protocol.outboundBuffer.p8(arg0.encode37());
}

View file

@ -1980,9 +1980,9 @@ public final class GlModel extends Model {
}
} else {
for (local25 = 0; local25 < this.anInt5297; local25++) {
aClass3_Sub15_8.p4le(this.aShortArray77[local25]);
aClass3_Sub15_8.p4le(this.aShortArray82[local25]);
aClass3_Sub15_8.p4le(this.aShortArray83[local25]);
aClass3_Sub15_8.ip4(this.aShortArray77[local25]);
aClass3_Sub15_8.ip4(this.aShortArray82[local25]);
aClass3_Sub15_8.ip4(this.aShortArray83[local25]);
}
}
if (!GlRenderer.arbVboSupported) {
@ -2360,9 +2360,9 @@ public final class GlModel extends Model {
break;
}
aClass3_Sub15_8.offset = local109 * local1;
aClass3_Sub15_8.p4le(local71);
aClass3_Sub15_8.p4le(local78);
aClass3_Sub15_8.p4le(local85);
aClass3_Sub15_8.ip4(local71);
aClass3_Sub15_8.ip4(local78);
aClass3_Sub15_8.ip4(local85);
}
}
}

View file

@ -63,8 +63,8 @@ public final class GlTexture extends SecondaryNode {
this.aBoolean285 = arg0.g1() == 1;
this.aBoolean284 = arg0.g1() == 1;
@Pc(68) int local68 = arg0.g1() & 0x3;
this.anInt5485 = arg0.g1s();
this.anInt5497 = arg0.g1s();
this.anInt5485 = arg0.g1b();
this.anInt5497 = arg0.g1b();
@Pc(82) int local82 = arg0.g1();
arg0.g1();
if (local68 == 1) {

View file

@ -275,7 +275,7 @@ public final class GlTile extends Node {
local86 = this.anIntArrayArray18[local47];
if (local86 != null) {
for (local90 = 0; local90 < local86.length; local90++) {
aClass3_Sub15_2.p4le(local86[local90]);
aClass3_Sub15_2.ip4(local86[local90]);
}
}
local111 = this.aBooleanArray54[local47] ? aClass3_Sub15_2 : aClass3_Sub15_3;
@ -283,9 +283,9 @@ public final class GlTile extends Node {
local111 = aClass3_Sub15_3;
}
for (local116 = 1; local116 < local78.length - 1; local116++) {
local111.p4le(local78[0]);
local111.p4le(local78[local116]);
local111.p4le(local78[local116 + 1]);
local111.ip4(local78[0]);
local111.ip4(local78[local116]);
local111.ip4(local78[local116 + 1]);
}
}
}

View file

@ -9,7 +9,7 @@ import org.openrs2.deob.annotation.Pc;
public final class HuffmanCodec {
@OriginalMember(owner = "client!fi", name = "c", descriptor = "[I")
public static final int[] anIntArray175 = new int[256];
public static final int[] crctable = new int[256];
@OriginalMember(owner = "client!fi", name = "b", descriptor = "[I")
private int[] anIntArray174;
@ -21,16 +21,16 @@ public final class HuffmanCodec {
private final byte[] aByteArray22;
static {
for (@Pc(4) int local4 = 0; local4 < 256; local4++) {
@Pc(9) int local9 = local4;
for (@Pc(11) int local11 = 0; local11 < 8; local11++) {
if ((local9 & 0x1) == 1) {
local9 = local9 >>> 1 ^ 0xEDB88320;
for (@Pc(4) int i = 0; i < 256; i++) {
@Pc(9) int temp = i;
for (@Pc(11) int j = 0; j < 8; j++) {
if ((temp & 0x1) == 1) {
temp = temp >>> 1 ^ 0xEDB88320;
} else {
local9 >>>= 0x1;
temp >>>= 0x1;
}
}
anIntArray175[local4] = local9;
crctable[i] = temp;
}
}

View file

@ -316,7 +316,7 @@ public final class Js5 {
} else {
local114 = method2696(this.anObjectArray32[arg0], true);
@Pc(128) Buffer local128 = new Buffer(local114);
local128.decryptXtea(arg1, local128.data.length);
local128.tinydec(arg1, local128.data.length);
}
@Pc(140) byte[] local140;
try {

View file

@ -21,7 +21,7 @@ public final class Js5Compression {
throw new RuntimeException();
} else if (type == 0) {
@Pc(53) byte[] bytes = new byte[len];
buffer.gBytes(len, bytes);
buffer.gdata(len, bytes);
return bytes;
} else {
@Pc(65) int uncompressedLen = buffer.g4();

View file

@ -106,22 +106,22 @@ public final class Js5GlTextureProvider implements TextureProvider {
}
for (local97 = 0; local97 < local55; local97++) {
if (this.aBooleanArray92[local97]) {
this.aByteArray59[local97] = local51.g1s();
this.aByteArray59[local97] = local51.g1b();
}
}
for (local97 = 0; local97 < local55; local97++) {
if (this.aBooleanArray92[local97]) {
this.aByteArray60[local97] = local51.g1s();
this.aByteArray60[local97] = local51.g1b();
}
}
for (local97 = 0; local97 < local55; local97++) {
if (this.aBooleanArray92[local97]) {
this.aByteArray62[local97] = local51.g1s();
this.aByteArray62[local97] = local51.g1b();
}
}
for (local97 = 0; local97 < local55; local97++) {
if (this.aBooleanArray92[local97]) {
this.aByteArray61[local97] = local51.g1s();
this.aByteArray61[local97] = local51.g1b();
}
}
for (local97 = 0; local97 < local55; local97++) {

View file

@ -40,7 +40,7 @@ public final class LightType {
} else if (arg0 == 3) {
this.anInt2867 = arg1.g2();
} else if (arg0 == 4) {
this.anInt2872 = arg1.g2s();
this.anInt2872 = arg1.g2b();
}
}
}

View file

@ -141,7 +141,7 @@ public final class Light_Class45 {
local15.gFloat((float) this.anIntArray179[local19]);
}
for (local19 = 0; local19 < this.anInt2018; local19++) {
local7.p4le(this.anIntArray177[local19]);
local7.ip4(this.anIntArray177[local19]);
}
}
if (GlRenderer.arbVboSupported) {

View file

@ -461,9 +461,9 @@ public final class LocType {
} else if (arg1 == 28) {
this.wallDecorOffsetScale = arg0.g1();
} else if (arg1 == 29) {
this.anInt4407 = arg0.g1s();
this.anInt4407 = arg0.g1b();
} else if (arg1 == 39) {
this.anInt4405 = arg0.g1s() * 5;
this.anInt4405 = arg0.g1b() * 5;
} else if (arg1 >= 30 && arg1 < 35) {
this.ops[arg1 - 30] = arg0.gjstr();
if (this.ops[arg1 - 30].equalsIgnoreCase(LocalizedText.HIDDEN)) {
@ -489,7 +489,7 @@ public final class LocType {
defaultMultiLoc = arg0.g1();
this.aByteArray63 = new byte[defaultMultiLoc];
for (len = 0; len < defaultMultiLoc; len++) {
this.aByteArray63[len] = arg0.g1s();
this.aByteArray63[len] = arg0.g1b();
}
} else if (arg1 == 60) {
this.mapElement = arg0.g2();
@ -506,11 +506,11 @@ public final class LocType {
} else if (arg1 == 69) {
this.blockedSides = arg0.g1();
} else if (arg1 == 70) {
this.translateX = arg0.g2s();
this.translateX = arg0.g2b();
} else if (arg1 == 71) {
this.translateY = arg0.g2s();
this.translateY = arg0.g2b();
} else if (arg1 == 72) {
this.translateZ = arg0.g2s();
this.translateZ = arg0.g2b();
} else if (arg1 == 73) {
this.aBoolean206 = true;
} else if (arg1 == 74) {

View file

@ -312,7 +312,7 @@ public class LoginManager {
Protocol.outboundBuffer.pjstr(JagString.parse(""));
Protocol.outboundBuffer.pjstr(JagString.parse(""));
}
Protocol.outboundBuffer.encryptRsa(GlobalConfig.RSA_EXPONENT, GlobalConfig.RSA_MODULUS);
Protocol.outboundBuffer.rsaenc(GlobalConfig.RSA_EXPONENT, GlobalConfig.RSA_MODULUS);
buffer.offset = 0;
if (client.gameState == 40) {
buffer.p1(18);
@ -324,7 +324,7 @@ public class LoginManager {
// pretend that we're loading the archive so we don't throw the packet size off
offset = 4;
}
buffer.p2(Protocol.outboundBuffer.offset + Buffer.getStringLength(client.settings) + (159 + offset));
buffer.p2(Protocol.outboundBuffer.offset + Buffer.gjstrlen(client.settings) + (159 + offset));
buffer.p4(530);
buffer.p1(anInt39);
buffer.p1(client.advertSuppressed ? 1 : 0);
@ -370,7 +370,7 @@ public class LoginManager {
if (GlobalConfig.LOGIN_FAKE_IDX28) {
buffer.p4(0);
}
buffer.pBytes(Protocol.outboundBuffer.data, Protocol.outboundBuffer.offset);
buffer.pdata(Protocol.outboundBuffer.data, Protocol.outboundBuffer.offset);
Protocol.socket.write(buffer.data, buffer.offset);
Protocol.outboundBuffer.setKey(key);
for (@Pc(583) int local583 = 0; local583 < 4; local583++) {
@ -539,11 +539,11 @@ public class LoginManager {
local43.p4((int) (Math.random() * 9.9999999E7D));
local43.pjstr(Player.password);
local43.p4((int) (Math.random() * 9.9999999E7D));
local43.encryptRsa(GlobalConfig.RSA_EXPONENT, GlobalConfig.RSA_MODULUS);
local43.rsaenc(GlobalConfig.RSA_EXPONENT, GlobalConfig.RSA_MODULUS);
Protocol.outboundBuffer.offset = 0;
Protocol.outboundBuffer.p1(210);
Protocol.outboundBuffer.p1(local43.offset);
Protocol.outboundBuffer.pBytes(local43.data, local43.offset);
Protocol.outboundBuffer.pdata(local43.data, local43.offset);
} else {
clear();
}

View file

@ -47,7 +47,7 @@ public final class MapElementList {
for (@Pc(37) int local37 = 0; local37 < local35.anInt5074; local37++) {
@Pc(56) Buffer local56 = new Buffer(arg1.getFile(local10, local29[local37]));
local35.aClass100Array153[local37] = local56.gjstr();
local35.aByteArray69[local37] = local56.g1s();
local35.aByteArray69[local37] = local56.g1b();
local35.aShortArray73[local37] = (short) local56.g2();
local35.aShortArray72[local37] = (short) local56.g2();
local35.anIntArray444[local37] = local56.g4();

View file

@ -43,7 +43,7 @@ public final class MidiInstrument extends Node {
@Pc(55) byte[] local55 = new byte[local29];
@Pc(57) int local57;
for (local57 = 0; local57 < local29; local57++) {
local55[local57] = local38.g1s();
local55[local57] = local38.g1b();
}
local38.offset++;
local29++;
@ -55,7 +55,7 @@ public final class MidiInstrument extends Node {
@Pc(106) byte[] local106 = new byte[local91];
@Pc(108) int local108;
for (local108 = 0; local108 < local91; local108++) {
local106[local108] = local38.g1s();
local106[local108] = local38.g1b();
}
local38.offset++;
local91++;
@ -67,7 +67,7 @@ public final class MidiInstrument extends Node {
}
@Pc(159) byte[] local159 = new byte[local133];
for (@Pc(161) int local161 = 0; local161 < local133; local161++) {
local159[local161] = local38.g1s();
local159[local161] = local38.g1b();
}
local38.offset++;
local133++;
@ -116,7 +116,7 @@ public final class MidiInstrument extends Node {
@Pc(346) byte[] local346 = new byte[local329];
@Pc(348) int local348;
for (local348 = 0; local348 < local329; local348++) {
local346[local348] = local38.g1s();
local346[local348] = local38.g1b();
}
local38.offset++;
local329++;
@ -226,23 +226,23 @@ public final class MidiInstrument extends Node {
local729 = local242[local664];
if (local729.aByteArray80 != null) {
for (local734 = 1; local734 < local729.aByteArray80.length; local734 += 2) {
local729.aByteArray80[local734] = local38.g1s();
local729.aByteArray80[local734] = local38.g1b();
}
}
if (local729.aByteArray81 != null) {
for (local734 = 3; local734 < local729.aByteArray81.length - 2; local734 += 2) {
local729.aByteArray81[local734] = local38.g1s();
local729.aByteArray81[local734] = local38.g1b();
}
}
}
if (local311 != null) {
for (local664 = 1; local664 < local311.length; local664 += 2) {
local311[local664] = local38.g1s();
local311[local664] = local38.g1b();
}
}
if (local327 != null) {
for (local664 = 1; local664 < local327.length; local664 += 2) {
local327[local664] = local38.g1s();
local327[local664] = local38.g1b();
}
}
for (local664 = 0; local664 < local194; local664++) {

View file

@ -359,24 +359,24 @@ public class MiniMenu {
Cross.x = Mouse.clickX;
Cross.y = Mouse.clickY;
Protocol.outboundBuffer.p1isaac(71);
Protocol.outboundBuffer.p2leadd(local36);
Protocol.outboundBuffer.ip2add(local36);
}
}
if (local23 == 46) {
PathFinder.findPathToLoc(local31, local19, local15);
Protocol.outboundBuffer.p1isaac(247);
Protocol.outboundBuffer.p2le(Camera.originZ + local19);
Protocol.outboundBuffer.p2leadd(local15 + Camera.originX);
Protocol.outboundBuffer.ip2(Camera.originZ + local19);
Protocol.outboundBuffer.ip2add(local15 + Camera.originX);
Protocol.outboundBuffer.p2(Integer.MAX_VALUE & (int) (local31 >>> 32));
}
if (local23 == 40) {
Protocol.outboundBuffer.p1isaac(27);
Protocol.outboundBuffer.p2(Static185.anInt4370);
Protocol.outboundBuffer.p4le2(local19);
Protocol.outboundBuffer.p2le(local15);
Protocol.outboundBuffer.p4le2(Static224.anInt5062);
Protocol.outboundBuffer.p2leadd(anInt4997);
Protocol.outboundBuffer.p2leadd(local36);
Protocol.outboundBuffer.ip4(local19);
Protocol.outboundBuffer.ip2(local15);
Protocol.outboundBuffer.ip4(Static224.anInt5062);
Protocol.outboundBuffer.ip2add(anInt4997);
Protocol.outboundBuffer.ip2add(local36);
anInt2043 = 0;
pressedInventoryComponent = InterfaceList.getComponent(local19);
anInt5444 = local15;
@ -403,7 +403,7 @@ public class MiniMenu {
Cross.type = 2;
Cross.y = Mouse.clickY;
Protocol.outboundBuffer.p1isaac(78);
Protocol.outboundBuffer.p2le(local36);
Protocol.outboundBuffer.ip2(local36);
}
}
if (local23 == 44) {
@ -415,14 +415,14 @@ public class MiniMenu {
Cross.y = Mouse.clickY;
Cross.milliseconds = 0;
Protocol.outboundBuffer.p1isaac(133);
Protocol.outboundBuffer.p2le(local36);
Protocol.outboundBuffer.ip2(local36);
}
}
if (local23 == 58) {
Protocol.outboundBuffer.p1isaac(135);
Protocol.outboundBuffer.p2add(local36);
Protocol.outboundBuffer.p2add(local15);
Protocol.outboundBuffer.p4me(local19);
Protocol.outboundBuffer.mp4(local19);
anInt2043 = 0;
pressedInventoryComponent = InterfaceList.getComponent(local19);
anInt5444 = local15;
@ -430,7 +430,7 @@ public class MiniMenu {
if (local23 == 42) {
PathFinder.findPathToLoc(local31, local19, local15);
Protocol.outboundBuffer.p1isaac(254);
Protocol.outboundBuffer.p2le(local15 + Camera.originX);
Protocol.outboundBuffer.ip2(local15 + Camera.originX);
Protocol.outboundBuffer.p2add((int) (local31 >>> 32) & Integer.MAX_VALUE);
Protocol.outboundBuffer.p2(local19 + Camera.originZ);
}
@ -446,9 +446,9 @@ public class MiniMenu {
Cross.milliseconds = 0;
Cross.y = Mouse.clickY;
Protocol.outboundBuffer.p1isaac(239);
Protocol.outboundBuffer.p4le2(anInt2512);
Protocol.outboundBuffer.ip4(anInt2512);
Protocol.outboundBuffer.p2add(anInt506);
Protocol.outboundBuffer.p2leadd(local36);
Protocol.outboundBuffer.ip2add(local36);
}
}
@Pc(560) boolean local560;
@ -466,16 +466,16 @@ public class MiniMenu {
Cross.type = 2;
Cross.y = Mouse.clickY;
Protocol.outboundBuffer.p1isaac(66);
Protocol.outboundBuffer.p2le(Camera.originX + local15);
Protocol.outboundBuffer.ip2(Camera.originX + local15);
Protocol.outboundBuffer.p2(local36);
Protocol.outboundBuffer.p2leadd(local19 + Camera.originZ);
Protocol.outboundBuffer.ip2add(local19 + Camera.originZ);
}
if (local23 == 1001) {
PathFinder.findPathToLoc(local31, local19, local15);
Protocol.outboundBuffer.p1isaac(170);
Protocol.outboundBuffer.p2leadd(Integer.MAX_VALUE & (int) (local31 >>> 32));
Protocol.outboundBuffer.p2leadd(local15 + Camera.originX);
Protocol.outboundBuffer.p2leadd(local19 + Camera.originZ);
Protocol.outboundBuffer.ip2add(Integer.MAX_VALUE & (int) (local31 >>> 32));
Protocol.outboundBuffer.ip2add(local15 + Camera.originX);
Protocol.outboundBuffer.ip2add(local19 + Camera.originZ);
}
if (local23 == 1002) {
Cross.type = 2;
@ -483,14 +483,14 @@ public class MiniMenu {
Cross.y = Mouse.clickY;
Cross.milliseconds = 0;
Protocol.outboundBuffer.p1isaac(92);
Protocol.outboundBuffer.p2leadd(local36);
Protocol.outboundBuffer.ip2add(local36);
}
@Pc(693) Component local693;
if (local23 == 1006) {
local693 = InterfaceList.getComponent(local19);
if (local693 == null || local693.objCounts[local15] < 100000) {
Protocol.outboundBuffer.p1isaac(92);
Protocol.outboundBuffer.p2leadd(local36);
Protocol.outboundBuffer.ip2add(local36);
} else {
Chat.add(JagString.EMPTY, 0, JagString.concatenate(new JagString[] { JagString.parseInt(local693.objCounts[local15]), aClass100_1039, ObjTypeList.get(local36).name}));
}
@ -538,20 +538,20 @@ public class MiniMenu {
}
if (local23 == 47) {
Protocol.outboundBuffer.p1isaac(156);
Protocol.outboundBuffer.p2leadd(local15);
Protocol.outboundBuffer.ip2add(local15);
Protocol.outboundBuffer.p2add(local36);
Protocol.outboundBuffer.p4le2(local19);
Protocol.outboundBuffer.ip4(local19);
anInt2043 = 0;
pressedInventoryComponent = InterfaceList.getComponent(local19);
anInt5444 = local15;
}
if (local23 == 3) {
Protocol.outboundBuffer.p1isaac(253);
Protocol.outboundBuffer.p4le2(anInt2512);
Protocol.outboundBuffer.p2leadd(local15);
Protocol.outboundBuffer.p4le2(local19);
Protocol.outboundBuffer.ip4(anInt2512);
Protocol.outboundBuffer.ip2add(local15);
Protocol.outboundBuffer.ip4(local19);
Protocol.outboundBuffer.p2add(local36);
Protocol.outboundBuffer.p2le(anInt506);
Protocol.outboundBuffer.ip2(anInt506);
anInt2043 = 0;
pressedInventoryComponent = InterfaceList.getComponent(local19);
anInt5444 = local15;
@ -565,7 +565,7 @@ public class MiniMenu {
Cross.x = Mouse.clickX;
Cross.milliseconds = 0;
Protocol.outboundBuffer.p1isaac(4);
Protocol.outboundBuffer.p2le(local36);
Protocol.outboundBuffer.ip2(local36);
}
}
if (local23 == 41 && Static39.aClass13_10 == null) {
@ -576,15 +576,15 @@ public class MiniMenu {
if (local23 == 49) {
PathFinder.findPathToLoc(local31, local19, local15);
Protocol.outboundBuffer.p1isaac(84);
Protocol.outboundBuffer.p2leadd(Integer.MAX_VALUE & (int) (local31 >>> 32));
Protocol.outboundBuffer.p2leadd(Camera.originZ + local19);
Protocol.outboundBuffer.p2le(local15 + Camera.originX);
Protocol.outboundBuffer.ip2add(Integer.MAX_VALUE & (int) (local31 >>> 32));
Protocol.outboundBuffer.ip2add(Camera.originZ + local19);
Protocol.outboundBuffer.ip2(local15 + Camera.originX);
}
if (local23 == 23) {
Protocol.outboundBuffer.p1isaac(206);
Protocol.outboundBuffer.p2add(local36);
Protocol.outboundBuffer.p2le(local15);
Protocol.outboundBuffer.p4le2(local19);
Protocol.outboundBuffer.ip2(local15);
Protocol.outboundBuffer.ip4(local19);
anInt2043 = 0;
pressedInventoryComponent = InterfaceList.getComponent(local19);
anInt5444 = local15;
@ -593,9 +593,9 @@ public class MiniMenu {
Protocol.outboundBuffer.p1isaac(134);
Protocol.outboundBuffer.p2add(Camera.originX + local15);
Protocol.outboundBuffer.p2(anInt4997);
Protocol.outboundBuffer.p2le(local19 + Camera.originZ);
Protocol.outboundBuffer.ip2(local19 + Camera.originZ);
Protocol.outboundBuffer.p2(Static185.anInt4370);
Protocol.outboundBuffer.p4me(Static224.anInt5062);
Protocol.outboundBuffer.mp4(Static224.anInt5062);
Protocol.outboundBuffer.p2add((int) (local31 >>> 32) & Integer.MAX_VALUE);
}
if (local23 == 37) {
@ -607,7 +607,7 @@ public class MiniMenu {
Cross.y = Mouse.clickY;
Cross.x = Mouse.clickX;
Protocol.outboundBuffer.p1isaac(114);
Protocol.outboundBuffer.p2leadd(local36);
Protocol.outboundBuffer.ip2add(local36);
}
}
if (local23 == 9 || local23 == 1003) {
@ -615,9 +615,9 @@ public class MiniMenu {
}
if (local23 == 5) {
Protocol.outboundBuffer.p1isaac(55);
Protocol.outboundBuffer.p2le(local36);
Protocol.outboundBuffer.ip2(local36);
Protocol.outboundBuffer.p2add(local15);
Protocol.outboundBuffer.p4rme(local19);
Protocol.outboundBuffer.imp4(local19);
anInt2043 = 0;
pressedInventoryComponent = InterfaceList.getComponent(local19);
anInt5444 = local15;
@ -637,8 +637,8 @@ public class MiniMenu {
Cross.y = Mouse.clickY;
Protocol.outboundBuffer.p1isaac(228);
Protocol.outboundBuffer.p2(local36);
Protocol.outboundBuffer.p2le(Camera.originX + local15);
Protocol.outboundBuffer.p2leadd(Camera.originZ + local19);
Protocol.outboundBuffer.ip2(Camera.originX + local15);
Protocol.outboundBuffer.ip2add(Camera.originZ + local19);
}
if (local23 == 4) {
local192 = NpcList.npcs[local36];
@ -680,14 +680,14 @@ public class MiniMenu {
Cross.type = 2;
Cross.x = Mouse.clickX;
Protocol.outboundBuffer.p1isaac(180);
Protocol.outboundBuffer.p2leadd(local36);
Protocol.outboundBuffer.ip2add(local36);
}
}
if (local23 == 35) {
Protocol.outboundBuffer.p1isaac(161);
Protocol.outboundBuffer.p4le2(local19);
Protocol.outboundBuffer.p2leadd(local36);
Protocol.outboundBuffer.p2leadd(local15);
Protocol.outboundBuffer.ip4(local19);
Protocol.outboundBuffer.ip2add(local36);
Protocol.outboundBuffer.ip2add(local15);
anInt2043 = 0;
pressedInventoryComponent = InterfaceList.getComponent(local19);
anInt5444 = local15;
@ -702,8 +702,8 @@ public class MiniMenu {
Cross.y = Mouse.clickY;
Protocol.outboundBuffer.p1isaac(195);
Protocol.outboundBuffer.p2add(anInt506);
Protocol.outboundBuffer.p4le2(anInt2512);
Protocol.outboundBuffer.p2leadd(local36);
Protocol.outboundBuffer.ip4(anInt2512);
Protocol.outboundBuffer.ip2add(local36);
}
}
if (local23 == 34) {
@ -720,15 +720,15 @@ public class MiniMenu {
Cross.y = Mouse.clickY;
Cross.milliseconds = 0;
Protocol.outboundBuffer.p1isaac(109);
Protocol.outboundBuffer.p2le(local19 + Camera.originZ);
Protocol.outboundBuffer.ip2(local19 + Camera.originZ);
Protocol.outboundBuffer.p2(local15 + Camera.originX);
Protocol.outboundBuffer.p2leadd(local36);
Protocol.outboundBuffer.ip2add(local36);
}
if (local23 == 25) {
Protocol.outboundBuffer.p1isaac(81);
Protocol.outboundBuffer.p2add(local15);
Protocol.outboundBuffer.p2(local36);
Protocol.outboundBuffer.p4rme(local19);
Protocol.outboundBuffer.imp4(local19);
anInt2043 = 0;
pressedInventoryComponent = InterfaceList.getComponent(local19);
anInt5444 = local15;
@ -742,7 +742,7 @@ public class MiniMenu {
Cross.x = Mouse.clickX;
Cross.milliseconds = 0;
Protocol.outboundBuffer.p1isaac(218);
Protocol.outboundBuffer.p2le(local36);
Protocol.outboundBuffer.ip2(local36);
}
}
@Pc(1955) int local1955;
@ -767,10 +767,10 @@ public class MiniMenu {
Cross.y = Mouse.clickY;
Cross.x = Mouse.clickX;
Protocol.outboundBuffer.p1isaac(115);
Protocol.outboundBuffer.p4me(Static224.anInt5062);
Protocol.outboundBuffer.p2le(Static185.anInt4370);
Protocol.outboundBuffer.p2le(local36);
Protocol.outboundBuffer.p2leadd(anInt4997);
Protocol.outboundBuffer.mp4(Static224.anInt5062);
Protocol.outboundBuffer.ip2(Static185.anInt4370);
Protocol.outboundBuffer.ip2(local36);
Protocol.outboundBuffer.ip2add(anInt4997);
}
}
if (local23 == 59) {
@ -793,12 +793,12 @@ public class MiniMenu {
Cross.y = Mouse.clickY;
Cross.type = 2;
Protocol.outboundBuffer.p1isaac(101);
Protocol.outboundBuffer.p2leadd(local15 + Camera.originX);
Protocol.outboundBuffer.p2le(Static185.anInt4370);
Protocol.outboundBuffer.p2le(anInt4997);
Protocol.outboundBuffer.p2le(local36);
Protocol.outboundBuffer.p2leadd(Camera.originZ + local19);
Protocol.outboundBuffer.p4me(Static224.anInt5062);
Protocol.outboundBuffer.ip2add(local15 + Camera.originX);
Protocol.outboundBuffer.ip2(Static185.anInt4370);
Protocol.outboundBuffer.ip2(anInt4997);
Protocol.outboundBuffer.ip2(local36);
Protocol.outboundBuffer.ip2add(Camera.originZ + local19);
Protocol.outboundBuffer.mp4(Static224.anInt5062);
}
if (local23 == 1004) {
Cross.milliseconds = 0;
@ -806,7 +806,7 @@ public class MiniMenu {
Cross.type = 2;
Cross.y = Mouse.clickY;
Protocol.outboundBuffer.p1isaac(94);
Protocol.outboundBuffer.p2leadd(local36);
Protocol.outboundBuffer.ip2add(local36);
}
if (local23 == 11) {
if (local36 == 0) {
@ -814,9 +814,9 @@ public class MiniMenu {
method3556(Player.level, local15, local19);
} else if (local36 == 1) {
Protocol.outboundBuffer.p1isaac(131);
Protocol.outboundBuffer.p4me(anInt2512);
Protocol.outboundBuffer.mp4(anInt2512);
Protocol.outboundBuffer.p2add(Camera.originX + local15);
Protocol.outboundBuffer.p2leadd(anInt506);
Protocol.outboundBuffer.ip2add(anInt506);
Protocol.outboundBuffer.p2add(local19 + Camera.originZ);
}
}
@ -840,15 +840,15 @@ public class MiniMenu {
Cross.type = 2;
Cross.x = Mouse.clickX;
Protocol.outboundBuffer.p1isaac(248);
Protocol.outboundBuffer.p2leadd(local36);
Protocol.outboundBuffer.ip2add(local36);
Protocol.outboundBuffer.p2(anInt4997);
Protocol.outboundBuffer.p2(Static185.anInt4370);
Protocol.outboundBuffer.p4me(Static224.anInt5062);
Protocol.outboundBuffer.mp4(Static224.anInt5062);
}
}
if (local23 == 7) {
Protocol.outboundBuffer.p1isaac(85);
Protocol.outboundBuffer.p4rme(local19);
Protocol.outboundBuffer.imp4(local19);
Protocol.outboundBuffer.p2(local15);
Protocol.outboundBuffer.p2add(local36);
anInt2043 = 0;
@ -870,22 +870,22 @@ public class MiniMenu {
Cross.milliseconds = 0;
Protocol.outboundBuffer.p1isaac(48);
Protocol.outboundBuffer.p2add(local15 + Camera.originX);
Protocol.outboundBuffer.p2leadd(local36);
Protocol.outboundBuffer.p2le(Camera.originZ + local19);
Protocol.outboundBuffer.ip2add(local36);
Protocol.outboundBuffer.ip2(Camera.originZ + local19);
}
if (local23 == 38 && PathFinder.findPathToLoc(local31, local19, local15)) {
Protocol.outboundBuffer.p1isaac(233);
Protocol.outboundBuffer.p2leadd(local19 + Camera.originZ);
Protocol.outboundBuffer.ip2add(local19 + Camera.originZ);
Protocol.outboundBuffer.p2add(Camera.originX + local15);
Protocol.outboundBuffer.p2leadd(anInt506);
Protocol.outboundBuffer.p4rme(anInt2512);
Protocol.outboundBuffer.ip2add(anInt506);
Protocol.outboundBuffer.imp4(anInt2512);
Protocol.outboundBuffer.p2add((int) (local31 >>> 32) & Integer.MAX_VALUE);
}
if (local23 == 13) {
Protocol.outboundBuffer.p1isaac(6);
Protocol.outboundBuffer.p4(local19);
Protocol.outboundBuffer.p2add(local15);
Protocol.outboundBuffer.p2le(local36);
Protocol.outboundBuffer.ip2(local36);
anInt2043 = 0;
pressedInventoryComponent = InterfaceList.getComponent(local19);
anInt5444 = local15;
@ -919,15 +919,15 @@ public class MiniMenu {
if (local23 == 50) {
PathFinder.findPathToLoc(local31, local19, local15);
Protocol.outboundBuffer.p1isaac(194);
Protocol.outboundBuffer.p2leadd(local19 + Camera.originZ);
Protocol.outboundBuffer.p2le(Camera.originX + local15);
Protocol.outboundBuffer.ip2add(local19 + Camera.originZ);
Protocol.outboundBuffer.ip2(Camera.originX + local15);
Protocol.outboundBuffer.p2((int) (local31 >>> 32) & Integer.MAX_VALUE);
}
if (local23 == 48) {
Protocol.outboundBuffer.p1isaac(154);
Protocol.outboundBuffer.p2le(local15);
Protocol.outboundBuffer.p4rme(local19);
Protocol.outboundBuffer.p2leadd(local36);
Protocol.outboundBuffer.ip2(local15);
Protocol.outboundBuffer.imp4(local19);
Protocol.outboundBuffer.ip2add(local36);
anInt2043 = 0;
pressedInventoryComponent = InterfaceList.getComponent(local19);
anInt5444 = local15;
@ -941,14 +941,14 @@ public class MiniMenu {
Cross.y = Mouse.clickY;
Cross.type = 2;
Protocol.outboundBuffer.p1isaac(68);
Protocol.outboundBuffer.p2leadd(local36);
Protocol.outboundBuffer.ip2add(local36);
}
}
if (local23 == 43) {
Protocol.outboundBuffer.p1isaac(153);
Protocol.outboundBuffer.p4le2(local19);
Protocol.outboundBuffer.p2le(local15);
Protocol.outboundBuffer.p2le(local36);
Protocol.outboundBuffer.ip4(local19);
Protocol.outboundBuffer.ip2(local15);
Protocol.outboundBuffer.ip2(local36);
anInt2043 = 0;
pressedInventoryComponent = InterfaceList.getComponent(local19);
anInt5444 = local15;
@ -963,18 +963,18 @@ public class MiniMenu {
Cross.type = 2;
Cross.milliseconds = 0;
Protocol.outboundBuffer.p1isaac(73);
Protocol.outboundBuffer.p4rme(anInt2512);
Protocol.outboundBuffer.imp4(anInt2512);
Protocol.outboundBuffer.p2(Camera.originZ + local19);
Protocol.outboundBuffer.p2leadd(local36);
Protocol.outboundBuffer.p2leadd(local15 + Camera.originX);
Protocol.outboundBuffer.p2le(anInt506);
Protocol.outboundBuffer.ip2add(local36);
Protocol.outboundBuffer.ip2add(local15 + Camera.originX);
Protocol.outboundBuffer.ip2(anInt506);
}
if (local23 == 12) {
Protocol.outboundBuffer.p1isaac(82);
Protocol.outboundBuffer.p2(anInt506);
Protocol.outboundBuffer.p4rme(local19);
Protocol.outboundBuffer.imp4(local19);
Protocol.outboundBuffer.p4(anInt2512);
Protocol.outboundBuffer.p2leadd(local15);
Protocol.outboundBuffer.ip2add(local15);
}
if (local23 == 36) {
if (local36 == 0) {
@ -1016,7 +1016,7 @@ public class MiniMenu {
Protocol.outboundBuffer.p1isaac(33);
Protocol.outboundBuffer.p2(local36);
Protocol.outboundBuffer.p2(Camera.originX + local15);
Protocol.outboundBuffer.p2le(Camera.originZ + local19);
Protocol.outboundBuffer.ip2(Camera.originZ + local19);
}
if (local23 == 16) {
local192 = NpcList.npcs[local36];
@ -1027,7 +1027,7 @@ public class MiniMenu {
Cross.y = Mouse.clickY;
Cross.type = 2;
Protocol.outboundBuffer.p1isaac(3);
Protocol.outboundBuffer.p2leadd(local36);
Protocol.outboundBuffer.ip2add(local36);
}
}
if (anInt5014 != 0) {

View file

@ -611,7 +611,7 @@ public final class NpcType {
count = arg1.g1();
this.aByteArray51 = new byte[count];
for (local18 = 0; local18 < count; local18++) {
this.aByteArray51[local18] = arg1.g1s();
this.aByteArray51[local18] = arg1.g1b();
}
} else if (arg0 == 60) {
count = arg1.g1();
@ -630,9 +630,9 @@ public final class NpcType {
} else if (arg0 == 99) {
this.aBoolean182 = true;
} else if (arg0 == 100) {
this.anInt3715 = arg1.g1s();
this.anInt3715 = arg1.g1b();
} else if (arg0 == 101) {
this.anInt3738 = arg1.g1s() * 5;
this.anInt3738 = arg1.g1b() * 5;
} else if (arg0 == 102) {
this.prayerIcon = arg1.g2();
} else if (arg0 == 103) {
@ -674,29 +674,29 @@ public final class NpcType {
this.aShort24 = (short) arg1.g2();
this.aShort23 = (short) arg1.g2();
} else if (arg0 == 114) {
this.aByte13 = arg1.g1s();
this.aByte12 = arg1.g1s();
this.aByte13 = arg1.g1b();
this.aByte12 = arg1.g1b();
} else if (arg0 == 115) {
arg1.g1();
arg1.g1();
} else if (arg0 == 119) {
this.aByte10 = arg1.g1s();
this.aByte10 = arg1.g1b();
} else if (arg0 == 121) {
this.anIntArrayArray29 = new int[this.modelIndices.length][];
count = arg1.g1();
for (local18 = 0; local18 < count; local18++) {
local297 = arg1.g1();
@Pc(439) int[] local439 = this.anIntArrayArray29[local297] = new int[3];
local439[0] = arg1.g1s();
local439[1] = arg1.g1s();
local439[2] = arg1.g1s();
local439[0] = arg1.g1b();
local439[1] = arg1.g1b();
local439[2] = arg1.g1b();
}
} else if (arg0 == 122) {
this.hitBarId = arg1.g2();
} else if (arg0 == 123) {
this.anInt3730 = arg1.g2();
} else if (arg0 == 125) {
this.aByte11 = arg1.g1s();
this.aByte11 = arg1.g1b();
} else if (arg0 == 126) {
this.anInt3739 = arg1.g2();
} else if (arg0 == 127) {

View file

@ -429,7 +429,7 @@ public final class ObjType {
local169 = arg0.g1();
this.recolorDestinationPalette = new byte[local169];
for (local179 = 0; local179 < local169; local179++) {
this.recolorDestinationPalette[local179] = arg0.g1s();
this.recolorDestinationPalette[local179] = arg0.g1b();
}
} else if (arg1 == 65) {
this.stockMarket = true;
@ -467,9 +467,9 @@ public final class ObjType {
} else if (arg1 == 112) {
this.resizeZ = arg0.g2();
} else if (arg1 == 113) {
this.ambient = arg0.g1s();
this.ambient = arg0.g1b();
} else if (arg1 == 114) {
this.contrast = arg0.g1s() * 5;
this.contrast = arg0.g1b() * 5;
} else if (arg1 == 115) {
this.team = arg0.g1();
} else if (arg1 == 121) {
@ -477,13 +477,13 @@ public final class ObjType {
} else if (arg1 == 122) {
this.lentTemplate = arg0.g2();
} else if (arg1 == 125) {
this.manWearXOff = arg0.g1s();
this.manWearYOff = arg0.g1s();
this.manWearZOff = arg0.g1s();
this.manWearXOff = arg0.g1b();
this.manWearYOff = arg0.g1b();
this.manWearZOff = arg0.g1b();
} else if (arg1 == 126) {
this.womanWearXOff = arg0.g1s();
this.womanWearYOff = arg0.g1s();
this.womanWearZOff = arg0.g1s();
this.womanWearXOff = arg0.g1b();
this.womanWearYOff = arg0.g1b();
this.womanWearZOff = arg0.g1b();
} else if (arg1 == 127) {
this.cursor1Op = arg0.g1();
this.cursor1 = arg0.g2();

View file

@ -220,8 +220,8 @@ public final class Player extends PathingEntity {
this.anInt1651 = local20 >> 6 & 0x3;
this.xFine += (this.getSize() - local41) * 64;
this.zFine += (this.getSize() - local41) * 64;
this.anInt1669 = arg0.g1s();
this.anInt1649 = arg0.g1s();
this.anInt1669 = arg0.g1b();
this.anInt1649 = arg0.g1b();
this.anInt1650 = 0;
@Pc(111) int local111;
@Pc(127) int local127;

View file

@ -69,11 +69,11 @@ public class Protocol {
ChangeLocRequest.push(Player.level, local45, local19, local39, -1, -1, local27, local23, 0);
}
} else if (opcode == ServerProt.LOCATION_PACKET_33) {
int local15 = inboundBuffer.g2le();
int local15 = inboundBuffer.ig2();
int local23 = inboundBuffer.g1();
int local27 = (local23 & 0x7) + Static180.currentChunkZ;
int local19 = (local23 >> 4 & 0x7) + Static115.currentChunkX;
int local31 = inboundBuffer.g2sub();
int local31 = inboundBuffer.g2add();
if (local19 >= 0 && local27 >= 0 && local19 < 104 && local27 < 104) {
@Pc(122) ObjStack local122 = new ObjStack();
local122.anInt5550 = local31;
@ -88,9 +88,9 @@ public class Protocol {
int local15 = inboundBuffer.g1();
int local23 = Static115.currentChunkX * 2 + (local15 >> 4 & 0xF);
int local19 = (local15 & 0xF) + Static180.currentChunkZ * 2;
int local27 = local23 + inboundBuffer.g1s();
int local31 = inboundBuffer.g1s() + local19;
int local39 = inboundBuffer.g2s();
int local27 = local23 + inboundBuffer.g1b();
int local31 = inboundBuffer.g1b() + local19;
int local39 = inboundBuffer.g2b();
int local45 = inboundBuffer.g2();
int local218 = inboundBuffer.g1() * 4;
int local224 = inboundBuffer.g1() * 4;
@ -131,19 +131,19 @@ public class Protocol {
int local31 = inboundBuffer.g1();
int local39 = Static115.currentChunkX + (local31 >> 4 & 0x7);
int local45 = (local31 & 0x7) + Static180.currentChunkZ;
int local218 = inboundBuffer.g2sub();
int local218 = inboundBuffer.g2add();
if (local39 >= 0 && local45 >= 0 && local39 < 104 && local45 < 104) {
ChangeLocRequest.push(Player.level, local45, local19, local39, -1, local218, local27, local23, 0);
}
} else if (opcode == ServerProt.LOCATION_PACKET_20) {
int local15 = inboundBuffer.g1ssub();
int local15 = inboundBuffer.g1sub();
int local23 = (local15 >> 4 & 0x7) + Static115.currentChunkX;
int local19 = Static180.currentChunkZ + (local15 & 0x7);
int local27 = inboundBuffer.g1ssub();
int local27 = inboundBuffer.g1sub();
int local31 = local27 >> 2;
int local39 = local27 & 0x3;
int local45 = Loc.LAYERS[local31];
int local218 = inboundBuffer.g2le();
int local218 = inboundBuffer.ig2();
if (local218 == 65535) {
local218 = -1;
}
@ -155,14 +155,14 @@ public class Protocol {
int local27 = inboundBuffer.g1();
int local31 = (local27 >> 4 & 0x7) + Static115.currentChunkX;
int local39 = (local27 & 0x7) + Static180.currentChunkZ;
@Pc(605) byte local605 = inboundBuffer.p1sub();
@Pc(609) byte local609 = inboundBuffer.p1sub();
@Pc(613) byte local613 = inboundBuffer.g1sub();
int local228 = inboundBuffer.g2sub();
int local232 = inboundBuffer.g2le();
@Pc(625) byte local625 = inboundBuffer.g1s();
@Pc(605) byte local605 = inboundBuffer.g1badd();
@Pc(609) byte local609 = inboundBuffer.g1badd();
@Pc(613) byte local613 = inboundBuffer.g1bsub();
int local228 = inboundBuffer.g2add();
int local232 = inboundBuffer.ig2();
@Pc(625) byte local625 = inboundBuffer.g1b();
int local247 = inboundBuffer.g2();
int local633 = inboundBuffer.g2lesadd();
int local633 = inboundBuffer.ig2badd();
if (!GlRenderer.enabled) {
SceneGraph.method2574(local625, local247, local633, local232, local39, local613, local19, local605, local31, local23, local609, local228);
}
@ -187,12 +187,12 @@ public class Protocol {
}
}
} else if (opcode == ServerProt.LOCATION_PACKET_135) {
int local15 = inboundBuffer.g2leadd();
int local15 = inboundBuffer.ig2add();
int local23 = inboundBuffer.g1neg();
int local27 = Static180.currentChunkZ + (local23 & 0x7);
int local19 = (local23 >> 4 & 0x7) + Static115.currentChunkX;
int local31 = inboundBuffer.g2le();
int local39 = inboundBuffer.g2le();
int local31 = inboundBuffer.ig2();
int local39 = inboundBuffer.ig2();
if (local19 >= 0 && local27 >= 0 && local19 < 104 && local27 < 104 && PlayerList.selfId != local15) {
@Pc(812) ObjStack local812 = new ObjStack();
local812.anInt5550 = local31;
@ -207,9 +207,9 @@ public class Protocol {
int local15 = inboundBuffer.g1();
int local23 = Static115.currentChunkX + (local15 >> 4 & 0x7);
int local19 = (local15 & 0x7) + Static180.currentChunkZ;
int local27 = local23 + inboundBuffer.g1s();
int local31 = inboundBuffer.g1s() + local19;
int local39 = inboundBuffer.g2s();
int local27 = local23 + inboundBuffer.g1b();
int local31 = inboundBuffer.g1b() + local19;
int local39 = inboundBuffer.g2b();
int local45 = inboundBuffer.g2();
int local218 = inboundBuffer.g1() * 4;
int local224 = inboundBuffer.g1() * 4;
@ -233,12 +233,12 @@ public class Protocol {
int local15 = inboundBuffer.g1();
int local19 = Static180.currentChunkZ * 2 + (local15 & 0xF);
int local23 = Static115.currentChunkX * 2 + (local15 >> 4 & 0xF);
int local27 = inboundBuffer.g1s() + local23;
int local31 = inboundBuffer.g1s() + local19;
int local39 = inboundBuffer.g2s();
int local45 = inboundBuffer.g2s();
int local27 = inboundBuffer.g1b() + local23;
int local31 = inboundBuffer.g1b() + local19;
int local39 = inboundBuffer.g2b();
int local45 = inboundBuffer.g2b();
int local218 = inboundBuffer.g2();
int local224 = inboundBuffer.g1s();
int local224 = inboundBuffer.g1b();
int local228 = inboundBuffer.g1() * 4;
int local232 = inboundBuffer.g2();
int local236 = inboundBuffer.g2();
@ -315,7 +315,7 @@ public class Protocol {
}
}
} else if (opcode == ServerProt.LOCATION_PACKET_240) {
int local15 = inboundBuffer.g1ssub();
int local15 = inboundBuffer.g1sub();
int local19 = Static180.currentChunkZ + (local15 & 0x7);
int local23 = (local15 >> 4 & 0x7) + Static115.currentChunkX;
int local27 = inboundBuffer.g2();
@ -350,18 +350,18 @@ public class Protocol {
@Pc(151) int local151;
@Pc(169) int local169;
if (!Static230.dynamicMapRegion) {
local13 = inboundBuffer.g2sub();
local13 = inboundBuffer.g2add();
local20 = (length - inboundBuffer.offset) / 16;
LoginManager.regionsXteaKeys = new int[local20][4];
for (local26 = 0; local26 < local20; local26++) {
for (local31 = 0; local31 < 4; local31++) {
LoginManager.regionsXteaKeys[local26][local31] = inboundBuffer.g4me();
LoginManager.regionsXteaKeys[local26][local31] = inboundBuffer.mg4();
}
}
local26 = inboundBuffer.g1ssub();
local26 = inboundBuffer.g1sub();
local31 = inboundBuffer.g2();
local60 = inboundBuffer.g2sub();
local64 = inboundBuffer.g2sub();
local60 = inboundBuffer.g2add();
local64 = inboundBuffer.g2add();
LoginManager.regionBitPacked = new int[local20];
LoginManager.mapFilesBuffer = new byte[local20][];
LoginManager.npcSpawnsFilesBuffer = null;
@ -400,10 +400,10 @@ public class Protocol {
LoginManager.method2463(local26, local60, local31, local64, false, local13);
return;
}
local13 = inboundBuffer.g2leadd();
local20 = inboundBuffer.g2leadd();
local26 = inboundBuffer.g1ssub();
local31 = inboundBuffer.g2leadd();
local13 = inboundBuffer.ig2add();
local20 = inboundBuffer.ig2add();
local26 = inboundBuffer.g1sub();
local31 = inboundBuffer.ig2add();
inboundBuffer.accessBits();
@Pc(391) int local391;
for (local60 = 0; local60 < 4; local60++) {
@ -423,7 +423,7 @@ public class Protocol {
LoginManager.regionsXteaKeys = new int[local60][4];
for (local64 = 0; local64 < local60; local64++) {
for (local391 = 0; local391 < 4; local391++) {
LoginManager.regionsXteaKeys[local64][local391] = inboundBuffer.g4me();
LoginManager.regionsXteaKeys[local64][local391] = inboundBuffer.mg4();
}
}
local64 = inboundBuffer.g2();
@ -477,7 +477,7 @@ public class Protocol {
@Pc(17) int int2;
@Pc(24) int local24;
if ((flags & 0x80) != 0) {
int1 = inboundBuffer.g2le();
int1 = inboundBuffer.ig2();
int2 = inboundBuffer.g1();
@Pc(21) int local21 = inboundBuffer.g1();
local24 = inboundBuffer.offset;
@ -499,7 +499,7 @@ public class Protocol {
}
if (!ignore && Player.inTutorialIsland == 0) {
chatBuffer.offset = 0;
inboundBuffer.gBytesRev(local21, chatBuffer.data);
inboundBuffer.igdata(local21, chatBuffer.data);
chatBuffer.offset = 0;
@Pc(106) int local106 = -1;
@Pc(127) JagString message;
@ -527,11 +527,11 @@ public class Protocol {
inboundBuffer.offset = local24 + local21;
}
if ((flags & 0x1) != 0) {
int1 = inboundBuffer.gSmart1or2();
int1 = inboundBuffer.gsmarts();
int2 = inboundBuffer.g1add();
player.addHit(int2, client.loop, int1);
player.hitpointsBarVisibleUntil = client.loop + 300;
player.hitpointsBar = inboundBuffer.g1ssub();
player.hitpointsBar = inboundBuffer.g1sub();
}
if ((flags & 0x8) != 0) {
int1 = inboundBuffer.g2();
@ -545,12 +545,12 @@ public class Protocol {
int1 = inboundBuffer.g1add();
@Pc(309) byte[] bytes = new byte[int1];
@Pc(314) Buffer buffer = new Buffer(bytes);
inboundBuffer.gBytes(int1, bytes);
inboundBuffer.gdata(int1, bytes);
PlayerList.appearanceCache[id] = buffer;
player.decodeAppearance(buffer);
}
if ((flags & 0x2) != 0) {
player.faceEntity = inboundBuffer.g2sub();
player.faceEntity = inboundBuffer.g2add();
if (player.faceEntity == 65535) {
player.faceEntity = -1;
}
@ -560,8 +560,8 @@ public class Protocol {
player.anInt3428 = inboundBuffer.g1();
player.anInt3416 = inboundBuffer.g1add();
player.anInt3392 = inboundBuffer.g1();
player.anInt3395 = inboundBuffer.g2le() + client.loop;
player.anInt3386 = inboundBuffer.g2le() + client.loop;
player.anInt3395 = inboundBuffer.ig2() + client.loop;
player.anInt3386 = inboundBuffer.ig2() + client.loop;
player.anInt3431 = inboundBuffer.g1neg();
player.movementQueueSize = 1;
player.anInt3405 = 0;
@ -579,8 +579,8 @@ public class Protocol {
player.chatLoops = 150;
}
if ((flags & 0x200) != 0) {
int1 = inboundBuffer.gSmart1or2();
int2 = inboundBuffer.g1ssub();
int1 = inboundBuffer.gsmarts();
int2 = inboundBuffer.g1sub();
player.addHit(int2, client.loop, int1);
}
if ((flags & 0x800) != 0) {
@ -589,7 +589,7 @@ public class Protocol {
@Pc(505) int[] delays = new int[int1];
@Pc(508) int[] slotMasks = new int[int1];
for (@Pc(510) int i = 0; i < int1; i++) {
@Pc(521) int seqId = inboundBuffer.g2le();
@Pc(521) int seqId = inboundBuffer.ig2();
if (seqId == 65535) {
seqId = -1;
}
@ -600,11 +600,11 @@ public class Protocol {
Player.method865(delays, seqIds, player, slotMasks);
}
if ((flags & 0x100) != 0) {
int1 = inboundBuffer.g2le();
int1 = inboundBuffer.ig2();
if (int1 == 65535) {
int1 = -1;
}
int2 = inboundBuffer.g4me();
int2 = inboundBuffer.mg4();
@Pc(573) boolean local573 = int1 == -1 || player.spotAnimId == -1 || SeqTypeList.get(SpotAnimTypeList.get(int1).seqId).forcedPriority >= SeqTypeList.get(SpotAnimTypeList.get(player.spotAnimId).seqId).forcedPriority;
if (local573) {
player.spotAnimStart = (int2 & 0xFFFF) + client.loop;
@ -629,7 +629,7 @@ public class Protocol {
}
if ((flags & 0x40) != 0) {
player.faceX = inboundBuffer.g2();
player.faceY = inboundBuffer.g2leadd();
player.faceY = inboundBuffer.ig2add();
}
}
@ -875,8 +875,8 @@ public class Protocol {
Static201.anInt1862 = 0;
if (opcode == ServerProt.VARP_SMALL) {
int id = inboundBuffer.g2sub();
@Pc(137) byte value = inboundBuffer.g1sneg();
int id = inboundBuffer.g2add();
@Pc(137) byte value = inboundBuffer.g1bneg();
VarpDomain.set(value, id);
opcode = -1;
return true;
@ -1012,8 +1012,8 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.IF_SETTEXT3) {
int id = inboundBuffer.g2le();
int tracknum = inboundBuffer.g2sub();
int id = inboundBuffer.ig2();
int tracknum = inboundBuffer.g2add();
JagString value = inboundBuffer.gjstr();
setVerifyId(tracknum);
DelayedStateChange.method3498(value, id);
@ -1021,7 +1021,7 @@ public class Protocol {
return true;
} else if (opcode == ServerProt.BATCH_LOCATION_PACKET) {
Static180.currentChunkZ = inboundBuffer.g1add();
Static115.currentChunkX = inboundBuffer.g1ssub();
Static115.currentChunkX = inboundBuffer.g1sub();
while (length > inboundBuffer.offset) {
opcode = inboundBuffer.g1();
readLocationPacket();
@ -1033,8 +1033,8 @@ public class Protocol {
LoginManager.mapFlagX = 0;
return true;
} else if (opcode == ServerProt.IF_SETSCROLLPOS) {
int id = inboundBuffer.g4me();
int pos = inboundBuffer.g2le();
int id = inboundBuffer.mg4();
int pos = inboundBuffer.ig2();
int tracknum = inboundBuffer.g2();
setVerifyId(tracknum);
DelayedStateChange.method3938(pos, id);
@ -1042,7 +1042,7 @@ public class Protocol {
return true;
} else if (opcode == ServerProt.CLAN_QUICK_CHAT) {
long name37 = inboundBuffer.g8();
inboundBuffer.g1s();
inboundBuffer.g1b();
long clan37 = inboundBuffer.g8();
int top = inboundBuffer.g2();
int bot = inboundBuffer.g3();
@ -1102,7 +1102,7 @@ public class Protocol {
long name37 = inboundBuffer.g8();
ClanChat.name = Base37.decode37(name37);
ClanChat.owner = Base37.decode37(owner37);
ClanChat.minKick = inboundBuffer.g1s();
ClanChat.minKick = inboundBuffer.g1b();
int clanSize = inboundBuffer.g1();
if (clanSize == 255) {
opcode = -1;
@ -1116,7 +1116,7 @@ public class Protocol {
members[i].key = inboundBuffer.g8();
members[i].username = Base37.decode37(members[i].key);
members[i].world = inboundBuffer.g2();
members[i].rank = inboundBuffer.g1s();
members[i].rank = inboundBuffer.g1b();
members[i].worldName = inboundBuffer.gjstr();
if (members[i].key == Player.name37) {
ClanChat.rank = members[i].rank;
@ -1143,7 +1143,7 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.LAST_LOGIN_INFO) {
int ip32 = inboundBuffer.g4rme();
int ip32 = inboundBuffer.img4();
Player.lastLogAddress = GameShell.signLink.getReverseDns(ip32);
opcode = -1;
return true;
@ -1154,7 +1154,7 @@ public class Protocol {
} else if (opcode == ServerProt.IF_SETTEXT2) {
int tracknum = inboundBuffer.g2();
JagString text = inboundBuffer.gjstr();
int id = inboundBuffer.g2leadd();
int id = inboundBuffer.ig2add();
setVerifyId(tracknum);
DelayedStateChange.method3498(text, id);
opcode = -1;
@ -1166,7 +1166,7 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.SET_INTERACTION) {
int cursor = inboundBuffer.g2leadd();
int cursor = inboundBuffer.ig2add();
if (cursor == 65535) {
cursor = -1;
}
@ -1185,22 +1185,22 @@ public class Protocol {
return true;
} else if (opcode == ServerProt.VARP_LARGE) {
int value = inboundBuffer.g4();
int id = inboundBuffer.g2sub();
int id = inboundBuffer.g2add();
VarpDomain.set(value, id);
opcode = -1;
return true;
} else if (opcode == ServerProt.IF_SETHIDE) {
int parent = inboundBuffer.g1neg();
int tracknum = inboundBuffer.g2();
int reset = inboundBuffer.g4le();
int reset = inboundBuffer.ig4();
setVerifyId(tracknum);
DelayedStateChange.method2905(reset, parent);
opcode = -1;
return true;
} else if (opcode == ServerProt.IF_OPENSUB) {
int parent = inboundBuffer.g2leadd();
int parent = inboundBuffer.ig2add();
int reset = inboundBuffer.g1add();
int tracknum = inboundBuffer.g2leadd();
int tracknum = inboundBuffer.ig2add();
setVerifyId(tracknum);
if (reset == 2) {
WorldMap.reset();
@ -1215,9 +1215,9 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.CLIENT_SETVARC_LARGE) {
int tracknum = inboundBuffer.g2leadd();
int tracknum = inboundBuffer.ig2add();
int value = inboundBuffer.g4();
int id = inboundBuffer.g2sub();
int id = inboundBuffer.g2add();
setVerifyId(tracknum);
DelayedStateChange.updateVarC(id, value);
opcode = -1;
@ -1251,22 +1251,22 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.IF_SETANIM) {
int id = inboundBuffer.g4me();
int value = inboundBuffer.g2les();
int tracknum = inboundBuffer.g2sub();
int id = inboundBuffer.mg4();
int value = inboundBuffer.ig2b();
int tracknum = inboundBuffer.g2add();
setVerifyId(tracknum);
DelayedStateChange.method3893(id, value);
opcode = -1;
return true;
} else if (opcode == ServerProt.WIDGETSTRUCT_SETTING) {
int value = inboundBuffer.g2leadd();
int parent = inboundBuffer.g4le();
int tracknum = inboundBuffer.g2sub();
int end = inboundBuffer.g2le();
int value = inboundBuffer.ig2add();
int parent = inboundBuffer.ig4();
int tracknum = inboundBuffer.g2add();
int end = inboundBuffer.ig2();
if (end == 65535) {
end = -1;
}
int start = inboundBuffer.g2sub();
int start = inboundBuffer.g2add();
if (start == 65535) {
start = -1;
}
@ -1289,9 +1289,9 @@ public class Protocol {
return true;
} else if (opcode == ServerProt.SPOTANIM_SPECIFIC) {
int delay = inboundBuffer.g2();
int height = inboundBuffer.g2le();
int target = inboundBuffer.g4rme();
int gfxId = inboundBuffer.g2leadd();
int height = inboundBuffer.ig2();
int target = inboundBuffer.img4();
int gfxId = inboundBuffer.ig2add();
if (target >> 30 == 0) {
@Pc(1994) SeqType seq;
if (target >> 29 != 0) {
@ -1372,10 +1372,10 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.INTERFACE_ANIMATE_ROTATE) {
int ptr = inboundBuffer.g4me();
int tracknum = inboundBuffer.g2sub();
int ptr = inboundBuffer.mg4();
int tracknum = inboundBuffer.g2add();
int pitchStep = inboundBuffer.g2();
int yawStep = inboundBuffer.g2sub();
int yawStep = inboundBuffer.g2add();
setVerifyId(tracknum);
DelayedStateChange.setComponentModelRotationSpeedServer(yawStep + (pitchStep << 16), ptr);
opcode = -1;
@ -1383,7 +1383,7 @@ public class Protocol {
} else if (opcode == ServerProt.UPDATE_STAT) {
InterfaceList.redrawActiveInterfaces();
int level = inboundBuffer.g1add();
int xp = inboundBuffer.g4rme();
int xp = inboundBuffer.img4();
int skill = inboundBuffer.g1();
PlayerSkillXpTable.experience[skill] = xp;
PlayerSkillXpTable.boostedLevels[skill] = level;
@ -1415,7 +1415,7 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.CAM_FORCEANGLE) {
int yaw = inboundBuffer.g2le();
int yaw = inboundBuffer.ig2();
int tracknum = inboundBuffer.g2();
int pitch = inboundBuffer.g2();
setVerifyId(tracknum);
@ -1430,9 +1430,9 @@ public class Protocol {
return true;
} else if (opcode == ServerProt.IF_SETANGLE) {
int pitch = inboundBuffer.g2();
int tracknum = inboundBuffer.g2sub();
int scale = inboundBuffer.g2leadd();
int yaw = inboundBuffer.g2leadd();
int tracknum = inboundBuffer.g2add();
int scale = inboundBuffer.ig2add();
int yaw = inboundBuffer.ig2add();
int ptr = inboundBuffer.g4();
setVerifyId(tracknum);
DelayedStateChange.updateView(scale, ptr, yaw, pitch);
@ -1457,7 +1457,7 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.INTERFACE_ITEMS_CLEAR) {
int id = inboundBuffer.g4me();
int id = inboundBuffer.mg4();
@Pc(2666) Component component = InterfaceList.getComponent(id);
for (int i = 0; i < component.objTypes.length; i++) {
component.objTypes[i] = -1;
@ -1467,9 +1467,9 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.IF_SETMODEL) {
int id = inboundBuffer.g4le();
int tracknum = inboundBuffer.g2leadd();
int modelId = inboundBuffer.g2sub();
int id = inboundBuffer.ig4();
int tracknum = inboundBuffer.ig2add();
int modelId = inboundBuffer.g2add();
if (modelId == 65535) {
modelId = -1;
}
@ -1482,7 +1482,7 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.TELEPORT_LOCAL_PLAYER) {
int pos1 = inboundBuffer.g1ssub();
int pos1 = inboundBuffer.g1sub();
int flags = inboundBuffer.g1add();
int pos2 = inboundBuffer.g1();
Player.level = flags >> 1;
@ -1639,9 +1639,9 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.SWITCH_WIDGET) {
int source = inboundBuffer.g4rme();
int tracknum = inboundBuffer.g2sub();
int target = inboundBuffer.g4rme();
int source = inboundBuffer.img4();
int tracknum = inboundBuffer.g2add();
int target = inboundBuffer.img4();
setVerifyId(tracknum);
@Pc(3449) ComponentPointer src = (ComponentPointer) InterfaceList.openInterfaces.get(source);
ComponentPointer tgt = (ComponentPointer) InterfaceList.openInterfaces.get(target);
@ -1682,9 +1682,9 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.IF_SETCOLOUR) {
int id = inboundBuffer.g4rme();
int tracknum = inboundBuffer.g2sub();
int color = inboundBuffer.g2leadd();
int id = inboundBuffer.img4();
int tracknum = inboundBuffer.g2add();
int color = inboundBuffer.ig2add();
setVerifyId(tracknum);
DelayedStateChange.setColor(color, id);
opcode = -1;
@ -1699,9 +1699,9 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.CLIENT_SETVARC_SMALL) {
int tracknum = inboundBuffer.g2le();
int tracknum = inboundBuffer.ig2();
int value = inboundBuffer.g1neg();
int id = inboundBuffer.g2leadd();
int id = inboundBuffer.ig2add();
setVerifyId(tracknum);
DelayedStateChange.updateVarC(id, value);
opcode = -1;
@ -1719,14 +1719,14 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.DELETE_INVENTORY) {
int id = inboundBuffer.g2le();
int id = inboundBuffer.ig2();
Inv.delete(id);
Inv.updatedInventories[Inv.updatedInventoriesWriterIndex++ & 0x1F] = id & 0x7FFF;
opcode = -1;
return true;
} else if (opcode == ServerProt.NPC_ANIM_SPECIFIC) {
int npcId = inboundBuffer.g2le();
int value = inboundBuffer.g1ssub();
int npcId = inboundBuffer.ig2();
int value = inboundBuffer.g1sub();
int seqId = inboundBuffer.g2();
@Pc(3766) Npc npc = NpcList.npcs[npcId];
if (npc != null) {
@ -1736,7 +1736,7 @@ public class Protocol {
return true;
} else if (opcode == ServerProt.UPDATE_RUNWEIGHT) {
InterfaceList.redrawActiveInterfaces();
Player.weight = inboundBuffer.g2s();
Player.weight = inboundBuffer.g2b();
InterfaceList.miscTransmitAt = InterfaceList.transmitTimer;
opcode = -1;
return true;
@ -1763,25 +1763,25 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.GENERATE_CHAT_HEAD_FROM_BODY) {
int tracknum = inboundBuffer.g2sub();
int id = inboundBuffer.g4me();
int value1 = inboundBuffer.g2leadd();
int value2 = inboundBuffer.g2le();
int value3 = inboundBuffer.g2leadd();
int tracknum = inboundBuffer.g2add();
int id = inboundBuffer.mg4();
int value1 = inboundBuffer.ig2add();
int value2 = inboundBuffer.ig2();
int value3 = inboundBuffer.ig2add();
setVerifyId(tracknum);
DelayedStateChange.updateComponentModel(value1, 7, id, value2 << 16 | value3);
opcode = -1;
return true;
} else if (opcode == ServerProt.VARBIT_SMALL) {
int value = inboundBuffer.g1add();
int id = inboundBuffer.g2le();
int id = inboundBuffer.ig2();
VarpDomain.setVarbit(value, id);
opcode = -1;
return true;
} else if (opcode == ServerProt.IF_OPENTOP) {
int type = inboundBuffer.g1();
int pointer = inboundBuffer.g4me();
int tracknum = inboundBuffer.g2sub();
int pointer = inboundBuffer.mg4();
int tracknum = inboundBuffer.g2add();
int component = inboundBuffer.g2();
setVerifyId(tracknum);
ComponentPointer ptr = (ComponentPointer) InterfaceList.openInterfaces.get(pointer);
@ -1862,16 +1862,16 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.IF_SETPOSITION) {
int tracknum = inboundBuffer.g2sub();
int ptr = inboundBuffer.g4le();
int x = inboundBuffer.g2s();
int y = inboundBuffer.g2sadd();
int tracknum = inboundBuffer.g2add();
int ptr = inboundBuffer.ig4();
int x = inboundBuffer.g2b();
int y = inboundBuffer.g2badd();
setVerifyId(tracknum);
DelayedStateChange.method4666(x, ptr, y);
opcode = -1;
return true;
} else if (opcode == ServerProt.LOC_ANIM_SPECIFIC) {
int slot = inboundBuffer.g1ssub();
int slot = inboundBuffer.g1sub();
int type = slot >> 2;
int rotation = slot & 0x3;
int type2 = Loc.LAYERS[type];
@ -1934,7 +1934,7 @@ public class Protocol {
return true;
} else if (opcode == ServerProt.MESSAGE_CLANCHANNEL) {
long name37 = inboundBuffer.g8();
inboundBuffer.g1s();
inboundBuffer.g1b();
long chat37 = inboundBuffer.g8();
int top = inboundBuffer.g2();
int bot = inboundBuffer.g3();
@ -1993,8 +1993,8 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.IF_SETPLAYERHEAD) {
int tracknum = inboundBuffer.g2leadd();
int id = inboundBuffer.g4rme();
int tracknum = inboundBuffer.ig2add();
int id = inboundBuffer.img4();
setVerifyId(tracknum);
int set = 0;
if (PlayerList.self.appearance != null) {
@ -2004,16 +2004,16 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.IF_SETTEXT1) {
int id = inboundBuffer.g4me();
int id = inboundBuffer.mg4();
JagString text = inboundBuffer.gjstr();
int tracknum = inboundBuffer.g2sub();
int tracknum = inboundBuffer.g2add();
setVerifyId(tracknum);
DelayedStateChange.method3617(text, id);
opcode = -1;
return true;
} else if (opcode == ServerProt.VARBIT_LARGE) {
int value = inboundBuffer.g4le();
int id = inboundBuffer.g2leadd();
int value = inboundBuffer.ig4();
int id = inboundBuffer.ig2add();
VarpDomain.setVarbit(value, id);
opcode = -1;
return true;
@ -2030,7 +2030,7 @@ public class Protocol {
component = InterfaceList.getComponent(componentHash);
}
while (inboundBuffer.offset < length) {
int slot = inboundBuffer.gSmart1or2();
int slot = inboundBuffer.gsmarts();
int amount = inboundBuffer.g2();
int id = 0;
if (amount != 0) {
@ -2074,12 +2074,12 @@ public class Protocol {
StockMarketManager.transmitAt = InterfaceList.transmitTimer;
return true;
} else if (opcode == ServerProt.IF_SETNPCHEAD) {
int npcId = inboundBuffer.g2sub();
int id = inboundBuffer.g4le();
int npcId = inboundBuffer.g2add();
int id = inboundBuffer.ig4();
if (npcId == 65535) {
npcId = -1;
}
int tracknum = inboundBuffer.g2le();
int tracknum = inboundBuffer.ig2();
setVerifyId(tracknum);
DelayedStateChange.updateComponentModel(-1, 2, id, npcId);
opcode = -1;
@ -2089,14 +2089,14 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.SET_INTERFACE_SETTINGS) {
int tracknum = inboundBuffer.g2le();
int end = inboundBuffer.g2le();
int tracknum = inboundBuffer.ig2();
int end = inboundBuffer.ig2();
if (end == 65535) {
end = -1;
}
int pointer = inboundBuffer.g4();
int start = inboundBuffer.g2sub();
int accessMask = inboundBuffer.g4rme();
int start = inboundBuffer.g2add();
int accessMask = inboundBuffer.img4();
if (start == 65535) {
start = -1;
}
@ -2125,7 +2125,7 @@ public class Protocol {
} else if (opcode == ServerProt.UPDATE_CLAN) {
long name37 = inboundBuffer.g8();
int worldId = inboundBuffer.g2();
@Pc(5325) byte rights = inboundBuffer.g1s();
@Pc(5325) byte rights = inboundBuffer.g1b();
boolean ignored = (Long.MIN_VALUE & name37) != 0L;
if (ignored) {
if (ClanChat.size == 0) {
@ -2191,12 +2191,12 @@ public class Protocol {
return true;
} else if (opcode == ServerProt.IF_SETOBJECT) {
int slot = inboundBuffer.g4();
int id = inboundBuffer.g4me();
int itemId = inboundBuffer.g2leadd();
int id = inboundBuffer.mg4();
int itemId = inboundBuffer.ig2add();
if (itemId == 65535) {
itemId = -1;
}
int tracknum = inboundBuffer.g2le();
int tracknum = inboundBuffer.ig2();
setVerifyId(tracknum);
@Pc(5603) Component component = InterfaceList.getComponent(id);
@Pc(5615) ObjType objType;
@ -2241,7 +2241,7 @@ public class Protocol {
Static14.method475(containerId);
int total = inboundBuffer.g2();
for (int slot = 0; slot < total; slot++) {
int amount = inboundBuffer.g1ssub();
int amount = inboundBuffer.g1sub();
if (amount == 255) {
amount = inboundBuffer.g4();
}
@ -2269,7 +2269,7 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.MIDI_SONG) {
int id = inboundBuffer.g2leadd();
int id = inboundBuffer.ig2add();
if (id == 65535) {
id = -1;
}
@ -2277,8 +2277,8 @@ public class Protocol {
opcode = -1;
return true;
} else if (opcode == ServerProt.MIDI_JINGLE) {
int volume = inboundBuffer.g3le();
int id = inboundBuffer.g2le();
int volume = inboundBuffer.ig3();
int id = inboundBuffer.ig2();
if (id == 65535) {
id = -1;
}
@ -2406,7 +2406,7 @@ public class Protocol {
anInt4762++;
}
}
outboundBuffer.p1len(outboundBuffer.offset - offset);
outboundBuffer.psize1(outboundBuffer.offset - offset);
if (MouseRecorder.instance.samples > type) {
MouseRecorder.instance.samples -= type;
for (i = 0; i < MouseRecorder.instance.samples; i++) {
@ -2442,8 +2442,8 @@ public class Protocol {
button = 1;
}
outboundBuffer.p1isaac(75);
outboundBuffer.p2leadd(button << 15 | x);
outboundBuffer.p4me(i | type << 16);
outboundBuffer.ip2add(button << 15 | x);
outboundBuffer.mp4(i | type << 16);
}
if (Static16.anInt551 > 0) {
Static16.anInt551--;
@ -2464,7 +2464,7 @@ public class Protocol {
Static197.aBoolean228 = false;
outboundBuffer.p1isaac(21);
outboundBuffer.p2add((int)Camera.pitchTarget);
outboundBuffer.p2le((int)Camera.yawTarget);
outboundBuffer.ip2((int)Camera.yawTarget);
}
if (GameShell.focus && !Static67.prevFocus) {
Static67.prevFocus = true;
@ -2680,7 +2680,7 @@ public class Protocol {
}
outboundBuffer.p1isaac(231);
outboundBuffer.p2(Static4.mouseOverInventoryObjectIndex);
outboundBuffer.p4le2(Static118.clickedInventoryComponent.id);
outboundBuffer.ip4(Static118.clickedInventoryComponent.id);
outboundBuffer.p2add(Static18.clickedInventoryIndex);
outboundBuffer.p1sub(inserting);
}
@ -2752,9 +2752,9 @@ public class Protocol {
} else if (Static125.anInt3096 == 2) {
if (MiniMenu.anInt1742 != -1) {
outboundBuffer.p1isaac(131);
outboundBuffer.p4me(MiniMenu.anInt2512);
outboundBuffer.mp4(MiniMenu.anInt2512);
outboundBuffer.p2add(Camera.originX + MiniMenu.anInt1742);
outboundBuffer.p2leadd(MiniMenu.anInt506);
outboundBuffer.ip2add(MiniMenu.anInt506);
outboundBuffer.p2add(MiniMenu.anInt2954 + Camera.originZ);
Cross.type = 1;
Cross.milliseconds = 0;
@ -2957,13 +2957,13 @@ public class Protocol {
local47 = inboundBuffer.g1neg(); // Color
npc.addHit(local47, client.loop, local43);
npc.hitpointsBarVisibleUntil = client.loop + 300;
npc.hitpointsBar = inboundBuffer.g1ssub();
npc.hitpointsBar = inboundBuffer.g1sub();
}
boolean hasSecondaryHitsplat = (local18 & 0x2) != 0;
if (hasSecondaryHitsplat) {
local43 = inboundBuffer.g1neg(); // Hit value
local47 = inboundBuffer.g1ssub(); // Color
local47 = inboundBuffer.g1sub(); // Color
npc.addHit(local47, client.loop, local43);
}
@ -2979,7 +2979,7 @@ public class Protocol {
boolean hasFaceEntity = (local18 & 0x4) != 0;
if (hasFaceEntity) {
npc.faceEntity = inboundBuffer.g2sub();
npc.faceEntity = inboundBuffer.g2add();
if (npc.faceEntity == 65535) {
npc.faceEntity = -1;
}
@ -2987,11 +2987,11 @@ public class Protocol {
boolean isKillingBlow = (local18 & 0x80) != 0;
if (isKillingBlow) {
local43 = inboundBuffer.g2sub();
local43 = inboundBuffer.g2add();
if (local43 == 65535) {
local43 = -1;
}
local47 = inboundBuffer.g4le();
local47 = inboundBuffer.ig4();
@Pc(147) boolean local147 = local43 == -1 || npc.spotAnimId == -1 || SeqTypeList.get(SpotAnimTypeList.get(local43).seqId).forcedPriority >= SeqTypeList.get(SpotAnimTypeList.get(npc.spotAnimId).seqId).forcedPriority;
if (local147) {
npc.spotAnimId = local43;
@ -3020,7 +3020,7 @@ public class Protocol {
if (npc.type.hasAreaSound()) {
AreaSoundManager.remove(npc);
}
npc.setNpcType(NpcTypeList.get(inboundBuffer.g2le()));
npc.setNpcType(NpcTypeList.get(inboundBuffer.ig2()));
npc.setSize(npc.type.size);
npc.anInt3365 = npc.type.basId;
if (npc.type.hasAreaSound()) {
@ -3039,12 +3039,12 @@ public class Protocol {
@Pc(334) int[] local334 = new int[local43];
@Pc(337) int[] local337 = new int[local43];
for (@Pc(339) int i1 = 0; i1 < local43; i1++) {
@Pc(350) int local350 = inboundBuffer.g2le();
@Pc(350) int local350 = inboundBuffer.ig2();
if (local350 == 65535) {
local350 = -1;
}
local331[i1] = local350;
local334[i1] = inboundBuffer.g1ssub();
local334[i1] = inboundBuffer.g1sub();
local337[i1] = inboundBuffer.g2();
}
Static159.method3037(local337, npc, local334, local331);
@ -3052,7 +3052,7 @@ public class Protocol {
boolean hasFaceLocation = (local18 & 0x200) != 0;
if (hasFaceLocation) {
npc.faceX = inboundBuffer.g2sub();
npc.faceX = inboundBuffer.g2add();
npc.faceY = inboundBuffer.g2();
}
}

View file

@ -70,7 +70,7 @@ public final class QuickChatCatType extends SecondaryNode {
this.subcategoryShortcuts = new int[local28];
for (local38 = 0; local38 < local28; local38++) {
this.subcategories[local38] = arg0.g2();
this.subcategoryShortcuts[local38] = method3933(arg0.g1s());
this.subcategoryShortcuts[local38] = method3933(arg0.g1b());
}
} else if (arg1 == 3) {
local28 = arg0.g1();
@ -78,7 +78,7 @@ public final class QuickChatCatType extends SecondaryNode {
this.phraseShortcuts = new int[local28];
for (local38 = 0; local38 < local28; local38++) {
this.phrases[local38] = arg0.g2();
this.phraseShortcuts[local38] = method3933(arg0.g1s());
this.phraseShortcuts[local38] = method3933(arg0.g1b());
}
} else if (arg1 == 4) {
}

View file

@ -963,7 +963,7 @@ public final class RawModel extends Entity {
buffer1.offset = 0;
for (int i = 0; i < texturedCount; i++) {
@Pc(143) byte type = this.textureTypes[i] = buffer1.g1s();
@Pc(143) byte type = this.textureTypes[i] = buffer1.g1b();
if (type == 0) {
simpleTextureFaceCount++;
} else if (type >= 1 && type <= 3) {
@ -1125,17 +1125,17 @@ public final class RawModel extends Entity {
int dx = 0;
if ((flags & 0x1) != 0) {
dx = buffer2.gSmart1or2s();
dx = buffer2.gsmart();
}
int dy = 0;
if ((flags & 0x2) != 0) {
dy = buffer3.gSmart1or2s();
dy = buffer3.gsmart();
}
int dz = 0;
if ((flags & 0x4) != 0) {
dz = buffer4.gSmart1or2s();
dz = buffer4.gsmart();
}
this.vertexX[v] = prevVertexX + dx;
@ -1163,15 +1163,15 @@ public final class RawModel extends Entity {
this.triangleColors[t] = (short) buffer1.g2();
if (hasTriangleInfo) {
this.triangleInfo[t] = buffer2.g1s();
this.triangleInfo[t] = buffer2.g1b();
}
if (priority == 255) {
this.trianglePriorities[t] = buffer3.g1s();
this.trianglePriorities[t] = buffer3.g1b();
}
if (hasAlpha == 1) {
this.triangleAlpha[t] = buffer4.g1s();
this.triangleAlpha[t] = buffer4.g1b();
}
if (hasTriangleBones == 1) {
@ -1202,23 +1202,23 @@ public final class RawModel extends Entity {
for (int t = 0; t < triangleCount; t++) {
int type = buffer2.g1();
if (type == 1) {
a = buffer1.gSmart1or2s() + last;
b = buffer1.gSmart1or2s() + a;
c = buffer1.gSmart1or2s() + b;
a = buffer1.gsmart() + last;
b = buffer1.gsmart() + a;
c = buffer1.gsmart() + b;
last = c;
this.triangleVertexA[t] = a;
this.triangleVertexB[t] = b;
this.triangleVertexC[t] = c;
} else if (type == 2) {
b = c;
c = buffer1.gSmart1or2s() + last;
c = buffer1.gsmart() + last;
last = c;
this.triangleVertexA[t] = a;
this.triangleVertexB[t] = b;
this.triangleVertexC[t] = c;
} else if (type == 3) {
a = c;
c = buffer1.gSmart1or2s() + last;
c = buffer1.gsmart() + last;
last = c;
this.triangleVertexA[t] = a;
this.triangleVertexB[t] = b;
@ -1227,7 +1227,7 @@ public final class RawModel extends Entity {
@Pc(803) int b0 = a;
a = b;
b = b0;
c = buffer1.gSmart1or2s() + last;
c = buffer1.gsmart() + last;
last = c;
this.triangleVertexA[t] = a;
this.triangleVertexB[t] = b0;
@ -1255,9 +1255,9 @@ public final class RawModel extends Entity {
this.texturesScaleX[t] = (short) buffer3.g2();
this.texturesScaleY[t] = (short) buffer3.g2();
this.texturesScaleZ[t] = (short) buffer3.g2();
this.textureRotationY[t] = buffer4.g1s();
this.aByteArray32[t] = buffer5.g1s();
this.aByteArray34[t] = buffer6.g1s();
this.textureRotationY[t] = buffer4.g1b();
this.aByteArray32[t] = buffer5.g1b();
this.aByteArray34[t] = buffer6.g1b();
} else if (type == 2) {
this.textureFacesP[t] = (short) buffer2.g2();
this.textureFacesM[t] = (short) buffer2.g2();
@ -1265,11 +1265,11 @@ public final class RawModel extends Entity {
this.texturesScaleX[t] = (short) buffer3.g2();
this.texturesScaleY[t] = (short) buffer3.g2();
this.texturesScaleZ[t] = (short) buffer3.g2();
this.textureRotationY[t] = buffer4.g1s();
this.aByteArray32[t] = buffer5.g1s();
this.aByteArray34[t] = buffer6.g1s();
this.aByteArray28[t] = buffer6.g1s();
this.aByteArray33[t] = buffer6.g1s();
this.textureRotationY[t] = buffer4.g1b();
this.aByteArray32[t] = buffer5.g1b();
this.aByteArray34[t] = buffer6.g1b();
this.aByteArray28[t] = buffer6.g1b();
this.aByteArray33[t] = buffer6.g1b();
} else if (type == 3) {
this.textureFacesP[t] = (short) buffer2.g2();
this.textureFacesM[t] = (short) buffer2.g2();
@ -1277,9 +1277,9 @@ public final class RawModel extends Entity {
this.texturesScaleX[t] = (short) buffer3.g2();
this.texturesScaleY[t] = (short) buffer3.g2();
this.texturesScaleZ[t] = (short) buffer3.g2();
this.textureRotationY[t] = buffer4.g1s();
this.aByteArray32[t] = buffer5.g1s();
this.aByteArray34[t] = buffer6.g1s();
this.textureRotationY[t] = buffer4.g1b();
this.aByteArray32[t] = buffer5.g1b();
this.aByteArray34[t] = buffer6.g1b();
}
}
@ -1741,17 +1741,17 @@ public final class RawModel extends Entity {
int dx = 0;
if ((flags & 0x1) != 0) {
dx = buffer2.gSmart1or2s();
dx = buffer2.gsmart();
}
int dy = 0;
if ((flags & 0x2) != 0) {
dy = buffer3.gSmart1or2s();
dy = buffer3.gsmart();
}
int dz = 0;
if ((flags & 0x4) != 0) {
dz = buffer4.gSmart1or2s();
dz = buffer4.gsmart();
}
this.vertexX[v] = prevVertexX + dx;
@ -1799,11 +1799,11 @@ public final class RawModel extends Entity {
}
if (hasPriorities == 255) {
this.trianglePriorities[t] = buffer3.g1s();
this.trianglePriorities[t] = buffer3.g1b();
}
if (hasAlpha == 1) {
this.triangleAlpha[t] = buffer4.g1s();
this.triangleAlpha[t] = buffer4.g1b();
}
if (hasTriangleBones == 1) {
@ -1822,23 +1822,23 @@ public final class RawModel extends Entity {
for (int t = 0; t < triangleCount; t++) {
int type = buffer2.g1();
if (type == 1) {
a = buffer1.gSmart1or2s() + last;
b = buffer1.gSmart1or2s() + a;
c = buffer1.gSmart1or2s() + b;
a = buffer1.gsmart() + last;
b = buffer1.gsmart() + a;
c = buffer1.gsmart() + b;
last = c;
this.triangleVertexA[t] = a;
this.triangleVertexB[t] = b;
this.triangleVertexC[t] = c;
} else if (type == 2) {
b = c;
c = buffer1.gSmart1or2s() + last;
c = buffer1.gsmart() + last;
last = c;
this.triangleVertexA[t] = a;
this.triangleVertexB[t] = b;
this.triangleVertexC[t] = c;
} else if (type == 3) {
a = c;
c = buffer1.gSmart1or2s() + last;
c = buffer1.gsmart() + last;
last = c;
this.triangleVertexA[t] = a;
this.triangleVertexB[t] = b;
@ -1847,7 +1847,7 @@ public final class RawModel extends Entity {
int b0 = a;
a = b;
b = b0;
c = buffer1.gSmart1or2s() + last;
c = buffer1.gsmart() + last;
last = c;
this.triangleVertexA[t] = a;
this.triangleVertexB[t] = b0;

View file

@ -150,8 +150,8 @@ public final class ReflectionCheck extends Node {
arg0.p1(local18.anIntArray138[local121]);
}
}
arg0.pCrc32(local25);
arg0.p1len(arg0.offset - local25);
arg0.addcrc(local25);
arg0.psize1(arg0.offset - local25);
local18.unlink();
}
}
@ -197,7 +197,7 @@ public final class ReflectionCheck extends Node {
for (@Pc(199) int local199 = 0; local199 < local95; local199++) {
local210 = arg1.g4();
local193[local199] = new byte[local210];
arg1.gBytes(local210, local193[local199]);
arg1.gdata(local210, local193[local199]);
}
}
local17.anIntArray139[local59] = local71;

View file

@ -388,7 +388,7 @@ public class SceneGraph {
break;
}
if (local32 <= 49) {
tileOverlays[arg7][arg5][arg4] = arg3.g1s();
tileOverlays[arg7][arg5][arg4] = arg3.g1b();
tileShapes[arg7][arg5][arg4] = (byte) ((local32 - 2) / 4);
tileAngles[arg7][arg5][arg4] = (byte) (local32 + arg6 - 2 & 0x3);
} else if (local32 > 81) {

View file

@ -2694,7 +2694,7 @@ public final class ScriptRunner {
Protocol.outboundBuffer.p1(local5555);
Protocol.outboundBuffer.p1(local5943);
WordPack.encode(Protocol.outboundBuffer, string);
Protocol.outboundBuffer.p1len(Protocol.outboundBuffer.offset - c);
Protocol.outboundBuffer.psize1(Protocol.outboundBuffer.offset - c);
continue;
}
Cheat.execute(string);
@ -2710,7 +2710,7 @@ public final class ScriptRunner {
int2 = Protocol.outboundBuffer.offset;
Protocol.outboundBuffer.p8(string.encode37());
WordPack.encode(Protocol.outboundBuffer, str1);
Protocol.outboundBuffer.p1len(Protocol.outboundBuffer.offset - int2);
Protocol.outboundBuffer.psize1(Protocol.outboundBuffer.offset - int2);
}
continue;
}
@ -2851,7 +2851,7 @@ public final class ScriptRunner {
Protocol.outboundBuffer.p1(0);
Protocol.outboundBuffer.p2(activePhrase.id);
activePhrase.type.encodeMessage(Protocol.outboundBuffer, activePhrase.values);
Protocol.outboundBuffer.p1len(Protocol.outboundBuffer.offset - int1);
Protocol.outboundBuffer.psize1(Protocol.outboundBuffer.offset - int1);
continue;
}
if (opcode == 5060) {
@ -2863,7 +2863,7 @@ public final class ScriptRunner {
Protocol.outboundBuffer.p8(string.encode37());
Protocol.outboundBuffer.p2(activePhrase.id);
activePhrase.type.encodeMessage(Protocol.outboundBuffer, activePhrase.values);
Protocol.outboundBuffer.p1len(Protocol.outboundBuffer.offset - int3);
Protocol.outboundBuffer.psize1(Protocol.outboundBuffer.offset - int3);
continue;
}
if (opcode == 5061) {
@ -2873,7 +2873,7 @@ public final class ScriptRunner {
Protocol.outboundBuffer.p1(1);
Protocol.outboundBuffer.p2(activePhrase.id);
activePhrase.type.encodeMessage(Protocol.outboundBuffer, activePhrase.values);
Protocol.outboundBuffer.p1len(Protocol.outboundBuffer.offset - int1);
Protocol.outboundBuffer.psize1(Protocol.outboundBuffer.offset - int1);
continue;
}
if (opcode == 5062) {
@ -3249,7 +3249,7 @@ public final class ScriptRunner {
isp--;
int2 = intStack[isp];
Protocol.outboundBuffer.p1isaac(117);
Protocol.outboundBuffer.p1(Buffer.getStringLength(string) + Buffer.getStringLength(str1) + 1);
Protocol.outboundBuffer.p1(Buffer.gjstrlen(string) + Buffer.gjstrlen(str1) + 1);
Protocol.outboundBuffer.pjstr(string);
Protocol.outboundBuffer.pjstr(str1);
Protocol.outboundBuffer.p1(int2);

View file

@ -89,12 +89,12 @@ public final class Shadow {
local147.p4(local154 + local11 * 9 + 1);
local147.p4(local154 + (local11 + 1) * 9 + 1);
} else {
local147.p4le(local154 + (local11 + 1) * 9);
local147.p4le(local154 + local11 * 9);
local147.p4le(local154 + local11 * 9 + 1);
local147.p4le(local154 + (local11 + 1) * 9);
local147.p4le(local154 + local11 * 9 + 1);
local147.p4le(local154 + (local11 + 1) * 9 + 1);
local147.ip4(local154 + (local11 + 1) * 9);
local147.ip4(local154 + local11 * 9);
local147.ip4(local154 + local11 * 9 + 1);
local147.ip4(local154 + (local11 + 1) * 9);
local147.ip4(local154 + local11 * 9 + 1);
local147.ip4(local154 + (local11 + 1) * 9 + 1);
}
}
}

View file

@ -196,7 +196,7 @@ public final class Song extends Node {
}
local500.p1(47);
local500.p1(0);
local500.p4len(local500.offset - local565);
local500.psize4(local500.offset - local565);
continue label221;
}
if (local583 == 23) {

View file

@ -105,11 +105,11 @@ public class SpriteLoader {
@Pc(232) int local232;
if ((local223 & 0x1) == 0) {
for (local232 = 0; local232 < local203; local232++) {
local206[local232] = buffer.g1s();
local206[local232] = buffer.g1b();
}
if ((local223 & 0x2) != 0) {
for (local232 = 0; local232 < local203; local232++) {
@Pc(343) byte local343 = local215[local232] = buffer.g1s();
@Pc(343) byte local343 = local215[local232] = buffer.g1b();
local208 |= local343 != -1;
}
}
@ -127,14 +127,14 @@ public class SpriteLoader {
break label88;
}
for (local241 = 0; local241 < local199; local241++) {
@Pc(291) byte local291 = local215[local195 * local241 + local232] = buffer.g1s();
@Pc(291) byte local291 = local215[local195 * local241 + local232] = buffer.g1b();
local208 |= local291 != -1;
}
local232++;
}
}
for (local241 = 0; local241 < local199; local241++) {
local206[local232 + local241 * local195] = buffer.g1s();
local206[local232 + local241 * local195] = buffer.g1b();
}
local232++;
}

View file

@ -12,10 +12,7 @@ public final class Static115 {
@OriginalMember(owner = "client!ja", name = "f", descriptor = "Lclient!ih;")
public static final LinkedList mediumPriorityRequests = new LinkedList();
@OriginalMember(owner = "client!ja", name = "j", descriptor = "I")
public static int anInt2937 = 0;
@OriginalMember(owner = "client!ja", name = "r", descriptor = "I")
@OriginalMember(owner = "client!ja", name = "r", descriptor = "I")
public static int anInt2941 = -1;
@OriginalMember(owner = "client!ja", name = "s", descriptor = "Lclient!na;")

View file

@ -101,6 +101,6 @@ public final class Static156 {
@OriginalMember(owner = "client!mf", name = "a", descriptor = "(BLclient!wa;)Lclient!ta;")
public static TextureOp29SubOp4 method2960(@OriginalArg(1) Buffer arg0) {
return new TextureOp29SubOp4(arg0.g2s(), arg0.g2s(), arg0.g2s(), arg0.g2s(), arg0.g3(), arg0.g3(), arg0.g1());
return new TextureOp29SubOp4(arg0.g2b(), arg0.g2b(), arg0.g2b(), arg0.g2b(), arg0.g3(), arg0.g3(), arg0.g1());
}
}

View file

@ -30,7 +30,7 @@ public final class Static217 {
local7 += local20;
@Pc(31) int local31 = 0;
while (true) {
@Pc(35) int local35 = local12.gSmart1or2();
@Pc(35) int local35 = local12.gsmarts();
if (local35 == 0) {
break;
}

View file

@ -9,9 +9,6 @@ public final class Static224 {
@OriginalMember(owner = "client!sd", name = "R", descriptor = "I")
public static int anInt5062;
@OriginalMember(owner = "client!sd", name = "T", descriptor = "I")
public static int anInt5064 = 0;
@OriginalMember(owner = "client!sd", name = "c", descriptor = "(II)V")
public static void method3884(@OriginalArg(0) int arg0, @OriginalArg(1) int arg1) {
@Pc(7) Tile local7 = SceneGraph.tiles[0][arg0][arg1];

View file

@ -6,17 +6,10 @@ import org.openrs2.deob.annotation.Pc;
public final class Static228 {
@OriginalMember(owner = "client!dc", name = "db", descriptor = "[[B")
public static final byte[][] aByteArrayArray6 = new byte[50][];
@OriginalMember(owner = "client!sh", name = "e", descriptor = "Lclient!na;")
@OriginalMember(owner = "client!sh", name = "e", descriptor = "Lclient!na;")
public static final JagString aClass100_967 = JagString.parse("");
@OriginalMember(owner = "client!wi", name = "X", descriptor = "[[B")
public static final byte[][] aByteArrayArray16 = new byte[1000][];
@OriginalMember(owner = "client!bb", name = "t", descriptor = "[[B")
public static final byte[][] aByteArrayArray2 = new byte[250][];
@OriginalMember(owner = "client!sh", name = "f", descriptor = "I")
@OriginalMember(owner = "client!sh", name = "f", descriptor = "I")
public static int anInt5103 = -1;
@OriginalMember(owner = "client!sh", name = "i", descriptor = "[[I")
@ -25,26 +18,6 @@ public final class Static228 {
@OriginalMember(owner = "client!sh", name = "k", descriptor = "Z")
public static final boolean aBoolean248 = false;
@OriginalMember(owner = "client!sh", name = "a", descriptor = "(II)[B")
public static synchronized byte[] allocate(@OriginalArg(1) int arg0) {
@Pc(22) byte[] local22;
if (arg0 == 100 && Static115.anInt2937 > 0) {
local22 = aByteArrayArray16[--Static115.anInt2937];
aByteArrayArray16[Static115.anInt2937] = null;
return local22;
} else if (arg0 == 5000 && Static251.anInt5459 > 0) {
local22 = aByteArrayArray2[--Static251.anInt5459];
aByteArrayArray2[Static251.anInt5459] = null;
return local22;
} else if (arg0 == 30000 && Static224.anInt5064 > 0) {
local22 = aByteArrayArray6[--Static224.anInt5064];
aByteArrayArray6[Static224.anInt5064] = null;
return local22;
} else {
return new byte[arg0];
}
}
@OriginalMember(owner = "client!sh", name = "a", descriptor = "(IZBIZ)V")
public static void sortWorldList(@OriginalArg(0) int arg0, @OriginalArg(1) boolean arg1, @OriginalArg(3) int arg2, @OriginalArg(4) boolean arg3) {
Static79.method1697(arg0, arg2, WorldList.sorted.length - 1, arg3, 0, arg1);

View file

@ -50,7 +50,7 @@ public final class Static245 {
break;
}
for (local108 = 0; local108 < 4; local108++) {
@Pc(223) byte local223 = local96.g1s();
@Pc(223) byte local223 = local96.g1b();
@Pc(237) int local237;
if (local223 == 0) {
if (local108 <= arg6) {
@ -89,7 +89,7 @@ public final class Static245 {
} else if (local223 == 1) {
for (local232 = 0; local232 < 64; local232 += 4) {
for (local237 = 0; local237 < 64; local237 += 4) {
@Pc(246) byte local246 = local96.g1s();
@Pc(246) byte local246 = local96.g1b();
if (local108 <= arg6) {
for (local255 = local232; local255 < local232 + 4; local255++) {
for (local266 = local237; local266 < local237 + 4; local266++) {

View file

@ -8,9 +8,6 @@ public final class Static251 {
@OriginalMember(owner = "client!ug", name = "b", descriptor = "[F")
public static final float[] aFloatArray28 = new float[4];
@OriginalMember(owner = "client!ug", name = "r", descriptor = "I")
public static int anInt5459 = 0;
@OriginalMember(owner = "client!ug", name = "a", descriptor = "(II)V")
public static void method4278(@OriginalArg(0) int arg0) {
if (Static241.anIntArray522 == null || Static241.anIntArray522.length < arg0) {

View file

@ -177,7 +177,7 @@ public final class Static254 {
@OriginalMember(owner = "client!uj", name = "a", descriptor = "(Lclient!wa;II)Lclient!na;")
public static JagString method4350(@OriginalArg(0) Buffer arg0) {
try {
@Pc(7) int local7 = arg0.gSmart1or2();
@Pc(7) int local7 = arg0.gsmarts();
if (local7 > 32767) {
local7 = 32767;
}

View file

@ -44,7 +44,7 @@ public final class Static26 {
local12 += local16;
@Pc(27) int local27 = 0;
while (true) {
@Pc(31) int local31 = local10.gSmart1or2();
@Pc(31) int local31 = local10.gsmarts();
if (local31 == 0) {
break;
}

View file

@ -51,7 +51,7 @@ public final class Static269 {
break;
}
for (local117 = 0; local117 < 4; local117++) {
@Pc(168) byte local168 = local95.g1s();
@Pc(168) byte local168 = local95.g1b();
if (local168 == 0) {
local243 = arg4;
if (arg4 < 0) {
@ -87,7 +87,7 @@ public final class Static269 {
} else if (local168 == 1) {
for (local243 = 0; local243 < 64; local243 += 4) {
for (local188 = 0; local188 < 64; local188 += 4) {
@Pc(305) byte local305 = local95.g1s();
@Pc(305) byte local305 = local95.g1b();
for (local194 = local243 + arg4; local194 < arg4 + local243 + 4; local194++) {
for (@Pc(320) int local320 = arg3 + local188; local320 < arg3 + local188 + 4; local320++) {
if (local194 >= 0 && local194 < 104 && local320 >= 0 && local320 < 104) {

View file

@ -31,13 +31,13 @@ public final class Static49 {
do {
@Pc(45) int local45;
while (local39) {
local45 = local22.gSmart1or2();
local45 = local22.gsmarts();
if (local45 == 0) {
continue label70;
}
local22.g1();
}
local45 = local22.gSmart1or2();
local45 = local22.gsmarts();
if (local45 == 0) {
continue label70;
}

View file

@ -24,7 +24,7 @@ public final class Static9 {
@OriginalMember(owner = "client!al", name = "a", descriptor = "(ILclient!wa;)Lclient!ci;")
public static TextureOp29SubOp1 method184(@OriginalArg(1) Buffer arg0) {
return new TextureOp29SubOp1(arg0.g2s(), arg0.g2s(), arg0.g2s(), arg0.g2s(), arg0.g3(), arg0.g1());
return new TextureOp29SubOp1(arg0.g2b(), arg0.g2b(), arg0.g2b(), arg0.g2b(), arg0.g3(), arg0.g1());
}
@OriginalMember(owner = "client!al", name = "b", descriptor = "(B)V")

View file

@ -31,7 +31,7 @@ public final class StockMarketOffer {
@OriginalMember(owner = "client!sg", name = "<init>", descriptor = "(Lclient!wa;)V")
public StockMarketOffer(@OriginalArg(0) Buffer arg0) {
this.aByte17 = arg0.g1s();
this.aByte17 = arg0.g1b();
this.item = arg0.g2();
this.price = arg0.g4();
this.count = arg0.g4();

View file

@ -305,16 +305,16 @@ public final class SynthInstrument {
this.aClass42_4.method1515(arg0);
}
for (@Pc(109) int local109 = 0; local109 < 10; local109++) {
@Pc(116) int local116 = arg0.gSmart1or2();
@Pc(116) int local116 = arg0.gsmarts();
if (local116 == 0) {
break;
}
this.anIntArray396[local109] = local116;
this.anIntArray404[local109] = arg0.gSmart1or2s();
this.anIntArray397[local109] = arg0.gSmart1or2();
this.anIntArray404[local109] = arg0.gsmart();
this.anIntArray397[local109] = arg0.gsmarts();
}
this.anInt4547 = arg0.gSmart1or2();
this.anInt4549 = arg0.gSmart1or2();
this.anInt4547 = arg0.gsmarts();
this.anInt4549 = arg0.gsmarts();
this.anInt4546 = arg0.g2();
this.anInt4548 = arg0.g2();
this.aClass110_1 = new SynthFilter();

View file

@ -44,11 +44,11 @@ public final class TextureOp13 extends TextureOp {
@Override
public final void method4629(@OriginalArg(0) int arg0, @OriginalArg(1) Buffer arg1) {
if (arg0 == 0) {
this.anInt2546 = arg1.g2s();
this.anInt2546 = arg1.g2b();
} else if (arg0 == 1) {
this.anInt2549 = (arg1.g1s() << 12) / 100;
this.anInt2549 = (arg1.g1b() << 12) / 100;
} else if (arg0 == 2) {
this.anInt2547 = (arg1.g1s() << 12) / 100;
this.anInt2547 = (arg1.g1b() << 12) / 100;
}
}

View file

@ -31,7 +31,7 @@ public final class TextureOp29SubOp2 extends TextureOp29SubOp {
@OriginalMember(owner = "client!kl", name = "a", descriptor = "(Lclient!wa;B)Lclient!kc;")
public static TextureOp29SubOp2 method2664(@OriginalArg(0) Buffer arg0) {
return new TextureOp29SubOp2(arg0.g2s(), arg0.g2s(), arg0.g2s(), arg0.g2s(), arg0.g3(), arg0.g3(), arg0.g1());
return new TextureOp29SubOp2(arg0.g2b(), arg0.g2b(), arg0.g2b(), arg0.g2b(), arg0.g3(), arg0.g3(), arg0.g1());
}
@OriginalMember(owner = "client!kc", name = "c", descriptor = "(III)V")

View file

@ -47,7 +47,7 @@ public final class TextureOp29SubOp3 extends TextureOp29SubOp {
@OriginalMember(owner = "client!bk", name = "a", descriptor = "(BLclient!wa;)Lclient!re;")
public static TextureOp29SubOp3 create(@OriginalArg(1) Buffer arg0) {
return new TextureOp29SubOp3(arg0.g2s(), arg0.g2s(), arg0.g2s(), arg0.g2s(), arg0.g2s(), arg0.g2s(), arg0.g2s(), arg0.g2s(), arg0.g3(), arg0.g1());
return new TextureOp29SubOp3(arg0.g2b(), arg0.g2b(), arg0.g2b(), arg0.g2b(), arg0.g2b(), arg0.g2b(), arg0.g2b(), arg0.g2b(), arg0.g3(), arg0.g1());
}
@OriginalMember(owner = "client!re", name = "a", descriptor = "(IZI)V")

View file

@ -164,11 +164,11 @@ public final class TextureOp4 extends TextureOp {
} else if (arg0 == 1) {
this.anInt642 = arg1.g1();
} else if (arg0 == 2) {
this.anInt648 = arg1.g2s();
this.anInt648 = arg1.g2b();
if (this.anInt648 < 0) {
this.aShortArray4 = new short[this.anInt642];
for (@Pc(93) int local93 = 0; local93 < this.anInt642; local93++) {
this.aShortArray4[local93] = (short) arg1.g2s();
this.aShortArray4[local93] = (short) arg1.g2b();
}
}
} else if (arg0 == 3) {

View file

@ -325,7 +325,7 @@ public final class VorbisSound extends Node {
local51 += local55;
} while (local55 >= 255);
@Pc(67) byte[] local67 = new byte[local51];
local4.gBytes(local51, local67);
local4.gdata(local51, local67);
this.aByteArrayArray10[local46] = local67;
}
}

View file

@ -19,7 +19,7 @@ public class WordPack {
public static int encode(@OriginalArg(1) Buffer arg0, @OriginalArg(2) JagString arg1) {
@Pc(6) int local6 = arg0.offset;
@Pc(14) byte[] local14 = arg1.method3148();
arg0.pSmart1or2(local14.length);
arg0.psmarts(local14.length);
arg0.offset += codec.method1550(local14.length, arg0.data, local14, 0, arg0.offset);
return arg0.offset - local6;
}

View file

@ -166,20 +166,20 @@ public class WorldList {
@OriginalMember(owner = "client!hi", name = "a", descriptor = "(Lclient!wa;I)V")
public static void decodeWorlds(@OriginalArg(0) Buffer buffer) {
@Pc(9) int countryCount = buffer.gSmart1or2();
@Pc(9) int countryCount = buffer.gsmarts();
countries = new WorldInfo[countryCount];
@Pc(14) int i;
for (i = 0; i < countryCount; i++) {
countries[i] = new WorldInfo();
countries[i].flag = buffer.gSmart1or2();
countries[i].flag = buffer.gsmarts();
countries[i].name = buffer.gjstr2();
}
minId = buffer.gSmart1or2();
maxId = buffer.gSmart1or2();
size = buffer.gSmart1or2();
minId = buffer.gsmarts();
maxId = buffer.gsmarts();
size = buffer.gsmarts();
worlds = new World[maxId + 1 - minId];
for (i = 0; i < size; i++) {
@Pc(77) int offset = buffer.gSmart1or2();
@Pc(77) int offset = buffer.gsmarts();
@Pc(85) World world = worlds[offset] = new World();
world.country = buffer.g1();
world.flags = buffer.g4();
@ -209,7 +209,7 @@ public class WorldList {
@OriginalMember(owner = "client!fh", name = "a", descriptor = "(Lclient!wa;I)V")
public static void decodePlayers(@OriginalArg(0) Buffer arg0) {
for (@Pc(7) int local7 = 0; local7 < size; local7++) {
@Pc(18) int local18 = arg0.gSmart1or2();
@Pc(18) int local18 = arg0.gsmarts();
@Pc(22) int local22 = arg0.g2();
if (local22 == 65535) {
local22 = -1;

View file

@ -290,7 +290,7 @@ public class WorldMap {
@Pc(112) byte[] underlay = underlays[local68 + local102];
for (local114 = 0; local114 < 64; local114++) {
if (!local35 || local102 >= local33 * 8 && local33 * 8 + 8 > local102 && local114 >= local31 * 8 && local114 < local31 * 8 + 8) {
underlay[local78 - local114] = data.g1s();
underlay[local78 - local114] = data.g1b();
}
}
}
@ -413,13 +413,13 @@ public class WorldMap {
}
for (@Pc(104) int local104 = 0; local104 < 64; local104++) {
if (!local24 || local97 >= local22 * 8 && local97 < local22 * 8 + 8 && local104 >= local26 * 8 && local104 < local26 * 8 + 8) {
local147 = arg0.g1s();
local147 = arg0.g1b();
if (local147 != 0) {
if (aByteArrayArrayArray3[local91][local95] == null) {
aByteArrayArrayArray3[local91][local95] = new byte[4096];
}
aByteArrayArrayArray3[local91][local95][local97 + (63 - local104 << 6)] = local147;
@Pc(186) byte local186 = arg0.g1s();
@Pc(186) byte local186 = arg0.g1b();
if (aByteArrayArrayArray8[local91][local95] == null) {
aByteArrayArrayArray8[local91][local95] = new byte[4096];
}
@ -435,7 +435,7 @@ public class WorldMap {
if ((local24 ? 64 : 4096) <= local91) {
continue label87;
}
local147 = arg0.g1s();
local147 = arg0.g1b();
if (local147 != 0) {
arg0.offset++;
}
@ -474,13 +474,13 @@ public class WorldMap {
}
for (@Pc(107) int local107 = 0; local107 < 64; local107++) {
if (!local25 || local23 * 8 <= local102 && local23 * 8 + 8 > local102 && local107 >= local27 * 8 && local27 * 8 + 8 > local107) {
local146 = arg0.g1s();
local146 = arg0.g1b();
if (local146 != 0) {
if (aByteArrayArrayArray12[local96][local100] == null) {
aByteArrayArrayArray12[local96][local100] = new byte[4096];
}
aByteArrayArrayArray12[local96][local100][(63 - local107 << 6) + local102] = local146;
@Pc(182) byte local182 = arg0.g1s();
@Pc(182) byte local182 = arg0.g1b();
if (aByteArrayArrayArray10[local96][local100] == null) {
aByteArrayArrayArray10[local96][local100] = new byte[4096];
}
@ -496,7 +496,7 @@ public class WorldMap {
if (local96 >= (local25 ? 64 : 4096)) {
continue label83;
}
local146 = arg0.g1s();
local146 = arg0.g1b();
if (local146 != 0) {
arg0.offset++;
}

View file

@ -458,7 +458,7 @@ public final class client extends GameShell {
}
}
}
arg0.pBytes(local15, 24);
arg0.pdata(local15, 24);
}
@OriginalMember(owner = "client!lb", name = "a", descriptor = "(Z)V")