Open xinhaihai opened 1 year ago
Sorry it took me a while to respond to this I have been quite busy lately and have not had the time to work on this project. Should time open in my schedule I will definitely look into this, I'm sorry you have been experiencing this issue and I hope to be able to get to the bottom of it soon.
Xinhaihai, sorry it took me so long to get to this, I have good news and bad news, the good news is that I have fixed a bug in the way experience was calculated and so experience in and out of the bank should be consistent now. Bad news is I still haven't gotten to work on the error that you were experiencing here.
I'm sorry to say that when I used the latest version of xpbank, I still reported that the players' experience in and out of the experience was inconsistent, and the following error occurred
org.bukkit.command.CommandException: Unhandled exception executing command 'xpbank' in plugin XpBank v1.12.3 at org.bukkit.command.PluginCommand.execute(PluginCommand.java:47) ~[purpur-api-1.20.1-R0.1-SNAPSHOT.jar:?] at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:168) ~[purpur-api-1.20.1-R0.1-SNAPSHOT.jar:?] at org.bukkit.craftbukkit.v1_20_R1.CraftServer.dispatchCommand(CraftServer.java:1020) ~[purpur-1.20.1.jar:git-Purpur-2015] at org.bukkit.craftbukkit.v1_20_R1.command.BukkitCommandWrapper.run(BukkitCommandWrapper.java:64) ~[purpur-1.20.1.jar:git-Purpur-2015] at com.mojang.brigadier.CommandDispatcher.execute(CommandDispatcher.java:265) ~[purpur-1.20.1.jar:?] at net.minecraft.commands.Commands.performCommand(Commands.java:332) ~[?:?] at net.minecraft.commands.Commands.performCommand(Commands.java:316) ~[?:?] at net.minecraft.server.network.ServerGamePacketListenerImpl.performChatCommand(ServerGamePacketListenerImpl.java:2392) ~[?:?] at net.minecraft.server.network.ServerGamePacketListenerImpl.lambda$handleChatCommand$21(ServerGamePacketListenerImpl.java:2352) ~[?:?] at net.minecraft.util.thread.BlockableEventLoop.lambda$submitAsync$0(BlockableEventLoop.java:59) ~[?:?] at java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1768) ~[?:?] at net.minecraft.server.TickTask.run(TickTask.java:18) ~[purpur-1.20.1.jar:git-Purpur-2015] at net.minecraft.util.thread.BlockableEventLoop.doRunTask(BlockableEventLoop.java:153) ~[?:?] at net.minecraft.util.thread.ReentrantBlockableEventLoop.doRunTask(ReentrantBlockableEventLoop.java:24) ~[?:?] at net.minecraft.server.MinecraftServer.doRunTask(MinecraftServer.java:1366) ~[purpur-1.20.1.jar:git-Purpur-2015] at net.minecraft.server.MinecraftServer.d(MinecraftServer.java:197) ~[purpur-1.20.1.jar:git-Purpur-2015] at net.minecraft.util.thread.BlockableEventLoop.pollTask(BlockableEventLoop.java:126) ~[?:?] at net.minecraft.server.MinecraftServer.pollTaskInternal(MinecraftServer.java:1343) ~[purpur-1.20.1.jar:git-Purpur-2015] at net.minecraft.server.MinecraftServer.pollTask(MinecraftServer.java:1336) ~[purpur-1.20.1.jar:git-Purpur-2015] at net.minecraft.util.thread.BlockableEventLoop.managedBlock(BlockableEventLoop.java:136) ~[?:?] at net.minecraft.server.MinecraftServer.tickServer(MinecraftServer.java:1413) ~[purpur-1.20.1.jar:git-Purpur-2015] at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1192) ~[purpur-1.20.1.jar:git-Purpur-2015] at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:323) ~[purpur-1.20.1.jar:git-Purpur-2015] at java.lang.Thread.run(Thread.java:833) ~[?:?] Caused by: java.lang.IllegalArgumentException: Experience progress must be between 0.0 and 1.0 (-1518.0) at com.google.common.base.Preconditions.checkArgument(Preconditions.java:220) ~[guava-31.1-jre.jar:?] at org.bukkit.craftbukkit.v1_20_R1.entity.CraftPlayer.setExp(CraftPlayer.java:1748) ~[purpur-1.20.1.jar:git-Purpur-2015] at me.head_block.xpbank.commands.Xp.addXp(Xp.java:551) ~[XPBank.jar:?] at me.head_block.xpbank.commands.Xp.asPlayer(Xp.java:182) ~[XPBank.jar:?] at me.head_block.xpbank.commands.Xp.onCommand(Xp.java:49) ~[XPBank.jar:?] at org.bukkit.command.PluginCommand.execute(PluginCommand.java:45) ~[purpur-api-1.20.1-R0.1-SNAPSHOT.jar:?] ... 23 more