@rian8337/osu-rebalance-difficulty-calculator 4.0.0-beta.102 → 4.0.0-beta.103
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +15 -24
- package/package.json +3 -3
- package/typings/index.d.ts +1 -0
package/dist/index.js
CHANGED
|
@@ -986,7 +986,7 @@ class DroidAim extends VariableLengthStrainSkill {
|
|
|
986
986
|
this.skillMultiplierSnap = 78.3;
|
|
987
987
|
this.skillMultiplierAgility = 32.5;
|
|
988
988
|
this.skillMultiplierFlow = 251;
|
|
989
|
-
this.skillMultiplierSpinner =
|
|
989
|
+
this.skillMultiplierSpinner = 1.8;
|
|
990
990
|
this.skillMultiplierTotal = 1.12;
|
|
991
991
|
this.combinedSnapNormExponent = 1.5;
|
|
992
992
|
/**
|
|
@@ -1074,12 +1074,8 @@ class DroidAim extends VariableLengthStrainSkill {
|
|
|
1074
1074
|
const pSnap = this.calculateSnapFlowProbability(flowDifficulty / combinedSnapDifficulty);
|
|
1075
1075
|
const pFlow = 1 - pSnap;
|
|
1076
1076
|
// Invert rating summation to obtain a more accurate TD adjustment.
|
|
1077
|
-
snapDifficulty =
|
|
1078
|
-
|
|
1079
|
-
Math.pow(snapDifficulty, 0.93);
|
|
1080
|
-
agilityDifficulty =
|
|
1081
|
-
Math.pow(0.02275 * Math.pow(10, 0.63), (0.89 - 1) / 0.63) *
|
|
1082
|
-
Math.pow(agilityDifficulty, 0.89);
|
|
1077
|
+
snapDifficulty = this.invertRatingSummation(snapDifficulty, 0.82);
|
|
1078
|
+
agilityDifficulty = this.invertRatingSummation(agilityDifficulty, 0.82);
|
|
1083
1079
|
combinedSnapDifficulty = osuBase.MathUtils.norm(this.combinedSnapNormExponent, snapDifficulty, agilityDifficulty);
|
|
1084
1080
|
if (this.mods.has(osuBase.ModRelax)) {
|
|
1085
1081
|
combinedSnapDifficulty *= 0.75;
|
|
@@ -1169,6 +1165,10 @@ class DroidAim extends VariableLengthStrainSkill {
|
|
|
1169
1165
|
strains.splice(0, strainsToRemove);
|
|
1170
1166
|
return strains.sort((a, b) => b.value - a.value);
|
|
1171
1167
|
}
|
|
1168
|
+
invertRatingSummation(rating, exponent) {
|
|
1169
|
+
return Math.pow(0.02275 * Math.pow(10, 0.63), (exponent - 1) / 0.63) *
|
|
1170
|
+
Math.pow(rating, exponent);
|
|
1171
|
+
}
|
|
1172
1172
|
strainDecay(ms) {
|
|
1173
1173
|
return Math.pow(0.2, ms / 1000);
|
|
1174
1174
|
}
|
|
@@ -1677,7 +1677,7 @@ class DroidReadingEvaluator {
|
|
|
1677
1677
|
let preemptDifficulty = Math.pow((this.preemptStartingPoint -
|
|
1678
1678
|
preempt +
|
|
1679
1679
|
Math.abs(preempt - this.preemptStartingPoint)) /
|
|
1680
|
-
2, 2.
|
|
1680
|
+
2, 2.475) / this.preemptBalancingFactor;
|
|
1681
1681
|
preemptDifficulty *= constantAngleNerfFactor * velocity;
|
|
1682
1682
|
return preemptDifficulty;
|
|
1683
1683
|
}
|
|
@@ -1957,7 +1957,7 @@ class DroidReading extends HarmonicSkill {
|
|
|
1957
1957
|
current.readingDifficulty = difficulty;
|
|
1958
1958
|
}
|
|
1959
1959
|
calculateAdjustedDifficulty(current) {
|
|
1960
|
-
let difficulty =
|
|
1960
|
+
let difficulty = DroidReadingEvaluator.evaluateDifficultyOf(current, this.mods);
|
|
1961
1961
|
if (this.mods.has(osuBase.ModRelax)) {
|
|
1962
1962
|
difficulty *= 0.4;
|
|
1963
1963
|
}
|
|
@@ -2220,10 +2220,6 @@ class DroidPerformanceCalculator extends PerformanceCalculator {
|
|
|
2220
2220
|
aimValue *= this.calculateDeviationBasedLengthScaling();
|
|
2221
2221
|
// Scale the aim value with slider cheese penalty.
|
|
2222
2222
|
aimValue *= this._sliderCheesePenalty;
|
|
2223
|
-
// Scale the aim value with deviation.
|
|
2224
|
-
aimValue *=
|
|
2225
|
-
1.025 *
|
|
2226
|
-
Math.pow(osuBase.ErrorFunction.erf(25 / (Math.SQRT2 * this._deviation)), 0.475);
|
|
2227
2223
|
return aimValue;
|
|
2228
2224
|
}
|
|
2229
2225
|
/**
|
|
@@ -2263,14 +2259,14 @@ class DroidPerformanceCalculator extends PerformanceCalculator {
|
|
|
2263
2259
|
if (this.mods.has(osuBase.ModRelax) || this.totalSuccessfulHits === 0) {
|
|
2264
2260
|
return 0;
|
|
2265
2261
|
}
|
|
2266
|
-
let accuracyValue =
|
|
2262
|
+
let accuracyValue = 725 * Math.exp(-0.1 * this._deviation);
|
|
2267
2263
|
const ncircles = this.mods.has(osuBase.ModScoreV2)
|
|
2268
2264
|
? this.totalHits - this.difficultyAttributes.spinnerCount
|
|
2269
2265
|
: this.difficultyAttributes.hitCircleCount;
|
|
2270
2266
|
// Bonus for many hitcircles - it's harder to keep good accuracy up for longer.
|
|
2271
2267
|
accuracyValue *= Math.pow(Math.log(1 + ((Math.E - 1) * ncircles) / 1000), ncircles < 1000 ? 0.5 : 0.25);
|
|
2272
2268
|
// Scale the accuracy value with rhythm complexity.
|
|
2273
|
-
accuracyValue *= osuBase.MathUtils.offsetLogistic(this.difficultyAttributes.rhythmDifficulty, 1, 0.5, 1.
|
|
2269
|
+
accuracyValue *= osuBase.MathUtils.offsetLogistic(this.difficultyAttributes.rhythmDifficulty, 1, 0.5, 1.6);
|
|
2274
2270
|
// Penalize accuracy pp after the first miss.
|
|
2275
2271
|
accuracyValue *= Math.pow(0.97, Math.max(0, this._effectiveMissCount - 1));
|
|
2276
2272
|
return accuracyValue;
|
|
@@ -2290,8 +2286,6 @@ class DroidPerformanceCalculator extends PerformanceCalculator {
|
|
|
2290
2286
|
Math.pow(1 -
|
|
2291
2287
|
Math.pow(this._effectiveMissCount / this.totalHits, 0.775), Math.pow(this._effectiveMissCount, 0.875));
|
|
2292
2288
|
}
|
|
2293
|
-
// Scale the flashlight value with deviation.
|
|
2294
|
-
flashlightValue *= osuBase.ErrorFunction.erf(50 / (Math.SQRT2 * this._deviation));
|
|
2295
2289
|
return flashlightValue;
|
|
2296
2290
|
}
|
|
2297
2291
|
/**
|
|
@@ -2306,10 +2300,6 @@ class DroidPerformanceCalculator extends PerformanceCalculator {
|
|
|
2306
2300
|
// Scale the reading value with estimated full combo deviation.
|
|
2307
2301
|
// As reading is easily "bypassable" with memorization, punish for memorization.
|
|
2308
2302
|
readingValue *= Math.min(1, this.calculateDeviationBasedLengthScaling(undefined, true));
|
|
2309
|
-
// Scale the reading value with deviation.
|
|
2310
|
-
readingValue *=
|
|
2311
|
-
1.025 *
|
|
2312
|
-
Math.pow(osuBase.ErrorFunction.erf(25 / (Math.SQRT2 * this._deviation)), 1.25);
|
|
2313
2303
|
return readingValue;
|
|
2314
2304
|
}
|
|
2315
2305
|
/**
|
|
@@ -3574,9 +3564,10 @@ class DroidScoreUtils {
|
|
|
3574
3564
|
const totalPossibleSpins = secondsDuration * maximumRotationsPerSecond;
|
|
3575
3565
|
// In osu!droid, spinner bonus points are awarded for each full rotation every nth spin after the required spins.
|
|
3576
3566
|
// For example, if a spinner requires 5.6 spins before bonus, the first bonus will be awarded at 6 spins instead
|
|
3577
|
-
// of 6.6 spins.
|
|
3567
|
+
// of 6.6 spins. Likewise, if a spinner requires exactly 6 spins, the 6th spin already awards the first bonus.
|
|
3578
3568
|
const maximumPossibleBonusSpins = Math.max(0, Math.floor(totalPossibleSpins) -
|
|
3579
|
-
Math.ceil(spinsRequiredBeforeBonus)
|
|
3569
|
+
Math.ceil(spinsRequiredBeforeBonus) +
|
|
3570
|
+
1);
|
|
3580
3571
|
bonus += maximumPossibleBonusSpins * 1000;
|
|
3581
3572
|
}
|
|
3582
3573
|
return Math.floor(Math.fround(bonus * scoreMultiplier));
|
|
@@ -4736,7 +4727,7 @@ class OsuSpinnerEvaluator {
|
|
|
4736
4727
|
}
|
|
4737
4728
|
// This duration is *not* rate scaled because spinners work by applying rates on rotations.
|
|
4738
4729
|
// This means spinning difficulty remains constant for a spinner, regardless of the applied rate.
|
|
4739
|
-
const duration = current.object.duration /
|
|
4730
|
+
const duration = current.object.duration / 1000;
|
|
4740
4731
|
const rps = current.object.spinsRequired / duration;
|
|
4741
4732
|
// The longer the spinner the more lenient spinning requirements are.
|
|
4742
4733
|
return rps / duration;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rian8337/osu-rebalance-difficulty-calculator",
|
|
3
|
-
"version": "4.0.0-beta.
|
|
3
|
+
"version": "4.0.0-beta.103",
|
|
4
4
|
"description": "A module for calculating osu!standard beatmap difficulty and performance value with respect to the latest osu!lazer difficulty and performance algorithm.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"osu",
|
|
@@ -33,10 +33,10 @@
|
|
|
33
33
|
"url": "https://github.com/Rian8337/osu-droid-module/issues"
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
|
-
"@rian8337/osu-base": "4.0.0-beta.
|
|
36
|
+
"@rian8337/osu-base": "4.0.0-beta.103"
|
|
37
37
|
},
|
|
38
38
|
"publishConfig": {
|
|
39
39
|
"access": "public"
|
|
40
40
|
},
|
|
41
|
-
"gitHead": "
|
|
41
|
+
"gitHead": "3f35122c29be5cf8a6d9ef612bfec5c93cfc2956"
|
|
42
42
|
}
|
package/typings/index.d.ts
CHANGED