# Format Info

East Coast Stamina 6 is split into two portions: a 56 minute marathon that each competitor gets a 20 minute warmup for,
and a timed set where players are allotted an amount of time based on their qualifier performance to try to pass as many of the
hardest songs that they can from a list of 100 charts ranging in (equivalent 16th) speed from 170 to 250 and difficulties from
16 to 23.

The length of the timed set is calculated using this formula:

55 + ((Sub170Skill + 170Skill + 180Skill + 190Skill + 200Skill) * (15 / 495))

So the range of set lengths can be from 55 minutes (if the player only has a skill of 1 for each of those from the qualifiers)
to 70 minutes (if they 99'd all five skills).

In both portions of the tournament, your objective is to accrue HP (Haul Points) and MP (Mastery Points); your
rank at the end is determined by the total HP and MP you've gained from both the marathon and the timed set.
Every song in the tournament (including the marathon) is worth a base amount of HP and MP that you gain under certain conditions
as you play.

# Mastery Points

MP calculation is simpler, so we'll start with that. Each song has a "Difficulty Level" and a "Speed Level".
The Difficulty Level is calculated as follows:

ChartDifficulty - 15

...and the Speed Level is calculated like this:

(ChartBPM/10) - 16

Note that for the purposes of this tournament, before subtracting 16, we round down whatever the ChartBPM/10 ends up being.
So, as an example, for Promethium, the BPM is 200 and the difficulty rating is 16, so you end up with a Difficulty Level of 1 (16 - 1)
and a Speed Level of 4 ((200 / 10) - 16). All you actually need to calculate the base MP value of a chart is the Difficulty Level, though,
which is handled like so:

(DiffcultyLevel * 50)^1.2

...which works out to mean that the lowest MP value for a song is 109, for 16s, and the highest is 1325, for 23s. What's worth
noting at this point (which you may have realized already) is that score does not have any impact on MP. However, the conditions
in which you actually gain MP are more restrictive (though slightly less complicated) than they are with HP. The requirements are:

- You must pass the song.
- Only the highest MP value of ANY song at a given Speed Level counts towards your total MP.

# Haul Points

The largest portion of each player's points will likely be coming from the HP they gain from the songs they play.
The base HP of each chart (including the marathon) is calculated like so:

(ChartMeasuresOf16ths^1.25) * ((((ChartBPM - 170) / (250 - 170)) * .7) + 1)

...and what this basically means is that you can have a BPM multiplier anywhere from 1 (if the song is 170 BPM) to 1.7 (at 250),
which is then applied against the total measures of 16th stream in the chart. Note that the small exponent on the ChartMeasuresOf16ths
means that the value of each individual measure of stream in the chart increases as the total number of measures increases (so it's better to do
one song with 300 measures of stream versus doing two songs with 150-- at least in terms of the HP yield, assuming they're the same BPM).

Once you know the base HP, in the marathon, you determine the actual HP yielded from the chart by using the following formula:

ChartBaseHP * MarathonScore

...but things get more complicated for the timed set. There are different ways your HP yield during the timed set can be
determined:

- You fail a song that has a length lower than your Fail Threshold for the song's Speed Level.
- You fail a song that has a length higher than your Fail Threshold for the song's Speed Level.
- You pass with below a 60%.
- You pass with 60% or above.

10 - ((10 - AverageLengthForSpeedLevel) * (SkillForSpeedLevel / 100))

...with a very slight bonus if you 99'd the skill:

9.25 - ((10 - AverageLengthForSpeedLevel) * (SkillForSpeedLevel / 100))

So, now that we've established what Fail Thresholds are, we can go into some of the different calculations for HP.

"You fail a song that has a length lower than your Fail Threshold for the song's Speed Level." -- this scenario is calculated as:

0

"You fail a song that has a length higher than your Fail Threshold for the song's Speed Level." -- this scenario is calculated as:

ChartBaseHP * SongScore^2.5

"You pass with below a 60%." -- this scenario is calculated as:

ChartBaseHP * .7

"You pass with 60% or above." -- this scenario is calculated as:

ChartBaseHP * ((((SongScore - .6) / .4) * .3) + .7)

So, you do get some HP if you fail a song with a length higher than your Fail Threshold for the Speed Level, and it approaches (but never matches) the HP you get from passing as your score gets higher. If you fail something with a shorter length than the respective threshold for that Speed Level, you don't get any HP, though-- and it's worth noting again here that you don't get any MP if you fail, period. As long as you pass, though, you're guaranteed to earn a minimum of 70% of the HP possible for that song, and more as your score increases above 60%.