runescape-client: fix the thing

This commit is contained in:
ThatGamerBlue
2020-12-11 06:14:29 +00:00
parent f74baf08ce
commit 463bc42f5f
325 changed files with 35526 additions and 35531 deletions

View File

@@ -54,11 +54,11 @@ public class WorldMapIcon_1 extends AbstractWorldMapIcon {
descriptor = "(Lhs;Lhs;ILam;)V"
)
WorldMapIcon_1(Coord var1, Coord var2, int var3, WorldMapRegion var4) {
super(var1, var2);
this.objectDefId = var3;
this.region = var4;
this.init();
}
super(var1, var2); // L: 17
this.objectDefId = var3; // L: 18
this.region = var4; // L: 19
this.init(); // L: 20
} // L: 21
@ObfuscatedName("h")
@ObfuscatedSignature(
@@ -67,7 +67,7 @@ public class WorldMapIcon_1 extends AbstractWorldMapIcon {
)
@Export("getElement")
public int getElement() {
return this.element;
return this.element; // L: 39
}
@ObfuscatedName("v")
@@ -77,7 +77,7 @@ public class WorldMapIcon_1 extends AbstractWorldMapIcon {
)
@Export("getLabel")
WorldMapLabel getLabel() {
return this.label;
return this.label; // L: 43
}
@ObfuscatedName("x")
@@ -87,7 +87,7 @@ public class WorldMapIcon_1 extends AbstractWorldMapIcon {
)
@Export("getSubWidth")
int getSubWidth() {
return this.subWidth;
return this.subWidth; // L: 47
}
@ObfuscatedName("w")
@@ -97,7 +97,7 @@ public class WorldMapIcon_1 extends AbstractWorldMapIcon {
)
@Export("getSubHeight")
int getSubHeight() {
return this.subHeight;
return this.subHeight; // L: 51
}
@ObfuscatedName("f")
@@ -107,19 +107,19 @@ public class WorldMapIcon_1 extends AbstractWorldMapIcon {
)
@Export("init")
void init() {
this.element = WorldMapDecoration.getObjectDefinition(this.objectDefId).transform().mapIconId;
this.label = this.region.createMapLabel(UserComparator10.WorldMapElement_get(this.element));
WorldMapElement var1 = UserComparator10.WorldMapElement_get(this.getElement());
Sprite var2 = var1.getSpriteBool(false);
if (var2 != null) {
this.subWidth = var2.subWidth;
this.subHeight = var2.subHeight;
this.element = WorldMapDecoration.getObjectDefinition(this.objectDefId).transform().mapIconId; // L: 24
this.label = this.region.createMapLabel(UserComparator10.WorldMapElement_get(this.element)); // L: 25
WorldMapElement var1 = UserComparator10.WorldMapElement_get(this.getElement()); // L: 26
Sprite var2 = var1.getSpriteBool(false); // L: 27
if (var2 != null) { // L: 28
this.subWidth = var2.subWidth; // L: 29
this.subHeight = var2.subHeight; // L: 30
} else {
this.subWidth = 0;
this.subHeight = 0;
this.subWidth = 0; // L: 33
this.subHeight = 0; // L: 34
}
}
} // L: 36
@ObfuscatedName("h")
@ObfuscatedSignature(
@@ -127,7 +127,7 @@ public class WorldMapIcon_1 extends AbstractWorldMapIcon {
garbageValue = "14"
)
static void method354() {
if (TaskHandler.javaVendor.toLowerCase().indexOf("microsoft") != -1) {
if (TaskHandler.javaVendor.toLowerCase().indexOf("microsoft") != -1) { // L: 119
KeyHandler.KeyHandler_keyCodes[186] = 57;
KeyHandler.KeyHandler_keyCodes[187] = 27;
KeyHandler.KeyHandler_keyCodes[188] = 71;
@@ -135,27 +135,27 @@ public class WorldMapIcon_1 extends AbstractWorldMapIcon {
KeyHandler.KeyHandler_keyCodes[190] = 72;
KeyHandler.KeyHandler_keyCodes[191] = 73;
KeyHandler.KeyHandler_keyCodes[192] = 58;
KeyHandler.KeyHandler_keyCodes[219] = 42;
KeyHandler.KeyHandler_keyCodes[219] = 42; // L: 127
KeyHandler.KeyHandler_keyCodes[220] = 74;
KeyHandler.KeyHandler_keyCodes[221] = 43;
KeyHandler.KeyHandler_keyCodes[222] = 59;
KeyHandler.KeyHandler_keyCodes[223] = 28;
KeyHandler.KeyHandler_keyCodes[221] = 43; // L: 129
KeyHandler.KeyHandler_keyCodes[222] = 59; // L: 130
KeyHandler.KeyHandler_keyCodes[223] = 28; // L: 131
} else {
KeyHandler.KeyHandler_keyCodes[44] = 71;
KeyHandler.KeyHandler_keyCodes[45] = 26;
KeyHandler.KeyHandler_keyCodes[46] = 72;
KeyHandler.KeyHandler_keyCodes[47] = 73;
KeyHandler.KeyHandler_keyCodes[59] = 57;
KeyHandler.KeyHandler_keyCodes[61] = 27;
KeyHandler.KeyHandler_keyCodes[91] = 42;
KeyHandler.KeyHandler_keyCodes[92] = 74;
KeyHandler.KeyHandler_keyCodes[93] = 43;
KeyHandler.KeyHandler_keyCodes[192] = 28;
KeyHandler.KeyHandler_keyCodes[222] = 58;
KeyHandler.KeyHandler_keyCodes[520] = 59;
KeyHandler.KeyHandler_keyCodes[44] = 71; // L: 134
KeyHandler.KeyHandler_keyCodes[45] = 26; // L: 135
KeyHandler.KeyHandler_keyCodes[46] = 72; // L: 136
KeyHandler.KeyHandler_keyCodes[47] = 73; // L: 137
KeyHandler.KeyHandler_keyCodes[59] = 57; // L: 138
KeyHandler.KeyHandler_keyCodes[61] = 27; // L: 139
KeyHandler.KeyHandler_keyCodes[91] = 42; // L: 140
KeyHandler.KeyHandler_keyCodes[92] = 74; // L: 141
KeyHandler.KeyHandler_keyCodes[93] = 43; // L: 142
KeyHandler.KeyHandler_keyCodes[192] = 28; // L: 143
KeyHandler.KeyHandler_keyCodes[222] = 58; // L: 144
KeyHandler.KeyHandler_keyCodes[520] = 59; // L: 145
}
}
} // L: 147
@ObfuscatedName("p")
@ObfuscatedSignature(
@@ -164,39 +164,39 @@ public class WorldMapIcon_1 extends AbstractWorldMapIcon {
)
public static boolean method355() {
try {
if (class206.musicPlayerStatus == 2) {
if (FileSystem.musicTrack == null) {
FileSystem.musicTrack = MusicTrack.readTrack(Varps.musicTrackArchive, HealthBarUpdate.musicTrackGroupId, class206.musicTrackFileId);
if (FileSystem.musicTrack == null) {
if (class206.musicPlayerStatus == 2) { // L: 102
if (FileSystem.musicTrack == null) { // L: 103
FileSystem.musicTrack = MusicTrack.readTrack(Varps.musicTrackArchive, HealthBarUpdate.musicTrackGroupId, class206.musicTrackFileId); // L: 104
if (FileSystem.musicTrack == null) { // L: 105
return false;
}
}
if (class206.soundCache == null) {
if (class206.soundCache == null) { // L: 107
class206.soundCache = new SoundCache(class206.soundEffectsArchive, class206.musicSamplesArchive);
}
if (class206.midiPcmStream.loadMusicTrack(FileSystem.musicTrack, class206.musicPatchesArchive, class206.soundCache, 22050)) {
class206.midiPcmStream.clearAll();
class206.midiPcmStream.setPcmStreamVolume(GrandExchangeEvent.musicTrackVolume);
class206.midiPcmStream.setMusicTrack(FileSystem.musicTrack, class231.musicTrackBoolean);
class206.musicPlayerStatus = 0;
FileSystem.musicTrack = null;
class206.soundCache = null;
Varps.musicTrackArchive = null;
return true;
if (class206.midiPcmStream.loadMusicTrack(FileSystem.musicTrack, class206.musicPatchesArchive, class206.soundCache, 22050)) { // L: 108
class206.midiPcmStream.clearAll(); // L: 109
class206.midiPcmStream.setPcmStreamVolume(GrandExchangeEvent.musicTrackVolume); // L: 110
class206.midiPcmStream.setMusicTrack(FileSystem.musicTrack, class231.musicTrackBoolean); // L: 111
class206.musicPlayerStatus = 0; // L: 112
FileSystem.musicTrack = null; // L: 113
class206.soundCache = null; // L: 114
Varps.musicTrackArchive = null; // L: 115
return true; // L: 116
}
}
} catch (Exception var1) {
var1.printStackTrace();
class206.midiPcmStream.clear();
class206.musicPlayerStatus = 0;
FileSystem.musicTrack = null;
class206.soundCache = null;
Varps.musicTrackArchive = null;
} catch (Exception var1) { // L: 120
var1.printStackTrace(); // L: 121
class206.midiPcmStream.clear(); // L: 122
class206.musicPlayerStatus = 0; // L: 123
FileSystem.musicTrack = null; // L: 124
class206.soundCache = null; // L: 125
Varps.musicTrackArchive = null; // L: 126
}
return false;
return false; // L: 128
}
@ObfuscatedName("e")
@@ -205,9 +205,9 @@ public class WorldMapIcon_1 extends AbstractWorldMapIcon {
garbageValue = "620552386"
)
public static void method339() {
NPCDefinition.NpcDefinition_cached.clear();
NPCDefinition.NpcDefinition_cachedModels.clear();
}
NPCDefinition.NpcDefinition_cached.clear(); // L: 285
NPCDefinition.NpcDefinition_cachedModels.clear(); // L: 286
} // L: 287
@ObfuscatedName("q")
@ObfuscatedSignature(
@@ -215,54 +215,54 @@ public class WorldMapIcon_1 extends AbstractWorldMapIcon {
garbageValue = "1021880804"
)
static int method336(int var0, Script var1, boolean var2) {
Widget var3 = CollisionMap.getWidget(Interpreter.Interpreter_intStack[--VarcInt.Interpreter_intStackSize]);
if (var0 == ScriptOpcodes.IF_GETSCROLLX) {
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.scrollX;
return 1;
} else if (var0 == ScriptOpcodes.IF_GETSCROLLY) {
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.scrollY;
return 1;
} else if (var0 == ScriptOpcodes.IF_GETTEXT) {
Interpreter.Interpreter_stringStack[++Interpreter.Interpreter_stringStackSize - 1] = var3.text;
return 1;
} else if (var0 == ScriptOpcodes.IF_GETSCROLLWIDTH) {
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.scrollWidth;
return 1;
} else if (var0 == ScriptOpcodes.IF_GETSCROLLHEIGHT) {
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.scrollHeight;
return 1;
} else if (var0 == ScriptOpcodes.IF_GETMODELZOOM) {
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.modelZoom;
return 1;
} else if (var0 == ScriptOpcodes.IF_GETMODELANGLE_X) {
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.modelAngleX;
return 1;
} else if (var0 == ScriptOpcodes.IF_GETMODELANGLE_Z) {
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.modelAngleZ;
return 1;
} else if (var0 == ScriptOpcodes.IF_GETMODELANGLE_Y) {
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.modelAngleY;
return 1;
} else if (var0 == ScriptOpcodes.IF_GETTRANSTOP) {
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.transparencyTop;
return 1;
} else if (var0 == ScriptOpcodes.IF_GETTRANSBOT) {
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.transparencyBot;
return 1;
} else if (var0 == ScriptOpcodes.IF_GETCOLOUR) {
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.color;
return 1;
} else if (var0 == ScriptOpcodes.IF_GETFILLCOLOUR) {
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.color2;
return 1;
} else if (var0 == ScriptOpcodes.IF_GETFILLMODE) {
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.fillMode.rsOrdinal();
return 1;
} else if (var0 == ScriptOpcodes.IF_GETMODELTRANSPARENT) {
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.modelTransparency ? 1 : 0;
return 1;
Widget var3 = CollisionMap.getWidget(Interpreter.Interpreter_intStack[--VarcInt.Interpreter_intStackSize]); // L: 1215
if (var0 == ScriptOpcodes.IF_GETSCROLLX) { // L: 1216
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.scrollX; // L: 1217
return 1; // L: 1218
} else if (var0 == ScriptOpcodes.IF_GETSCROLLY) { // L: 1220
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.scrollY; // L: 1221
return 1; // L: 1222
} else if (var0 == ScriptOpcodes.IF_GETTEXT) { // L: 1224
Interpreter.Interpreter_stringStack[++Interpreter.Interpreter_stringStackSize - 1] = var3.text; // L: 1225
return 1; // L: 1226
} else if (var0 == ScriptOpcodes.IF_GETSCROLLWIDTH) { // L: 1228
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.scrollWidth; // L: 1229
return 1; // L: 1230
} else if (var0 == ScriptOpcodes.IF_GETSCROLLHEIGHT) { // L: 1232
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.scrollHeight; // L: 1233
return 1; // L: 1234
} else if (var0 == ScriptOpcodes.IF_GETMODELZOOM) { // L: 1236
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.modelZoom; // L: 1237
return 1; // L: 1238
} else if (var0 == ScriptOpcodes.IF_GETMODELANGLE_X) { // L: 1240
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.modelAngleX; // L: 1241
return 1; // L: 1242
} else if (var0 == ScriptOpcodes.IF_GETMODELANGLE_Z) { // L: 1244
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.modelAngleZ; // L: 1245
return 1; // L: 1246
} else if (var0 == ScriptOpcodes.IF_GETMODELANGLE_Y) { // L: 1248
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.modelAngleY; // L: 1249
return 1; // L: 1250
} else if (var0 == ScriptOpcodes.IF_GETTRANSTOP) { // L: 1252
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.transparencyTop; // L: 1253
return 1; // L: 1254
} else if (var0 == ScriptOpcodes.IF_GETTRANSBOT) { // L: 1256
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.transparencyBot; // L: 1257
return 1; // L: 1258
} else if (var0 == ScriptOpcodes.IF_GETCOLOUR) { // L: 1260
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.color; // L: 1261
return 1; // L: 1262
} else if (var0 == ScriptOpcodes.IF_GETFILLCOLOUR) { // L: 1264
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.color2; // L: 1265
return 1; // L: 1266
} else if (var0 == ScriptOpcodes.IF_GETFILLMODE) { // L: 1268
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.fillMode.rsOrdinal(); // L: 1269
return 1; // L: 1270
} else if (var0 == ScriptOpcodes.IF_GETMODELTRANSPARENT) { // L: 1272
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var3.modelTransparency ? 1 : 0; // L: 1273
return 1; // L: 1274
} else {
return 2;
return 2; // L: 1276
}
}
@@ -273,34 +273,34 @@ public class WorldMapIcon_1 extends AbstractWorldMapIcon {
)
static int method345(int var0, Script var1, boolean var2) {
Widget var5;
if (var0 == ScriptOpcodes.IF_GETINVOBJECT) {
var5 = CollisionMap.getWidget(Interpreter.Interpreter_intStack[--VarcInt.Interpreter_intStackSize]);
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var5.itemId;
return 1;
} else if (var0 == ScriptOpcodes.IF_GETINVCOUNT) {
var5 = CollisionMap.getWidget(Interpreter.Interpreter_intStack[--VarcInt.Interpreter_intStackSize]);
if (var5.itemId != -1) {
if (var0 == ScriptOpcodes.IF_GETINVOBJECT) { // L: 1280
var5 = CollisionMap.getWidget(Interpreter.Interpreter_intStack[--VarcInt.Interpreter_intStackSize]); // L: 1281
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var5.itemId; // L: 1282
return 1; // L: 1283
} else if (var0 == ScriptOpcodes.IF_GETINVCOUNT) { // L: 1285
var5 = CollisionMap.getWidget(Interpreter.Interpreter_intStack[--VarcInt.Interpreter_intStackSize]); // L: 1286
if (var5.itemId != -1) { // L: 1287
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = var5.itemQuantity;
} else {
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = 0;
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = 0; // L: 1288
}
return 1;
} else if (var0 == ScriptOpcodes.IF_HASSUB) {
int var3 = Interpreter.Interpreter_intStack[--VarcInt.Interpreter_intStackSize];
InterfaceParent var4 = (InterfaceParent)Client.interfaceParents.get((long)var3);
if (var4 != null) {
return 1; // L: 1289
} else if (var0 == ScriptOpcodes.IF_HASSUB) { // L: 1291
int var3 = Interpreter.Interpreter_intStack[--VarcInt.Interpreter_intStackSize]; // L: 1292
InterfaceParent var4 = (InterfaceParent)Client.interfaceParents.get((long)var3); // L: 1293
if (var4 != null) { // L: 1294
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = 1;
} else {
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = 0;
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = 0; // L: 1295
}
return 1;
} else if (var0 == ScriptOpcodes.IF_GETTOP) {
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = Client.rootInterface;
return 1;
return 1; // L: 1296
} else if (var0 == ScriptOpcodes.IF_GETTOP) { // L: 1298
Interpreter.Interpreter_intStack[++VarcInt.Interpreter_intStackSize - 1] = Client.rootInterface; // L: 1299
return 1; // L: 1300
} else {
return 2;
return 2; // L: 1302
}
}
}