Skip to content

Commit 22cf597

Browse files
committed
plus one on mouse button code and limit texture object to size of 4096
1 parent 7f36fc5 commit 22cf597

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

src/main/java/de/srendi/advancedperipherals/client/screens/KeyboardScreen.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ public boolean mouseClicked(double x, double y, int button) {
142142
if (this.mouseState != MouseState.CAPTURE) {
143143
return false;
144144
}
145-
PacketDistributor.sendToServer(new KeyboardMouseClickPacket(button, false));
145+
PacketDistributor.sendToServer(new KeyboardMouseClickPacket(button + 1, false));
146146
return true;
147147
}
148148

@@ -151,7 +151,7 @@ public boolean mouseReleased(double x, double y, int button) {
151151
if (this.mouseState != MouseState.CAPTURE) {
152152
return false;
153153
}
154-
PacketDistributor.sendToServer(new KeyboardMouseClickPacket(button, true));
154+
PacketDistributor.sendToServer(new KeyboardMouseClickPacket(button + 1, true));
155155
return true;
156156
}
157157

src/main/java/de/srendi/advancedperipherals/common/smartglasses/modules/overlay/objects/three_dim/TextureObject.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
import javax.imageio.ImageIO;
4040

4141
public class TextureObject extends ThreeDimensionalObject implements AutoCloseable {
42-
private static final int MAX_DIM = 0xffff;
42+
private static final int MAX_DIM = 0xfff;
4343
private static final int[] ZERO_DATA = new int[0];
4444

4545
@FloatingNumberProperty

0 commit comments

Comments
 (0)