aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSoopyboo32 <49228220+Soopyboo32@users.noreply.github.com>2022-06-08 06:41:21 +0800
committerSoopyboo32 <49228220+Soopyboo32@users.noreply.github.com>2022-06-08 06:41:21 +0800
commitc01d28e92646a46fe02e8e8dd3c60c1abff2e1d3 (patch)
tree4762716fe0102e47c2cbca67ef5bf49f28c0c8be
parent43e36beb446236caf354bdd2d726aafc3d21732d (diff)
downloadSoopyV2-c01d28e92646a46fe02e8e8dd3c60c1abff2e1d3.tar.gz
SoopyV2-c01d28e92646a46fe02e8e8dd3c60c1abff2e1d3.tar.bz2
SoopyV2-c01d28e92646a46fe02e8e8dd3c60c1abff2e1d3.zip
Make eman hype hits number parsing more lenient
-rw-r--r--features/slayers/index.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/features/slayers/index.js b/features/slayers/index.js
index ed7bb04..7076736 100644
--- a/features/slayers/index.js
+++ b/features/slayers/index.js
@@ -91,7 +91,7 @@ class Slayers extends Feature {
}
}
- this.slayerExp[this.lastSlayerType] = this.lastSlayerExp* multiplier + (this.slayerExp[this.lastSlayerType] || 0) ;
+ this.slayerExp[this.lastSlayerType] = this.lastSlayerExp * multiplier + (this.slayerExp[this.lastSlayerType] || 0);
if (this.expOnKill.getValue()) {
cancel(e);
@@ -407,12 +407,12 @@ class Slayers extends Feature {
if (emanHealth.includes("k")) {
emanText += " &c0 Hits"
- } else if (emanHealth.includes("M") && parseInt(emanHealth) <= this.whenToShowHitsLeft.getValue()) {
+ } else if (emanHealth.includes("M") && parseInt(emanHealth) <= parseFloat(this.whenToShowHitsLeft.getValue())) {
let thunderLevel = MathLib.clamp(parseInt(this.thunderLevel.getValue()), 5, 7)
let thunderMultiplier = 1 + ((thunderLevel - 1) / 10);
- let hits = parseInt(emanHealth) / (this.rcmDamagePerHit.getValue() * thunderMultiplier);
+ let hits = parseInt(emanHealth) / (parseFloat(this.rcmDamagePerHit.getValue()) * thunderMultiplier);
emanText += ` &c${Math.max(0, Math.floor(hits - 0.75))} Hits`
}