Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: JER Villagers tab not working (Just Enough Resources compat) #65

Closed
Krutoy242 opened this issue Oct 5, 2023 · 5 comments
Closed

Comments

@Krutoy242
Copy link

Opening Villagers tab when JER installed caused error spam and malfunction of tab itself.

How to reproduce:

  1. Install only HEI 4.25.0 + JER 0.9.3.203
  2. Run game
  3. Open JEI tab with villagers
  4. See how total numbers of pages in this trade becomes less and less
  5. After some scrolling, only 2 bugged trades left
javaw_ATwvgBzgJa.mp4
[Client thread/ERROR] [HadEnoughItems]: Error caught from Recipe Category: jeresources.jei.villager.VillagerCategory
java.lang.IndexOutOfBoundsException: Index: 4, Size: 4
	at java.util.LinkedList.checkElementIndex(LinkedList.java:555) ~[?:1.8.0_352]
	at java.util.LinkedList.get(LinkedList.java:476) ~[?:1.8.0_352]
	at jeresources.entry.VillagerEntry.getVillagerTrades(VillagerEntry.java:37) ~[VillagerEntry.class:?]
	at jeresources.jei.villager.VillagerWrapper.getTrades(VillagerWrapper.java:35) ~[VillagerWrapper.class:?]
	at jeresources.jei.villager.VillagerCategory.setRecipe(VillagerCategory.java:58) ~[VillagerCategory.class:?]
	at jeresources.jei.villager.VillagerCategory.setRecipe(VillagerCategory.java:16) ~[VillagerCategory.class:?]
	at mezz.jei.gui.recipes.RecipeLayout.create(RecipeLayout.java:69) [RecipeLayout.class:?]
	at mezz.jei.gui.recipes.RecipeGuiLogic.getRecipeLayouts(RecipeGuiLogic.java:198) [RecipeGuiLogic.class:?]
	at mezz.jei.gui.recipes.RecipesGui.updateLayout(RecipesGui.java:492) [RecipesGui.class:?]
	at mezz.jei.gui.recipes.RecipesGui.onStateChange(RecipesGui.java:538) [RecipesGui.class:?]
	at mezz.jei.gui.recipes.RecipeGuiLogic.nextPage(RecipeGuiLogic.java:254) [RecipeGuiLogic.class:?]
	at mezz.jei.gui.recipes.RecipesGui.func_146284_a(RecipesGui.java:438) [RecipesGui.class:?]
	at net.minecraft.client.gui.GuiScreen.func_73864_a(GuiScreen.java:443) [blk.class:?]
	at mezz.jei.gui.recipes.RecipesGui.func_73864_a(RecipesGui.java:336) [RecipesGui.class:?]
	at net.minecraft.client.gui.GuiScreen.func_146274_d(GuiScreen.java:533) [blk.class:?]
	at mezz.jei.gui.recipes.RecipesGui.func_146274_d(RecipesGui.java:304) [RecipesGui.class:?]
	at net.minecraft.client.gui.GuiScreen.func_146269_k(GuiScreen.java:501) [blk.class:?]

debug.log

@Krutoy242 Krutoy242 changed the title Bug: JER Villagers tab not working (Just Enough Resources bug) Bug: JER Villagers tab not working (Just Enough Resources compat) Oct 5, 2023
@Krutoy242
Copy link
Author

Krutoy242 commented Oct 5, 2023

Rolling back to JustEnoughResources-1.12.2-0.9.2.60 fixed the issue. Seems like i should address it to JER github instead.

way2muchnoise/JustEnoughResources#423

@Krutoy242 Krutoy242 closed this as not planned Won't fix, can't repro, duplicate, stale Oct 5, 2023
@magcicada
Copy link

magcicada commented Oct 14, 2023

The weird that when running JER with HEI, the int of level
https://github.com/way2muchnoise/JustEnoughResources/blob/4daa2e0284075ce87546ce3668b14c895b800b58/src/main/java/jeresources/entry/VillagerEntry.java#L37 here will get int +1 than the original int of level, so it will get IndexOutOfBoundsException.

@Krutoy242
Copy link
Author

The weird that when running JER with HEI, the int of level way2muchnoise/JustEnoughResources@4daa2e0/src/main/java/jeresources/entry/VillagerEntry.java#L37 here will get int +1 than the original int of level, so it will get IndexOutOfBoundsException.

As far as i understand, even JEI would have this error, not just HEI.

@magcicada
Copy link

JustEnoughResources-1.12.2-0.9.3.jar.zip
try this mod file

@magcicada
Copy link

image
maybe it has been fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants