toppev / strikepractice-public

StrikePractice bug tracking and some free resources
2 stars 3 forks source link

Per kit pearl cooldown console error #3

Closed Wolren closed 2 years ago

Wolren commented 2 years ago

Describe the bug When you change the value of pearl cooldown to a certain kit to -1, console logs indicates that it is not a number and starts spamming a lot of errors (20-30 per second). Luckily pearl cooldown disappears as intended.

To Reproduce Steps to reproduce the behavior:

  1. Change pearl cooldown of certain kit to -1
  2. Go play one duel and throw one pearl
  3. Look for errors in console

Expected behavior No console errors

Screenshots obraz

Errors and console logs Screenshot: obraz Text: [00:13:51] [Craft Scheduler Thread - 86 - StrikePractice/WARN]: [StrikePractice] Plugin StrikePractice v3.4.3-SNAPSHOT generated an exception while executing task 103167 java.lang.IllegalArgumentException: Experience progress must be between 0.0 and 1.0 (NaN) at com.google.common.base.Preconditions.checkArgument(Preconditions.java:216) ~[patched_1.17.1.jar:git-Purpur-1428] at org.bukkit.craftbukkit.v1_17_R1.entity.CraftPlayer.setExp(CraftPlayer.java:1391) ~[patched_1.17.1.jar:git-Purpur-1428] at ga.strikepractice.d.a$a.run(PearlListener.java:158) ~[strikepractice-3.4.3.jar:?] at org.bukkit.craftbukkit.v1_17_R1.scheduler.CraftTask.run(CraftTask.java:101) ~[patched_1.17.1.jar:git-Purpur-1428] at org.bukkit.craftbukkit.v1_17_R1.scheduler.CraftAsyncTask.run(CraftAsyncTask.java:57) ~[patched_1.17.1.jar:git-Purpur-1428] at com.destroystokyo.paper.ServerSchedulerReportingWrapper.run(ServerSchedulerReportingWrapper.java:22) ~[patched_1.17.1.jar:git-Purpur-1428] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[?:?] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[?:?] at java.lang.Thread.run(Thread.java:833) ~[?:?]

Checklist

Versions:

Other plugins Not important

Wolren commented 2 years ago

I just checked and it occurs on cooldown value "0" too

toppev commented 2 years ago

This will be fixed & closed when next update is released.