rs-client: Cleanup (#1087)

* rs-client: name SpriteBuffer

* rs-client: (re)name spritebuffer methods

* rs-client/deob: Add missed @Export's, make updatemappings fix this next time

* rs-client: run intellij redundant else inspection

* rs-client: invert some script interpreter if's

* deob: checkstyle fixes

* rs-client: SpriteBuffer_loadSprite -> SpriteBuffer_bufferFile
This commit is contained in:
Lucwousin
2019-07-23 19:43:31 +02:00
committed by GitHub
parent 61b4531a0d
commit 596689a4f7
175 changed files with 9825 additions and 9776 deletions

View File

@@ -81,9 +81,8 @@ public abstract class AbstractWorldMapIcon {
boolean fitsScreen(int var1, int var2) {
if (this.elementFitsScreen(var1, var2)) {
return true;
} else {
return this.labelFitsScreen(var1, var2);
}
return this.labelFitsScreen(var1, var2);
}
@ObfuscatedName("d")
@@ -105,47 +104,46 @@ public abstract class AbstractWorldMapIcon {
boolean elementFitsScreen(int var1, int var2) {
if (!this.hasValidElement()) {
return false;
} else {
WorldMapElement var3 = class222.getWorldMapElement(this.getElement());
int var4 = this.getSubWidth();
int var5 = this.getSubHeight();
switch(var3.horizontalAlignment.value) {
case 0:
if (var1 <= this.screenX - var4 || var1 > this.screenX) {
return false;
}
break;
case 1:
if (var1 >= this.screenX && var1 < var4 + this.screenX) {
break;
}
return false;
case 2:
if (var1 < this.screenX - var4 / 2 || var1 > var4 / 2 + this.screenX) {
return false;
}
}
switch(var3.verticalAlignment.value) {
case 0:
if (var2 < this.screenY - var5 / 2 || var2 > var5 / 2 + this.screenY) {
return false;
}
break;
case 1:
if (var2 <= this.screenY - var5 || var2 > this.screenY) {
return false;
}
break;
case 2:
if (var2 < this.screenY || var2 >= var5 + this.screenY) {
return false;
}
}
return true;
}
WorldMapElement var3 = class222.getWorldMapElement(this.getElement());
int var4 = this.getSubWidth();
int var5 = this.getSubHeight();
switch(var3.horizontalAlignment.value) {
case 0:
if (var1 <= this.screenX - var4 || var1 > this.screenX) {
return false;
}
break;
case 1:
if (var1 >= this.screenX && var1 < var4 + this.screenX) {
break;
}
return false;
case 2:
if (var1 < this.screenX - var4 / 2 || var1 > var4 / 2 + this.screenX) {
return false;
}
}
switch(var3.verticalAlignment.value) {
case 0:
if (var2 < this.screenY - var5 / 2 || var2 > var5 / 2 + this.screenY) {
return false;
}
break;
case 1:
if (var2 <= this.screenY - var5 || var2 > this.screenY) {
return false;
}
break;
case 2:
if (var2 < this.screenY || var2 >= var5 + this.screenY) {
return false;
}
}
return true;
}
@ObfuscatedName("z")
@@ -158,11 +156,11 @@ public abstract class AbstractWorldMapIcon {
WorldMapLabel var3 = this.getLabel();
if (var3 == null) {
return false;
} else if (var1 >= this.screenX - var3.width / 2 && var1 <= var3.width / 2 + this.screenX) {
return var2 >= this.screenY && var2 <= this.screenY + var3.height;
} else {
return false;
}
if (var1 >= this.screenX - var3.width / 2 && var1 <= var3.width / 2 + this.screenX) {
return var2 >= this.screenY && var2 <= this.screenY + var3.height;
}
return false;
}
@ObfuscatedName("r")