diff options
| author | shedaniel <daniel@shedaniel.me> | 2022-11-12 14:46:44 +0800 |
|---|---|---|
| committer | shedaniel <daniel@shedaniel.me> | 2023-05-29 21:19:41 +0800 |
| commit | e7f02cc97d19c99e02bffeaa97f3422bc8b764ad (patch) | |
| tree | b14bf8d41644456ace99b181ea835cae43a46594 /runtime/src/main/java/me | |
| parent | 20b87ef1fa159ff4166dfeb2eae857af3532feb0 (diff) | |
| download | RoughlyEnoughItems-e7f02cc97d19c99e02bffeaa97f3422bc8b764ad.tar.gz RoughlyEnoughItems-e7f02cc97d19c99e02bffeaa97f3422bc8b764ad.tar.bz2 RoughlyEnoughItems-e7f02cc97d19c99e02bffeaa97f3422bc8b764ad.zip | |
Solve some z-fighting for auto crafting
Diffstat (limited to 'runtime/src/main/java/me')
2 files changed, 2 insertions, 2 deletions
diff --git a/runtime/src/main/java/me/shedaniel/rei/impl/client/gui/screen/CompositeDisplayViewingScreen.java b/runtime/src/main/java/me/shedaniel/rei/impl/client/gui/screen/CompositeDisplayViewingScreen.java index 097e90f62..338300f38 100644 --- a/runtime/src/main/java/me/shedaniel/rei/impl/client/gui/screen/CompositeDisplayViewingScreen.java +++ b/runtime/src/main/java/me/shedaniel/rei/impl/client/gui/screen/CompositeDisplayViewingScreen.java @@ -162,7 +162,7 @@ public class CompositeDisplayViewingScreen extends AbstractDisplayViewingScreen this.widgets.addAll(setupDisplay); Optional<ButtonArea> supplier = CategoryRegistry.getInstance().get(category.getCategoryIdentifier()).getPlusButtonArea(); if (supplier.isPresent() && supplier.get().get(recipeBounds) != null) - this.widgets.add(InternalWidgets.createAutoCraftingButtonWidget(recipeBounds, supplier.get().get(recipeBounds), new TextComponent(supplier.get().getButtonText()), display::provideInternalDisplay, display::provideInternalDisplayIds, setupDisplay, category)); + this.widgets.add(Widgets.withTranslate(InternalWidgets.createAutoCraftingButtonWidget(recipeBounds, supplier.get().get(recipeBounds), new TextComponent(supplier.get().getButtonText()), display::provideInternalDisplay, display::provideInternalDisplayIds, setupDisplay, category), 0, 0, 100)); int index = 0; for (DisplaySpec recipeDisplay : categoryMap.get(category)) { diff --git a/runtime/src/main/java/me/shedaniel/rei/impl/client/gui/screen/DefaultDisplayViewingScreen.java b/runtime/src/main/java/me/shedaniel/rei/impl/client/gui/screen/DefaultDisplayViewingScreen.java index f7e9ebf1c..d4a814239 100644 --- a/runtime/src/main/java/me/shedaniel/rei/impl/client/gui/screen/DefaultDisplayViewingScreen.java +++ b/runtime/src/main/java/me/shedaniel/rei/impl/client/gui/screen/DefaultDisplayViewingScreen.java @@ -265,7 +265,7 @@ public class DefaultDisplayViewingScreen extends AbstractDisplayViewingScreen { this.recipeBounds.put(displayBounds, Pair.of(display, setupDisplay)); this.widgets.add(new DisplayCompositeWidget(display, setupDisplay, displayBounds)); if (plusButtonArea.isPresent()) { - this.widgets.add(InternalWidgets.createAutoCraftingButtonWidget(displayBounds, plusButtonArea.get().get(displayBounds), new TextComponent(plusButtonArea.get().getButtonText()), displaySupplier, display::provideInternalDisplayIds, setupDisplay, getCurrentCategory())); + this.widgets.add(Widgets.withTranslate(InternalWidgets.createAutoCraftingButtonWidget(displayBounds, plusButtonArea.get().get(displayBounds), new TextComponent(plusButtonArea.get().getButtonText()), displaySupplier, display::provideInternalDisplayIds, setupDisplay, getCurrentCategory()), 0, 0, 100)); } } } |
