Skip to content

Commit

Permalink
runescape-client: export rsOrdinal
Browse files Browse the repository at this point in the history
  • Loading branch information
Adam- committed May 10, 2018
1 parent 73c5dc3 commit 15f8c75
Show file tree
Hide file tree
Showing 17 changed files with 28 additions and 26 deletions.
2 changes: 1 addition & 1 deletion runescape-client/src/main/java/AttackOption.java
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public enum AttackOption implements Enumerated {
signature = "(B)I",
garbageValue = "60"
)
public int vmethod5860() {
public int rsOrdinal() {
return this.id;
}

Expand Down
2 changes: 1 addition & 1 deletion runescape-client/src/main/java/Client.java
Original file line number Diff line number Diff line change
Expand Up @@ -2956,7 +2956,7 @@ final void method1201() {
int[] var12 = new int[]{(int)(Math.random() * 9.9999999E7D), (int)(Math.random() * 9.9999999E7D), (int)(class165.field2065 >> 32), (int)(class165.field2065 & -1L)};
var17.offset = 0;
var17.putByte(1);
var17.putByte(field716.vmethod5860());
var17.putByte(field716.rsOrdinal());
var17.putInt(var12[0]);
var17.putInt(var12[1]);
var17.putInt(var12[2]);
Expand Down
4 changes: 3 additions & 1 deletion runescape-client/src/main/java/Enumerated.java
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import net.runelite.mapping.Export;
import net.runelite.mapping.Implements;
import net.runelite.mapping.ObfuscatedName;
import net.runelite.mapping.ObfuscatedSignature;
Expand All @@ -10,5 +11,6 @@ public interface Enumerated {
signature = "(B)I",
garbageValue = "60"
)
int vmethod5860();
@Export("rsOrdinal")
int rsOrdinal();
}
2 changes: 1 addition & 1 deletion runescape-client/src/main/java/HorizontalAlignment.java
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public enum HorizontalAlignment implements Enumerated {
signature = "(B)I",
garbageValue = "60"
)
public int vmethod5860() {
public int rsOrdinal() {
return this.field3497;
}
}
2 changes: 1 addition & 1 deletion runescape-client/src/main/java/JagexGame.java
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public enum JagexGame implements Enumerated {
signature = "(B)I",
garbageValue = "60"
)
public int vmethod5860() {
public int rsOrdinal() {
return this.id;
}

Expand Down
2 changes: 1 addition & 1 deletion runescape-client/src/main/java/Permission.java
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ public enum Permission implements Enumerated {
signature = "(B)I",
garbageValue = "60"
)
public int vmethod5860() {
public int rsOrdinal() {
return this.field3141;
}
}
2 changes: 1 addition & 1 deletion runescape-client/src/main/java/VerticalAlignment.java
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public enum VerticalAlignment implements Enumerated {
signature = "(B)I",
garbageValue = "60"
)
public int vmethod5860() {
public int rsOrdinal() {
return this.field3245;
}
}
2 changes: 1 addition & 1 deletion runescape-client/src/main/java/WorldMapDecorationType.java
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ public enum WorldMapDecorationType implements Enumerated {
signature = "(B)I",
garbageValue = "60"
)
public int vmethod5860() {
public int rsOrdinal() {
return this.rsOrdinal;
}
}
18 changes: 9 additions & 9 deletions runescape-client/src/main/java/WorldMapManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -268,18 +268,18 @@ void method524(int var1, int var2, WorldMapRegion[] var3) {
boolean var6 = var2 <= 0;
boolean var7 = var2 >= this.mapRegions[0].length - 1;
if(var7) {
var3[class240.field3128.vmethod5860()] = null;
var3[class240.field3128.rsOrdinal()] = null;
} else {
var3[class240.field3128.vmethod5860()] = this.mapRegions[var1][var2 + 1];
var3[class240.field3128.rsOrdinal()] = this.mapRegions[var1][var2 + 1];
}

var3[class240.field3121.vmethod5860()] = !var7 && !var5?this.mapRegions[var1 + 1][var2 + 1]:null;
var3[class240.field3120.vmethod5860()] = !var7 && !var4?this.mapRegions[var1 - 1][var2 + 1]:null;
var3[class240.field3125.vmethod5860()] = var5?null:this.mapRegions[var1 + 1][var2];
var3[class240.field3127.vmethod5860()] = var4?null:this.mapRegions[var1 - 1][var2];
var3[class240.field3124.vmethod5860()] = var6?null:this.mapRegions[var1][var2 - 1];
var3[class240.field3123.vmethod5860()] = !var6 && !var5?this.mapRegions[var1 + 1][var2 - 1]:null;
var3[class240.field3122.vmethod5860()] = !var6 && !var4?this.mapRegions[var1 - 1][var2 - 1]:null;
var3[class240.field3121.rsOrdinal()] = !var7 && !var5?this.mapRegions[var1 + 1][var2 + 1]:null;
var3[class240.field3120.rsOrdinal()] = !var7 && !var4?this.mapRegions[var1 - 1][var2 + 1]:null;
var3[class240.field3125.rsOrdinal()] = var5?null:this.mapRegions[var1 + 1][var2];
var3[class240.field3127.rsOrdinal()] = var4?null:this.mapRegions[var1 - 1][var2];
var3[class240.field3124.rsOrdinal()] = var6?null:this.mapRegions[var1][var2 - 1];
var3[class240.field3123.rsOrdinal()] = !var6 && !var5?this.mapRegions[var1 + 1][var2 - 1]:null;
var3[class240.field3122.rsOrdinal()] = !var6 && !var4?this.mapRegions[var1 - 1][var2 - 1]:null;
}

@ObfuscatedName("a")
Expand Down
4 changes: 2 additions & 2 deletions runescape-client/src/main/java/WorldMapRegion.java
Original file line number Diff line number Diff line change
Expand Up @@ -420,7 +420,7 @@ void method322(WorldMapRegion[] var1, class32 var2) {

for(int var6 = 0; var6 < var5.length; ++var6) {
class240 var7 = var5[var6];
if(var1[var7.vmethod5860()] != null) {
if(var1[var7.rsOrdinal()] != null) {
byte var8 = 0;
byte var9 = 0;
byte var10 = 64;
Expand Down Expand Up @@ -469,7 +469,7 @@ void method322(WorldMapRegion[] var1, class32 var2) {
var10 = 5;
}

this.method326(var12, var13, var8, var9, var10, var11, var1[var7.vmethod5860()], var2);
this.method326(var12, var13, var8, var9, var10, var11, var1[var7.rsOrdinal()], var2);
}
}

Expand Down
2 changes: 1 addition & 1 deletion runescape-client/src/main/java/class146.java
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public enum class146 implements Enumerated {
signature = "(B)I",
garbageValue = "60"
)
public int vmethod5860() {
public int rsOrdinal() {
return this.field1931;
}
}
2 changes: 1 addition & 1 deletion runescape-client/src/main/java/class15.java
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public enum class15 implements Enumerated {
signature = "(B)I",
garbageValue = "60"
)
public int vmethod5860() {
public int rsOrdinal() {
return this.field127;
}

Expand Down
2 changes: 1 addition & 1 deletion runescape-client/src/main/java/class240.java
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public enum class240 implements Enumerated {
signature = "(B)I",
garbageValue = "60"
)
public int vmethod5860() {
public int rsOrdinal() {
return this.field3129;
}

Expand Down
2 changes: 1 addition & 1 deletion runescape-client/src/main/java/class316.java
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public enum class316 implements Enumerated {
signature = "(B)I",
garbageValue = "60"
)
public int vmethod5860() {
public int rsOrdinal() {
return this.field3783;
}
}
2 changes: 1 addition & 1 deletion runescape-client/src/main/java/class32.java
Original file line number Diff line number Diff line change
Expand Up @@ -507,7 +507,7 @@ static int method600(int var0, Script var1, boolean var2) {
class69.intStack[++class45.intStackSize - 1] = var3.field2640;
return 1;
} else if(var0 == 2613) {
class69.intStack[++class45.intStackSize - 1] = var3.field2700.vmethod5860();
class69.intStack[++class45.intStackSize - 1] = var3.field2700.rsOrdinal();
return 1;
} else if(var0 == 2614) {
class69.intStack[++class45.intStackSize - 1] = var3.field2679?1:0;
Expand Down
2 changes: 1 addition & 1 deletion runescape-client/src/main/java/class52.java
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ static int method1066(int var0, Script var1, boolean var2) {
class69.intStack[++class45.intStackSize - 1] = var3.field2640;
return 1;
} else if(var0 == 1613) {
class69.intStack[++class45.intStackSize - 1] = var3.field2700.vmethod5860();
class69.intStack[++class45.intStackSize - 1] = var3.field2700.rsOrdinal();
return 1;
} else if(var0 == 1614) {
class69.intStack[++class45.intStackSize - 1] = var3.field2679?1:0;
Expand Down
2 changes: 1 addition & 1 deletion runescape-client/src/main/java/class7.java
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ public static Enumerated forOrdinal(Enumerated[] var0, int var1) {

for(int var3 = 0; var3 < var2.length; ++var3) {
Enumerated var4 = var2[var3];
if(var1 == var4.vmethod5860()) {
if(var1 == var4.rsOrdinal()) {
return var4;
}
}
Expand Down

0 comments on commit 15f8c75

Please sign in to comment.