This document defines formal behavioral expectations for difficulty models based on transitions and note timing in FlashFlashRevolution (FFR).
An FFR level, or chart, is essentially a collection of timed inputs that the player must hit with a certain degree of timing precision in order to maximize their score.
FFR's rhythm game genre is called "4-key", where the inputs are limited to 4 different key bindings on the keyboard. The most common way of playing 4-key, when looking to maximize score, is called spread, where the 4 key bindings are played by a separate finger and each hand uses 2 fingers. The key bindings are generally setup in a row-like arrangement, such as "ASKL" or "WEOP".
This document will assume that style of play as it has stood the test of time in being the only style that allows getting anywhere near the best of scores, and is generally the most ergonomic approach to the game. There are some exceptions to that, but the other styles tend to only have better ergonomy in very particular edge cases that would rarely ever be considered easier on entire charts than spread.
Let's define some core concepts in order to be able to formalize the meaning of "difficulty" in FFR.
Let the following be a chart made of
A hit
-
$m \in [0, \infin]$ is the millisecond timing of the hit relative to the start of the song. -
$h \in {1, 2}$ denotes the hand used to perform the input for the hit where:-
$1$ : left hand hit; -
$2$ : right hand hit.
-
-
$r \in {1, 2, 3}$ denotes the finger(s) representation of a hit where:-
$1$ : single on left finger only; -
$2$ : single on right finger only; -
$3$ : jump (i.e., both fingers pressed simultaneously).
-
Let the following be selectors for the different values of a hit:
For robustness sake, let's constrain that definition to not contain any set of hits that share the same
This will ensure that the charts are valid and don't have anomalous features, even though such invalid charts are technically possible to create for the game; there's no benefit to considering them in this document.
We will also make the trivial assumption, for simplicity, that the hits are ordered by time:
Now since some elements defined below are based on the relationship between two consecutive hits, let's denote the set of "all hits in a chart except the last hit" as follows for simplicity:
This hit-based definition of a chart is not the only one; there are other representations that allow different mathematical manipulations. One particularly helpful result of this definition is that it allows for easier representation of same-hand elements, which can be isolated from both-hands elements. This is especially practical for evaluating spread-specific ergonomy, as each hand has a certain degree of independence while the 2 fingers on a given hand are much less independent mechanically. A hit being represented as
Another chart representation that will also be useful is the following:
This representation denotes a chart
-
$m \in [0, \infin]$ is the millisecond timing of the note relative to the start of the song. This is identical to the$m$ value of a hit. -
$l \in {1, 2, 3, 4}$ denotes the lane of the note. More visually, each value represents a finger in a spread playstyle setup from left to right. As an example, with key bindings "ASKL",$1$ would be "A",$2$ would be "S",$3$ would be "K" and$4$ would be "L".
Again, let's define selectors for these values:
The chart validity constraint of this form is more straightforward:
While the hit-based representation is particularly helpful for formalizing concepts that are more centered around ergonomy of play, this note-based one will be helpful for concepts that are more related to the game's specific mechanics.
To ensure that all definitions derived from either representation is applicable to the other, there needs to be a formal mapping between the two.
Let's first define special selectors of a note that return elements of a hit:
Then, the selectors of a hit that return elements of a note:
Using all these selectors, let's now define mappings of hits to notes and vice versa.
The mapping from hits to notes can result in either one or two notes depending on if the finger type of the hit is a single (
The opposite mapping however (from notes to hits) is slightly less straightforward due to the possibility of having to merge pairs of notes that would result in a singular jump hit.
Let the following set
This grouping of notes completely partitions the chart, so whatever action is taken over all such partitions of a given chart is guaranteed to cover all notes too. More formally:
Then, there needs to be a way to transform a single partition of notes into one or more hits. The mapping below does that:
With all of that, it becomes possible to map all partitions to hits, merging notes where needed. Let's define the function
With the transformer functions defined above, there is a complete bidirectional mapping. This mapping can be written as such:
The step-by-step proof of this mapping relies on the defined chart constraints and would be somewhat lengthy, so it is left out to keep things more concise.
We can now define some important same-hand elements in order to facilitate the formalizing of features that pertain to only the sequence of hits on a given hand.
Let the following be the subset of all hits in a chart that are on the hand
Let the following be the gap value
Note that the gap value of the last hit on a given hand is set to
This element is very important because the time between two hits on a given hand is an intuitive and logical major contributor to perceived difficulty. Generally, although not always, a sequence of hits is perceived as more difficult as the
Next, let's define the "type" of transition between two consecutive same-hand hits as the following:
Again, note that the transition value for the last hit is set at
This element allows to factor in the different ways a hand can move when transitioning from one hit to the next. It is a widely accepted fact that each type of transition has different implications regarding perceived difficulty, although the exact shape and values for these implications are unknown and not necessarily unanimously agreed upon.
Here's what each transition value means in words:
-
$0$ : single → single (different finger)- This is commonly refered to as a trill motion.*
-
$1$ : single → single (same finger)- This is commonly refered to as a jack motion.**
-
$2$ : left single → jump -
$3$ : right single → jump- These can be categorized as a jack-like motions (which
$t=1$ also is), and are generally considered to be the least ergonomic motion in spread style.
- These can be categorized as a jack-like motions (which
-
$4$ : jump → left single -
$5$ : jump → right single- These can be also categorized as a jack-like motions, and are generally considered to be just slightly more ergonomic than their opposite counterparts
$2$ and$3$ .
- These can be also categorized as a jack-like motions, and are generally considered to be just slightly more ergonomic than their opposite counterparts
-
$6$ : jump → jump- This is commonly refered to as a jumpjack motion, which is another jack-like motion.
Note that:
* The word "trill" is slightly overloaded there, as it is generally known to mean multiple such transitions in a row. For now, let's just allow a single such transition to also be labeled that way. More specific contextual terminology will be introduced later if necessary.
** Similarly, "jack" is generally known to mean multiple such transitions. Let's accept a singular one to also be labeled that way.
It is essential to formally define FFR's scoring system so that we can relate the difficulty concepts to the players' goal during gameplay. Nowadays, and for many years now, that scoring system has been an accuracy based one where the players attempt to get a "AAA" or as close to it as they can.
The "
There are a lot of high level concepts that people naturally refer to when discussing the difficulty of a chart or a section of a chart, or when comparing multiple of those together. The goal here is simply to define basic aspects relating to difficulty, which will be useful when exploring those high level concepts later on.
Let the following denote an unknown function that outputs a single positive real number
The shape of this difficulty function is likely very complicated and probably contains a fair amount of hyperparameters that would attempt to reflect the intricacies of the various human biomechanical aspects of the spread playstyle. Such hyperparameters aren't the focus of this document, however it's good to keep in mind that they're somewhat at the root of a lot of debates over how different aspects of difficulty interact together mathematically and intuitively.
Over the years, there have been many lengthy discussions and debates over how to approach the automatic computation of a chart's difficulty. Due to the lack of extensive tooling and proper formalization of the problem, most of these debates would end in a dead end; the intricacies are simply too complex to discuss just in a casual conversation without eventually having inconsistent statements.
In order to build a foundation for those debates in a more formal setting, this section introduces some axioms that should always hold regardless of the approach taken to implement a difficulty calculator. These axioms are based on concepts that are considered as universally true and agreed upon by essentially any knowledgeable player.
For any chart consisting of a sequence of hits all on the same hand, with identical gap
That is, shorter gaps are always more difficult for constant jack-like motion patterns.
Let
For any chart consisting of a sequence of alternating singles, so constant transition type
That is, as alternating notes approach the manipulation threshold of 100ms, the difficulty increases. As they move further apart, the difficulty decreases.
Let
For any chart consisting of a sequence of a single transition type (or a consistent alternating motion such as
That is, longer repetitive motions (e.g., 20-note jacks) are always more difficult than shorter ones (e.g., 10-note jacks), assuming the motion type and gap are the same.
Let
Note that the increase in difficulty may saturate:
This captures the idea that while difficulty increases with repetition, the rate of increase may diminish over time.