Undo class refactor changes

This commit is contained in:
Jonatino
2021-03-25 18:24:59 -04:00
parent 257103dbcd
commit 284b5bea32
18 changed files with 34 additions and 47 deletions

View File

@@ -1,3 +0,0 @@
package net.runelite.rs.api;
public interface RSFrameLoader {}

View File

@@ -1,3 +0,0 @@
package net.runelite.rs.api;
public interface RSFrameProvider {}

View File

@@ -1,3 +0,0 @@
package net.runelite.rs.api;
public interface RSMinimapRenderer {}

View File

@@ -1188,23 +1188,23 @@ public abstract class AbstractWorldMapIcon {
if (var3 == 4) { // L: 11146
if (var2 == 0) { // L: 11147
FrameProvider.updateSoundEffectVolume(127);
class171.updateSoundEffectVolume(127);
}
if (var2 == 1) { // L: 11148
FrameProvider.updateSoundEffectVolume(96);
class171.updateSoundEffectVolume(96);
}
if (var2 == 2) { // L: 11149
FrameProvider.updateSoundEffectVolume(64);
class171.updateSoundEffectVolume(64);
}
if (var2 == 3) { // L: 11150
FrameProvider.updateSoundEffectVolume(32);
class171.updateSoundEffectVolume(32);
}
if (var2 == 4) { // L: 11151
FrameProvider.updateSoundEffectVolume(0);
class171.updateSoundEffectVolume(0);
}
}

View File

@@ -121,7 +121,7 @@ public class ApproximateRouteStrategy extends RouteStrategy {
return 1; // L: 1758
} else if (var0 == 3205) { // L: 1760
var3 = Math.min(Math.max(Interpreter.Interpreter_intStack[--Interpreter.Interpreter_intStackSize], 0), 100); // L: 1761
FrameProvider.updateSoundEffectVolume(Math.round(1.27F * (float)var3)); // L: 1762
class171.updateSoundEffectVolume(Math.round(1.27F * (float)var3)); // L: 1762
return 1; // L: 1763
} else if (var0 == 3206) { // L: 1765
Interpreter.Interpreter_intStack[++Interpreter.Interpreter_intStackSize - 1] = Math.round((float)WorldMapSectionType.clientPreferences.soundEffectsVolume / 1.27F); // L: 1766

View File

@@ -162,7 +162,7 @@ public class ChatChannel {
Client.worldId = var0.id; // L: 1556
Client.worldProperties = var0.properties; // L: 1557
MouseRecorder.worldPort = Client.gameBuild == 0 ? 43594 : var0.id + 40000; // L: 1558
FrameProvider.js5Port = Client.gameBuild == 0 ? 443 : var0.id + 50000; // L: 1559
class171.js5Port = Client.gameBuild == 0 ? 443 : var0.id + 50000; // L: 1559
DynamicObject.currentPort = MouseRecorder.worldPort; // L: 1560
} // L: 1561
}

View File

@@ -1567,12 +1567,12 @@ public final class Client extends GameEngine implements Usernamed {
protected final void setUp() {
Strings.method4329(new int[]{20, 260, 10000}, new int[]{1000, 100, 500}); // L: 791
MouseRecorder.worldPort = gameBuild == 0 ? 43594 : worldId + 40000; // L: 792
FrameProvider.js5Port = gameBuild == 0 ? 443 : worldId + 50000; // L: 793
class171.js5Port = gameBuild == 0 ? 443 : worldId + 50000; // L: 793
DynamicObject.currentPort = MouseRecorder.worldPort; // L: 794
PlayerComposition.field2565 = MinimapRenderer.field2577; // L: 795
class105.field1339 = MinimapRenderer.field2573; // L: 796
HealthBar.field1143 = MinimapRenderer.field2575; // L: 797
WorldMapSprite.field259 = MinimapRenderer.field2574; // L: 798
PlayerComposition.field2565 = class224.field2577; // L: 795
class105.field1339 = class224.field2573; // L: 796
HealthBar.field1143 = class224.field2575; // L: 797
WorldMapSprite.field259 = class224.field2574; // L: 798
ScriptFrame.urlRequester = new UrlRequester(); // L: 799
this.setUpKeyboard(); // L: 800
this.setUpMouse(); // L: 801
@@ -2402,7 +2402,7 @@ public final class Client extends GameEngine implements Usernamed {
WorldMapArea.js5Socket = null; // L: 1357
js5ConnectState = 0; // L: 1358
if (DynamicObject.currentPort == MouseRecorder.worldPort) { // L: 1359
DynamicObject.currentPort = FrameProvider.js5Port;
DynamicObject.currentPort = class171.js5Port;
} else {
DynamicObject.currentPort = MouseRecorder.worldPort; // L: 1360
}
@@ -2909,7 +2909,7 @@ public final class Client extends GameEngine implements Usernamed {
if (field696 > 2000) { // L: 2396
if (field786 < 1) { // L: 2397
if (MouseRecorder.worldPort == DynamicObject.currentPort) { // L: 2398
DynamicObject.currentPort = FrameProvider.js5Port;
DynamicObject.currentPort = class171.js5Port;
} else {
DynamicObject.currentPort = MouseRecorder.worldPort; // L: 2399
}
@@ -3071,7 +3071,7 @@ public final class Client extends GameEngine implements Usernamed {
} catch (IOException var22) { // L: 2408
if (field786 < 1) { // L: 2409
if (MouseRecorder.worldPort == DynamicObject.currentPort) { // L: 2410
DynamicObject.currentPort = FrameProvider.js5Port;
DynamicObject.currentPort = class171.js5Port;
} else {
DynamicObject.currentPort = MouseRecorder.worldPort; // L: 2411
}
@@ -3358,7 +3358,7 @@ public final class Client extends GameEngine implements Usernamed {
var2 = npcIndices[var1]; // L: 2873
NPC var23 = npcs[var2]; // L: 2874
if (var23 != null) { // L: 2875
FrameProvider.updateActorSequence(var23, var23.definition.size); // L: 2876
class171.updateActorSequence(var23, var23.definition.size); // L: 2876
}
}

View File

@@ -192,7 +192,7 @@ public class ClientPreferences {
if (var1 != null) { // L: 188
return var1;
} else {
var1 = FrameProvider.loadFrames(SequenceDefinition.SequenceDefinition_animationsArchive, SequenceDefinition.SequenceDefinition_skeletonsArchive, var0, false); // L: 189
var1 = class171.loadFrames(SequenceDefinition.SequenceDefinition_animationsArchive, SequenceDefinition.SequenceDefinition_skeletonsArchive, var0, false); // L: 189
if (var1 != null) { // L: 190
SequenceDefinition.SequenceDefinition_cachedFrames.put(var1, (long)var0);
}

View File

@@ -1,7 +0,0 @@
import net.runelite.mapping.Implements;
import net.runelite.mapping.ObfuscatedName;
@ObfuscatedName("ff")
@Implements("FrameLoader")
public interface FrameLoader {
}

View File

@@ -182,7 +182,7 @@ public class Login {
worldSelectPage = 0; // L: 103
worldSelectPagesCount = 0; // L: 104
new DecimalFormat("##0.00"); // L: 107
new FrameProvider();
new class171();
field1213 = -1L; // L: 115
field1226 = -1L; // L: 116
}

View File

@@ -286,7 +286,7 @@ public final class Projectile extends Renderable {
JagexCache.userHomeDirectory = "~/";
}
MinimapRenderer.cacheParentPaths = new String[]{"c:/rscache/", "/rscache/", "c:/windows/", "c:/winnt/", "c:/", JagexCache.userHomeDirectory, "/tmp/", ""}; // L: 65
class224.cacheParentPaths = new String[]{"c:/rscache/", "/rscache/", "c:/windows/", "c:/winnt/", "c:/", JagexCache.userHomeDirectory, "/tmp/", ""}; // L: 65
Timer.cacheSubPaths = new String[]{".jagex_cache_" + JagexCache.cacheGamebuild, ".file_store_" + JagexCache.cacheGamebuild}; // L: 66
int var18 = 0;
@@ -357,8 +357,8 @@ public final class Projectile extends Renderable {
if (var7 == null && var18 == 0) { // L: 116
label225:
for (int var19 = 0; var19 < Timer.cacheSubPaths.length; ++var19) { // L: 117
for (int var20 = 0; var20 < MinimapRenderer.cacheParentPaths.length; ++var20) { // L: 118
File var21 = new File(MinimapRenderer.cacheParentPaths[var20] + Timer.cacheSubPaths[var19] + File.separatorChar + var0 + File.separatorChar); // L: 119
for (int var20 = 0; var20 < class224.cacheParentPaths.length; ++var20) { // L: 118
File var21 = new File(class224.cacheParentPaths[var20] + Timer.cacheSubPaths[var19] + File.separatorChar + var0 + File.separatorChar); // L: 119
if (var21.exists() && class23.isWriteable(new File(var21, "test.dat"), true)) { // L: 120 121
var7 = var21.toString(); // L: 122
var9 = true; // L: 123

View File

@@ -47,7 +47,7 @@ public abstract class Renderable extends DualNode {
static final void method3417() {
if (Client.field889 != class90.Client_plane) { // L: 3402
Client.field889 = class90.Client_plane; // L: 3403
MinimapRenderer.redrawMiniMapIcons(class90.Client_plane); // L: 3404
class224.redrawMiniMapIcons(class90.Client_plane); // L: 3404
}
} // L: 3406

View File

@@ -408,8 +408,8 @@ public class Varcs {
} else {
label39:
for (int var1 = 0; var1 < Timer.cacheSubPaths.length; ++var1) { // L: 255
for (var2 = 0; var2 < MinimapRenderer.cacheParentPaths.length; ++var2) { // L: 256
File var3 = new File(MinimapRenderer.cacheParentPaths[var2] + Timer.cacheSubPaths[var1] + File.separatorChar + "random.dat"); // L: 257
for (var2 = 0; var2 < class224.cacheParentPaths.length; ++var2) { // L: 256
File var3 = new File(class224.cacheParentPaths[var2] + Timer.cacheSubPaths[var1] + File.separatorChar + "random.dat"); // L: 257
if (var3.exists()) { // L: 258
JagexCache.JagexCache_randomDat = new BufferedFile(new AccessFile(var3, "rw", 25L), 24, 0); // L: 259
break label39; // L: 260

View File

@@ -159,7 +159,7 @@ public final class WorldMapRectangle {
for (int var2 = 0; var2 < var0; ++var2) { // L: 3495
Player var3 = Client.players[var1[var2]]; // L: 3496
if (var3 != null) { // L: 3497
FrameProvider.updateActorSequence(var3, 1); // L: 3498
class171.updateActorSequence(var3, 1); // L: 3498
}
}

View File

@@ -71,7 +71,7 @@ public final class class13 {
if (!Client.isCameraLocked) { // L: 4014
var4 = AbstractWorldMapIcon.method712();
} else {
var4 = FrameProvider.method3639(); // L: 4015
var4 = class171.method3639(); // L: 4015
}
var28 = SecureRandomFuture.cameraX; // L: 4016

View File

@@ -0,0 +1,5 @@
import net.runelite.mapping.ObfuscatedName;
@ObfuscatedName("ff")
public interface class170 {
}

View File

@@ -1,12 +1,11 @@
import net.runelite.mapping.Export;
import net.runelite.mapping.Implements;
import net.runelite.mapping.ObfuscatedGetter;
import net.runelite.mapping.ObfuscatedName;
import net.runelite.mapping.ObfuscatedSignature;
@ObfuscatedName("fd")
@Implements("FrameProvider")
public class FrameProvider implements FrameLoader {
public class class171 implements class170
{
@ObfuscatedName("ee")
@ObfuscatedGetter(
intValue = -853566565

View File

@@ -4,8 +4,7 @@ import net.runelite.mapping.ObfuscatedName;
import net.runelite.mapping.ObfuscatedSignature;
@ObfuscatedName("hn")
@Implements("MinimapRenderer")
public class MinimapRenderer {
public class class224 {
@ObfuscatedName("n")
public static final short[] field2577;
@ObfuscatedName("v")