abraker wrote:
double intervalScaled = 1.0 / pow(longestStream.interval, pow(longestStream.interval, GetVar("Tenacity", "IntervalPow")) * GetVar("Tenacity", "IntervalMult")) * GetVar("Tenacity", "IntervalMult2");
double lengthScaled = pow(GetVar("Tenacity", "LengthDivisor") / longestStream.length, GetVar("Tenacity", "LengthDivisor") / longestStream.length * GetVar("Tenacity", "LengthMult"));
double tenacity = intervalScaled * lengthScaled;
beatmap.skills.tenacity = tenacity;
beatmap.skills.tenacity = GetVar("Tenacity", "TotalMult") * pow(beatmap.skills.tenacity, GetVar("Tenacity", "TotalPow"));
return beatmap.skills.tenacity;
So first I took the code and simplified it to something that is can be better understood:
_IScaled = X_IntervalMult2 / (M_longestStreamI ^ (M_longestStreamI ^ X_IntervalPow) * X_IntervalMult);
_LScaled = (X_LengthDivisor / M_longestStreamL) ^ (X_LengthDivisor / M_longestStreamL * X_LengthMult);
S_tenacity = X_TotalMult * (_IScaled * _LScaled) ^ X_totalPow;
Notice the prefixes. They help with knowing where the values are coming from. "_" prefix are local variables. "M_" prefix come from the map. "X_" prefix are free variables. "S_" prefix are final skill values.
The desmos link you provided is kinda of a mess, so I redid it: https://www.desmos.com/calculator/kbgnn5wlhr
Finally, it's hard to know what values are reasonable for the free variables. There is already an existing offline calculator kert made that shows default values for these free variables:
I do find it weird that skill values decreases as you add more length to it. I am not sure what's up with that. I don't feel like spending a better part of my day launching the skill calc in VS Studio to figure that one out right now.
Thanks for the help, and if you're still interested, I tried changing the M_ values and it looks like it also decreases tenacity when length and interval increase at the same time as well, while if you set them both to a low number like 3 you get a tenacity value of 3315 when in reality its just clicking 3 circles in 3 seconds...
I did the something similar (but with increased length and interval) for a map that only has streams with the skill calculator, but the results were different and a bit more accurate there.
(1440 notes of only streams on 180 bpm for ~120 seconds.)
GUI result:
Graph result:
The equation in the code for interval was
1.0 / pow(longestStream.interval, pow(longestStream.interval, GetVar("Tenacity", "IntervalPow")) * GetVar("Tenacity", "IntervalMult")) * GetVar("Tenacity", "IntervalMult2");
but i saw you replaced the "1.0" with "X_IntervalMult2", (which looks a lot better than 1.0), and since all of these versions of the code are making completely different results do you think this means that the code in the open source version for tenacity is incorrect? It looks like the website and offline calculator scales the values for tenacity correctly.
I think I found some of the problem, I_Scaled had the length of the stream instead of the interval in its equation, so now the skill value increases when you add more length.
When you increase the interval, the graph looks like this:
I was thinking that it would trade off into stamina, except I realized in this case something like a burst that has 8 circles in 1 interval gives you a tenacity value of 4961.