Skip to content

Commit

Permalink
Prefer the user's preference to the server ones
Browse files Browse the repository at this point in the history
  • Loading branch information
EnnuiL committed Nov 27, 2021
1 parent 1842f09 commit 7de270e
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions src/main/java/io/github/ennuil/okzoomer/utils/ZoomUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,16 @@ public static final void changeZoomDivisor(boolean increase) {
double lesserChangedZoomDivisor;

if (ZoomPackets.getForceZoomDivisors()) {
minimumZoomDivisor = ZoomPackets.getMinimumZoomDivisor();
maximumZoomDivisor = ZoomPackets.getMaximumZoomDivisor();
double packetMinimumZoomDivisor = ZoomPackets.getMaximumZoomDivisor();
double packetMaximumZoomDivisor = ZoomPackets.getMaximumZoomDivisor();

if (packetMinimumZoomDivisor < minimumZoomDivisor) {
minimumZoomDivisor = packetMinimumZoomDivisor;
}

if (packetMaximumZoomDivisor > maximumZoomDivisor) {
maximumZoomDivisor = packetMaximumZoomDivisor;
}
}

if (increase) {
Expand Down

0 comments on commit 7de270e

Please sign in to comment.