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:
Change pearl cooldown of certain kit to -1
Go play one duel and throw one pearl
Look for errors in console
Expected behavior
No console errors
Screenshots
Errors and console logs
Screenshot:
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
[yes ] The issue occurs on latest version of StrikePractice.
[yes] The issue occurs without other plugins (or non-official addons).
[yes] I am using regular spigot or paper (not a fork) and the issue still occurs.
[yes] I have purchased StrikePractice or I am working with someone who has purchased the resource.
Versions:
Server version [1.17.1 Purpur & Default spigot]
Client version [1.16.5/1.17.1]
Other version [0 addons, newest version of strikepractice]
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:
Expected behavior No console errors
Screenshots![obraz](https://user-images.githubusercontent.com/86470291/160261264-095f1c2a-1125-45c5-b024-7c95890b52f9.png)
Errors and console logs Screenshot:
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