aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/me/shedaniel/rei/gui/widget/ButtonWidget.java
diff options
context:
space:
mode:
authorUnknown <shekwancheung0528@gmail.com>2019-05-09 22:38:34 +0800
committerUnknown <shekwancheung0528@gmail.com>2019-05-09 22:38:34 +0800
commitc1b0219e8d5458ddf1eccc194d34893f698b7d88 (patch)
treea0ed116ad122b66721c5fe9345925e04f3c73a47 /src/main/java/me/shedaniel/rei/gui/widget/ButtonWidget.java
parent6017255b2b2704031a784eafd2bd720f1e7b8fc2 (diff)
downloadRoughlyEnoughItems-c1b0219e8d5458ddf1eccc194d34893f698b7d88.tar.gz
RoughlyEnoughItems-c1b0219e8d5458ddf1eccc194d34893f698b7d88.tar.bz2
RoughlyEnoughItems-c1b0219e8d5458ddf1eccc194d34893f698b7d88.zip
VillagerRecipeViewingScreen done
Diffstat (limited to 'src/main/java/me/shedaniel/rei/gui/widget/ButtonWidget.java')
-rw-r--r--src/main/java/me/shedaniel/rei/gui/widget/ButtonWidget.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main/java/me/shedaniel/rei/gui/widget/ButtonWidget.java b/src/main/java/me/shedaniel/rei/gui/widget/ButtonWidget.java
index 2431ca5e1..9ad51e516 100644
--- a/src/main/java/me/shedaniel/rei/gui/widget/ButtonWidget.java
+++ b/src/main/java/me/shedaniel/rei/gui/widget/ButtonWidget.java
@@ -74,8 +74,8 @@ public abstract class ButtonWidget extends HighlightableWidget {
this.blit(x + 4, y + height - 4, 4, 62 + textureOffset * 20, width - 8, 4);
for(int i = y + 4; i < y + height - 4; i += 4) {
- this.blit(x, i, 0, 50 + textureOffset * 20, width / 2, MathHelper.clamp(y + height - 4 - i, 0, 4));
- this.blit(x + width / 2, i, 200 - width / 2, 50 + textureOffset * 20, width / 2, MathHelper.clamp(y + height - 4 - i, 0, 4));
+ this.blit(x, i, 0, 50 + textureOffset * 20, MathHelper.ceil(width / 2f), MathHelper.clamp(y + height - 4 - i, 0, 4));
+ this.blit(x + MathHelper.ceil(width / 2f), i, 200 - MathHelper.floor(width / 2f), 50 + textureOffset * 20, MathHelper.floor(width / 2f), MathHelper.clamp(y + height - 4 - i, 0, 4));
}
int colour = 14737632;