Skip to content

Commit

Permalink
Fix backport
Browse files Browse the repository at this point in the history
Signed-off-by: Zailer43 <minecraftpelusa@gmail.com>
  • Loading branch information
Zailer43 committed Sep 19, 2024
1 parent 1b5f442 commit 9fb1081
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/main/java/fzmm/zailer/me/utils/SkinPart.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import com.google.common.collect.ImmutableList;
import fzmm.zailer.me.utils.position.PosI;
import net.minecraft.util.math.MathHelper;

import java.util.ArrayList;
import java.util.List;
Expand Down Expand Up @@ -205,7 +206,7 @@ default byte[][] get(byte x, byte y, byte hatX, byte hatY, byte width, byte heig
// [x][x][x][x]
byte[][] result = new byte[2][4];

byte rightEmptyAreaSize = (byte) Math.clamp(width - maxWidth + emptyAreaSize, 0, emptyAreaSize);
byte rightEmptyAreaSize = (byte) MathHelper.clamp(width - maxWidth + emptyAreaSize, 0, emptyAreaSize);

// [ ][x][x][ ]
// [ ][ ][ ][ ]
Expand Down

0 comments on commit 9fb1081

Please sign in to comment.