Bestem0r / VillagerMarket

The shop plugin you've been looking for! Perfect for semi-vanilla servers.
12 stars 17 forks source link

[1.20.1] Market Suddenly Unstable #25

Open Epik-B0mber opened 1 month ago

Epik-B0mber commented 1 month ago

Hello! I just wanted to throw up a real fast issue with the plugin that I haven't been having before. I went to update it to the latest version, but that seemed to completely break the plugin, so upon bringing it back down the shops have been acting weird, where items start disappearing, multiple clicks are required for transaction, the menus are behaving strangely, and sometimes you're simply not allowed to interact until you rejoin the server. All I have is this error, hope this helps

[VillagerMarket] Task #59 for VillagerMarket v1.12.0 generated an exception java.lang.ArrayIndexOutOfBoundsException: Index 32 out of bounds for length 18 at java.util.Arrays$ArrayList.set(Arrays.java:4170) ~[?:?] at net.minecraft.core.NonNullList.set(NonNullList.java:54) ~[server-1.20.1-20230612.114412-srg.jar%23507!/:?] at org.bukkit.craftbukkit.v1_20_R1.inventory.CraftInventoryCustom$MinecraftInventory.m6836(CraftInventoryCustom.java:141) ~[forge-1.20.1-47.3.7-universal.jar%23512!/:?] at org.bukkit.craftbukkit.v1_20_R1.inventory.CraftInventory.setItem(CraftInventory.java:100) ~[forge-1.20.1-47.3.7-universal.jar%23512!/:?] at net.bestemor.villagermarket.menu.Shopfront.updateEditorInventory(Shopfront.java:170) ~[?:?] at net.bestemor.villagermarket.menu.Shopfront.update(Shopfront.java:122) ~[?:?] at java.util.ArrayList.forEach(ArrayList.java:1511) ~[?:?] at net.bestemor.villagermarket.menu.ShopfrontHolder.load(ShopfrontHolder.java:54) ~[?:?] at net.bestemor.villagermarket.shop.PlayerShop.lambda$new$0(PlayerShop.java:75) ~[?:?] at org.bukkit.craftbukkit.v1_20_R1.scheduler.CraftTask.run(CraftTask.java:78) ~[forge-1.20.1-47.3.7-universal.jar%23512!/:?] at org.bukkit.craftbukkit.v1_20_R1.scheduler.CraftScheduler.mainThreadHeartbeat(CraftScheduler.java:416) ~[forge-1.20.1-47.3.7-universal.jar%23512!/:?] at net.minecraft.server.MinecraftServer.m5703(MinecraftServer.java:1132) ~[server-1.20.1-20230612.114412-srg.jar%23507!/:?] at net.minecraft.server.dedicated.DedicatedServer.m5703(DedicatedServer.java:360) ~[server-1.20.1-20230612.114412-srg.jar%23507!/:?] at net.minecraft.server.MinecraftServer.m5705(MinecraftServer.java:1070) ~[server-1.20.1-20230612.114412-srg.jar%23507!/:?] at net.minecraft.server.MinecraftServer.m130011(MinecraftServer.java:909) ~[server-1.20.1-20230612.114412-srg.jar%23507!/:?] at net.minecraft.server.MinecraftServer.m206580(MinecraftServer.java:285) ~[server-1.20.1-20230612.114412-srg.jar%23507!/:?] at java.lang.Thread.run(Thread.java:840) [?:?]

Bestem0r commented 1 month ago

Hi! What errors are you getting when upgrading to 1.12.1. Can you also list your other plugins?

Epik-B0mber commented 1 month ago

Here are my plugins: EssentialsX (and its descendants) GraviTree GSit LuckPerms OfflineManager Shopkeepers Vault VM WE WorldEditSUI WG

None of these have ever clashed with the plugin before. I haven't been having any trouble for some years now, when all of the sudden nothing worked on the upgrade, and I suppose some sort of residue was made from backtracking, as I've had a similar experience with Shopkeepers having to manually rebuild every single NPC.

I just went to playtest the latest version of the plugin and found that I couldn't replicate the issues that I had had. :/ I don't know if I require other players (that I'll try to gather) or if it was just some sort of particularly bad day on the server, but it was well experienced by all parties. I'll see if it can be replicated. In the meantime, I only generated this error:

[11:26:52] [Server thread/WARN] [net.bestemor.villagermarket.VMPlugin]: [VillagerMarket] Task #61 for VillagerMarket v1.12.1 generated an exception java.lang.ArrayIndexOutOfBoundsException: Index 32 out of bounds for length 18 at java.util.Arrays$ArrayList.set(Arrays.java:4170) ~[?:?] at net.minecraft.core.NonNullList.set(NonNullList.java:54) ~[server-1.20.1-20230612.114412-srg.jar%23511!/:?] at org.bukkit.craftbukkit.v1_20_R1.inventory.CraftInventoryCustom$MinecraftInventory.m_6836_(CraftInventoryCustom.java:141) ~[forge-1.20.1-47.3.1-universal.jar%23516!/:?] at org.bukkit.craftbukkit.v1_20_R1.inventory.CraftInventory.setItem(CraftInventory.java:100) ~[forge-1.20.1-47.3.1-universal.jar%23516!/:?] at net.bestemor.villagermarket.menu.Shopfront.updateEditorInventory(Shopfront.java:170) ~[?:?] at net.bestemor.villagermarket.menu.Shopfront.update(Shopfront.java:122) ~[?:?] at java.util.ArrayList.forEach(ArrayList.java:1511) ~[?:?] at net.bestemor.villagermarket.menu.ShopfrontHolder.load(ShopfrontHolder.java:54) ~[?:?] at net.bestemor.villagermarket.shop.PlayerShop.lambda$new$0(PlayerShop.java:76) ~[?:?] at org.bukkit.craftbukkit.v1_20_R1.scheduler.CraftTask.run(CraftTask.java:78) ~[forge-1.20.1-47.3.1-universal.jar%23516!/:?] at org.bukkit.craftbukkit.v1_20_R1.scheduler.CraftScheduler.mainThreadHeartbeat(CraftScheduler.java:416) ~[forge-1.20.1-47.3.1-universal.jar%23516!/:?] at net.minecraft.server.MinecraftServer.m_5703_(MinecraftServer.java:1135) ~[server-1.20.1-20230612.114412-srg.jar%23511!/:?] at net.minecraft.server.dedicated.DedicatedServer.m_5703_(DedicatedServer.java:349) ~[server-1.20.1-20230612.114412-srg.jar%23511!/:?] at net.minecraft.server.MinecraftServer.m_5705_(MinecraftServer.java:1074) ~[server-1.20.1-20230612.114412-srg.jar%23511!/:?] at net.minecraft.server.MinecraftServer.m_130011_(MinecraftServer.java:904) ~[server-1.20.1-20230612.114412-srg.jar%23511!/:?] at net.minecraft.server.MinecraftServer.m_206580_(MinecraftServer.java:281) ~[server-1.20.1-20230612.114412-srg.jar%23511!/:?] at java.lang.Thread.run(Thread.java:840) [?:?]

Thanks for the help! Hope this isn't a wild goose chase for you. Cheers!

Bestem0r commented 4 weeks ago

Hi again, and sorry for late response @Epik-B0mber. It looks like there's a shop with an item that's placed outside of the shopfront's range somewhere. Are you able to join my discord? I'll send you a build that fixes this