diff --git a/.github/workflows/loader-client.yaml b/.github/workflows/build.yaml similarity index 72% rename from .github/workflows/loader-client.yaml rename to .github/workflows/build.yaml index 814e7b8a..9ca904e2 100644 --- a/.github/workflows/loader-client.yaml +++ b/.github/workflows/build.yaml @@ -5,7 +5,7 @@ on: jobs: loader-client: - name: Build Loader and Client + name: Build Projects runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 @@ -23,9 +23,16 @@ jobs: - name: Run Gradle build run: gradle build -x :deob-annotations:build - - name: Upload a Build Artifact + - name: Upload Loader-Client Artifact uses: actions/upload-artifact@v3 with: name: loader-client path: | loader/build/libs/* + + - name: Upload Mapview Artifact + uses: actions/upload-artifact@v3 + with: + name: mapview + path: | + mapview/build/libs/* diff --git a/mapview/src/main/java/mapview.java b/mapview/src/main/java/mapview.java index 1498faf6..1b03fc57 100644 --- a/mapview/src/main/java/mapview.java +++ b/mapview/src/main/java/mapview.java @@ -73,6 +73,7 @@ public final class mapview extends GameShell { private byte[][] locMapscenes; private boolean[][] objTiles; + private boolean[][] npcTiles; @OriginalMember(owner = "mapview!mapview", name = "X", descriptor = "Lmapview!j;") @@ -133,22 +134,22 @@ public final class mapview extends GameShell { private int labelCount; @OriginalMember(owner = "mapview!mapview", name = "F", descriptor = "I") - private int colorInactiveBorderTL = 0x887755; + private final int colorInactiveBorderTL = 0x887755; @OriginalMember(owner = "mapview!mapview", name = "G", descriptor = "I") - private int colorInactive = 0x776644; + private final int colorInactive = 0x776644; @OriginalMember(owner = "mapview!mapview", name = "H", descriptor = "I") - private int colorInactiveBorderBR = 0x665533; + private final int colorInactiveBorderBR = 0x665533; @OriginalMember(owner = "mapview!mapview", name = "I", descriptor = "I") - private int colorActiveBorderTL = 0xaa0000; + private final int colorActiveBorderTL = 0xaa0000; @OriginalMember(owner = "mapview!mapview", name = "J", descriptor = "I") - private int colorActive = 0x990000; + private final int colorActive = 0x990000; @OriginalMember(owner = "mapview!mapview", name = "K", descriptor = "I") - private int colorActiveBorderBR = 0x880000; + private final int colorActiveBorderBR = 0x880000; @OriginalMember(owner = "mapview!mapview", name = "L", descriptor = "Z") private boolean redraw = true; @@ -222,7 +223,7 @@ public final class mapview extends GameShell { private boolean showOverview = false; @OriginalMember(owner = "mapview!mapview", name = "Jb", descriptor = "I") - private int maxLabelCount = 1000; + private final int maxLabelCount = 1000; @OriginalMember(owner = "mapview!mapview", name = "Kb", descriptor = "[Ljava/lang/String;") private String[] labelText = new String[this.maxLabelCount]; @@ -641,20 +642,19 @@ protected void unload() { @Override protected void update() { if (super.actionKey[1] == 1) { - this.offsetX = (int) ((double) this.offsetX - 16.0D / this.zoom); + this.offsetX = (int) ((double) this.offsetX - (16.0D / this.zoom)); this.redraw = true; } if (super.actionKey[2] == 1) { - this.offsetX = (int) ((double) this.offsetX + 16.0D / this.zoom); + this.offsetX = (int) ((double) this.offsetX + (16.0D / this.zoom)); this.redraw = true; } - if (super.actionKey[3] == 1) { - this.offsetZ = (int) ((double) this.offsetZ - 16.0D / this.zoom); + this.offsetZ = (int) ((double) this.offsetZ - (16.0D / this.zoom)); this.redraw = true; } if (super.actionKey[4] == 1) { - this.offsetZ = (int) ((double) this.offsetZ + 16.0D / this.zoom); + this.offsetZ = (int) ((double) this.offsetZ + (16.0D / this.zoom)); this.redraw = true; } @@ -846,10 +846,10 @@ protected void update() { if (top < 48) { this.offsetZ = (int) (503.0D / this.zoom) + 48; } - if (right > (this.sizeX - 48)) { - this.offsetX = this.sizeX - 48 - (int) (635.0D / this.zoom); + if (right > this.sizeX - 48) { + this.offsetX = (this.sizeX - 48) - (int) (635.0D / this.zoom); } - if (bottom > (this.sizeZ - 48)) { + if (bottom > this.sizeZ - 48) { this.offsetZ = (this.sizeZ - 48) - (int) (503.0D / this.zoom); } } @@ -1070,7 +1070,7 @@ private void drawMap(@OriginalArg(0) int left, @OriginalArg(1) int top, @Origina wall -= 4; } if (wall == 27 || wall == 28) { - // bugfix: draw diagonal active locs (doors) + // bugfix: drawing diagonal doors rgb = 0xcc0000; wall -= 2; } diff --git a/mapview/src/main/java/sig.java b/mapview/src/main/java/sig.java index e7450825..578a6d3d 100644 --- a/mapview/src/main/java/sig.java +++ b/mapview/src/main/java/sig.java @@ -1,5 +1,5 @@ public class sig { - public static final int len = 317398; + public static final int len = 324757; - public static final int[] sha = { -80, -121, -25, -125, -3, 0, -18, -115, -90, -65, 86, 8, -9, 97, -7, -44, -77, 63, -20, 28 }; + public static final int[] sha = { -84, -71, 57, -4, 22, -94, -89, 99, -64, -76, 60, -108, 66, -91, 74, -108, 44, 38, -127, 44 }; } \ No newline at end of file