mirror of
https://github.com/GTNewHorizons/NotEnoughItems.git
synced 2026-11-12 16:37:45 +00:00
Make the "Accepts following:" tooltip work for otherStacks (#625)
Co-authored-by: Maya <10861407+serenibyss@users.noreply.github.com>
This commit is contained in:
1 parent
5ad6095c43
commit
29ade6f327
1 file changed
+11
-6
@@ -882,14 +882,19 @@ public abstract class GuiRecipe<H extends IRecipeHandler> extends GuiContainer i
|
||||
if (NEIClientConfig.showCycledIngredientsTooltip() && itemstack != null) {
|
||||
PositionedStack hovered = null;
|
||||
|
||||
for (int refIndex = 0; refIndex < indices.size() && hovered == null; refIndex++) {
|
||||
outer: for (int refIndex = 0; refIndex < indices.size(); refIndex++) {
|
||||
final int recipeIndex = indices.get(refIndex);
|
||||
final List<PositionedStack> stacks = handler.original.getIngredientStacks(recipeIndex);
|
||||
|
||||
for (PositionedStack pStack : stacks) {
|
||||
if (isMouseOver(pStack, refIndex)) {
|
||||
hovered = pStack;
|
||||
break;
|
||||
List<List<PositionedStack>> stackGroups = Arrays.asList(
|
||||
handler.original.getIngredientStacks(recipeIndex),
|
||||
handler.original.getOtherStacks(recipeIndex));
|
||||
|
||||
for (List<PositionedStack> group : stackGroups) {
|
||||
for (PositionedStack pStack : group) {
|
||||
if (isMouseOver(pStack, refIndex)) {
|
||||
hovered = pStack;
|
||||
break outer;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user