Replace opcode constants with ScriptOpcodes field refs in rsclient
This commit is contained in:
@@ -3,6 +3,7 @@ import net.runelite.mapping.Implements;
|
||||
import net.runelite.mapping.ObfuscatedGetter;
|
||||
import net.runelite.mapping.ObfuscatedName;
|
||||
import net.runelite.mapping.ObfuscatedSignature;
|
||||
import net.runelite.rs.ScriptOpcodes;
|
||||
|
||||
@ObfuscatedName("bh")
|
||||
@Implements("FriendSystem")
|
||||
@@ -129,13 +130,14 @@ public class FriendSystem {
|
||||
signature = "(Ljava/lang/String;I)V",
|
||||
garbageValue = "-1721017960"
|
||||
)
|
||||
final void method103(String var1) {
|
||||
@Export("addFriend")
|
||||
final void addFriend(String var1) {
|
||||
if (var1 != null) {
|
||||
Username var2 = new Username(var1, this.loginType);
|
||||
if (var2.hasCleanName()) {
|
||||
StringBuilder var3;
|
||||
String var4;
|
||||
if (this.method104()) {
|
||||
if (this.canAddFriend()) {
|
||||
var3 = null;
|
||||
var4 = "Your friend list is full. Max of 200 for free users, and 400 for members";
|
||||
WorldMapIcon1.method219(30, "", var4);
|
||||
@@ -174,7 +176,8 @@ public class FriendSystem {
|
||||
signature = "(B)Z",
|
||||
garbageValue = "57"
|
||||
)
|
||||
final boolean method104() {
|
||||
@Export("canAddFriend")
|
||||
final boolean canAddFriend() {
|
||||
return this.friendsList.isFull() || this.friendsList.size() >= 200 && Client.field209 != 1;
|
||||
}
|
||||
|
||||
@@ -183,13 +186,14 @@ public class FriendSystem {
|
||||
signature = "(Ljava/lang/String;B)V",
|
||||
garbageValue = "30"
|
||||
)
|
||||
final void method105(String var1) {
|
||||
@Export("addIgnore")
|
||||
final void addIgnore(String var1) {
|
||||
if (var1 != null) {
|
||||
Username var2 = new Username(var1, this.loginType);
|
||||
if (var2.hasCleanName()) {
|
||||
StringBuilder var3;
|
||||
String var4;
|
||||
if (this.method106()) {
|
||||
if (this.canAddIgnore()) {
|
||||
var3 = null;
|
||||
var4 = "Your ignore list is full. Max of 100 for free users, and 400 for members";
|
||||
WorldMapIcon1.method219(30, "", var4);
|
||||
@@ -225,7 +229,8 @@ public class FriendSystem {
|
||||
signature = "(B)Z",
|
||||
garbageValue = "120"
|
||||
)
|
||||
final boolean method106() {
|
||||
@Export("canAddIgnore")
|
||||
final boolean canAddIgnore() {
|
||||
return this.ignoreList.isFull() || this.ignoreList.size() >= 100 && Client.field209 != 1;
|
||||
}
|
||||
|
||||
@@ -302,7 +307,7 @@ public class FriendSystem {
|
||||
var3 = var2 ? WorldMapIcon1.field1030 : class12.field1111;
|
||||
}
|
||||
|
||||
if (var0 == 1927) {
|
||||
if (var0 == ScriptOpcodes.CC_CALLONRESIZE) {
|
||||
if (Interpreter.field425 >= 10) {
|
||||
throw new RuntimeException();
|
||||
} else if (var3.field975 == null) {
|
||||
|
||||
Reference in New Issue
Block a user