Wolfieheart / ArmorStandEditor

Spigot/Paper etc. plugin to allow players to edit armorstands without commands.
GNU General Public License v3.0
25 stars 19 forks source link

[Bug]: Error in folia 1.20.4 #527

Closed SeemWind closed 1 month ago

SeemWind commented 1 month ago

Expected behavior

no error log

Observed/Actual behavior

Could not pass event PlayerInteractAtEntityEvent to ArmorStandEditor v1.20.6-46.1
java.lang.NoSuchFieldError: Class org.bukkit.inventory.ItemFlag does not have member field 'org.bukkit.inventory.ItemFlag HIDE_ADDITIONAL_TOOLTIP'
        at io.github.rypofalem.armorstandeditor.menu.EquipmentMenu.createIcon(EquipmentMenu.java:90) ~[armorstandeditor-1.20.6-46.1.jar:?]
        at io.github.rypofalem.armorstandeditor.menu.EquipmentMenu.fillInventory(EquipmentMenu.java:68) ~[armorstandeditor-1.20.6-46.1.jar:?]
        at io.github.rypofalem.armorstandeditor.menu.EquipmentMenu.open(EquipmentMenu.java:96) ~[armorstandeditor-1.20.6-46.1.jar:?]
        at io.github.rypofalem.armorstandeditor.PlayerEditor.openEquipment(PlayerEditor.java:217) ~[armorstandeditor-1.20.6-46.1.jar:?]
        at io.github.rypofalem.armorstandeditor.PlayerEditor.editArmorStand(PlayerEditor.java:170) ~[armorstandeditor-1.20.6-46.1.jar:?]
        at io.github.rypofalem.armorstandeditor.PlayerEditor.reverseEditArmorStand(PlayerEditor.java:261) ~[armorstandeditor-1.20.6-46.1.jar:?]
        at io.github.rypofalem.armorstandeditor.PlayerEditorManager.applyRightTool(PlayerEditorManager.java:362) ~[armorstandeditor-1.20.6-46.1.jar:?]
        at io.github.rypofalem.armorstandeditor.PlayerEditorManager.onArmorStandInteract(PlayerEditorManager.java:128) ~[armorstandeditor-1.20.6-46.1.jar:?]
        at com.destroystokyo.paper.event.executor.MethodHandleEventExecutor.execute(MethodHandleEventExecutor.java:40) ~[folia-api-1.20.4-R0.1-SNAPSHOT.jar:?]
        at co.aikar.timings.TimedEventExecutor.execute(TimedEventExecutor.java:77) ~[folia-api-1.20.4-R0.1-SNAPSHOT.jar:git-Folia-"ec6b172"]
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:70) ~[folia-api-1.20.4-R0.1-SNAPSHOT.jar:?]
        at io.papermc.paper.plugin.manager.PaperEventManager.callEvent(PaperEventManager.java:54) ~[folia-1.20.4.jar:git-Folia-"ec6b172"]
        at io.papermc.paper.plugin.manager.PaperPluginManagerImpl.callEvent(PaperPluginManagerImpl.java:126) ~[folia-1.20.4.jar:git-Folia-"ec6b172"]
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:615) ~[folia-api-1.20.4-R0.1-SNAPSHOT.jar:?]
        at net.minecraft.server.network.ServerGamePacketListenerImpl$3.performInteraction(ServerGamePacketListenerImpl.java:2795) ~[?:?]
        at net.minecraft.server.network.ServerGamePacketListenerImpl$3.a(ServerGamePacketListenerImpl.java:2848) ~[?:?]
        at net.minecraft.network.protocol.game.ServerboundInteractPacket$InteractionAtLocationAction.dispatch(ServerboundInteractPacket.java:159) ~[?:?]
        at net.minecraft.network.protocol.game.ServerboundInteractPacket.dispatch(ServerboundInteractPacket.java:80) ~[?:?]
        at net.minecraft.server.network.ServerGamePacketListenerImpl.handleInteract(ServerGamePacketListenerImpl.java:2784) ~[?:?]
        at net.minecraft.network.protocol.game.ServerboundInteractPacket.handle(ServerboundInteractPacket.java:67) ~[?:?]
        at net.minecraft.network.protocol.game.ServerboundInteractPacket.handle(ServerboundInteractPacket.java:12) ~[?:?]
        at net.minecraft.network.protocol.PacketUtils.lambda$ensureRunningOnSameThread$1(PacketUtils.java:56) ~[?:?]
        at net.minecraft.network.protocol.PacketUtils.lambda$ensureRunningOnSameThread$2(PacketUtils.java:102) ~[?:?]
        at io.papermc.paper.threadedregions.EntityScheduler.executeTick(EntityScheduler.java:173) ~[folia-1.20.4.jar:git-Folia-"ec6b172"]
        at net.minecraft.server.MinecraftServer.tickServer(MinecraftServer.java:1646) ~[folia-1.20.4.jar:git-Folia-"ec6b172"]
        at io.papermc.paper.threadedregions.TickRegions$ConcreteRegionTickHandle.tickRegion(TickRegions.java:407) ~[folia-1.20.4.jar:git-Folia-"ec6b172"]
        at io.papermc.paper.threadedregions.TickRegionScheduler$RegionScheduleHandle.runTick(TickRegionScheduler.java:404) ~[folia-1.20.4.jar:git-Folia-"ec6b172"]
        at ca.spottedleaf.concurrentutil.scheduler.SchedulerThreadPool$TickThreadRunner.run(SchedulerThreadPool.java:525) ~[folia-1.20.4.jar:git-Folia-"ec6b172"]
        at java.lang.Thread.run(Thread.java:1570) ~[?:?]

Steps/models to reproduce

use as usual

Plugin list

ase

Plugin Version

v1.20.6-46.1

Server Version

folia 1.20.4

Other

No response

Wolfieheart commented 1 month ago

This sounds like something didnt get ported to Folia, which I find strange since it is present on Paper.

Wolfieheart commented 1 month ago

Found the issue. Commit/Fix Incoming

Sikatsu commented 1 month ago

I do not use Folia, but this is the error I experienced: https://pastebin.com/7EfME5hp

Wolfieheart commented 1 month ago

Fixed with the merge in of 1.20.6-46.2. Tested on Paper/Spigot/Folia 1.20.4 and Paper/Spigot 1.20.6