Back

P-Note

DISCLAIMER: This page is incomplete and research is unfinished. Please contact Nivrad00#3724 on Discord with any questions.

A p-note is a long note with an ending timestamp that is earlier than the starting timestamp. P-notes cause a number of glitches that can be exploited to create gimmick maps. Notably, p-notes used to be the only known method of creating fake notes, before NaN notes were discovered.

This page is maintained by Nivrad00 and is based on work by Nivrad00, NovaSagittari, Davvy, Agka, and other members of the osu!mania Research Lab Discord. P-notes are named after the osu! player who discovered this phenomenon, Pope Gadget.

Contents

Overview

P-notes in the editor

When playing a map, p-notes will render as two separate entities: an LN tail at the ending timestamp, followed by an LN head at the starting timestamp. There is no visible LN body. These two entities are called the p-note tail and p-note head respectively. Note that the tail comes before the head!

There are various types of p-notes, each of which has different qualities, but there are a few commonalities. All p-note ends act like fakes, or notes that cannot be hit or missed and have no effect on the combo or score. Autoplay will ignore p-note ends completely, but it will try to hit p-note starts and then hold down the key until the next note in the lane, which it will miss. In a multiplayer lobby, p-notes have been observed to cause the map to end immediately.

Editor Behavior

In the editor, p-notes render only if both the head and the tail appear within the editor's view. An LN body will actually be rendered, beginning at the p-note head and extending upward. However, this LN body is not present when playing the map.

The position of the p-note can be adjusted by dragging or copy-pasting the head, but the tail length cannot be adjusted except when the p-note tail automatically snaps after being dragged. P-notes can be created and edited by changing the timestamps in the .osu file. Unlike some other types of glitched notes (eg. notes with negative timestamps), p-notes will usually not disappear upon entering the editor or saving.

Types of P-notes

P-note behavior can be categorized into these types:

Mini p-notes
These p-notes are short enough that the judgement windows of the head and tail overlap. That means mini p-notes can be hit almost like short LNs, by tapping the head and immediately releasing.
Bomb p-notes
The head of a bomb p-note always yields a miss, even if you press the key correctly.
Fake p-notes
The head of a fake p-note can't be hit or missed, and it has no effect on score or combo. For this type of p-note, heads and tails are effectively identical in behavior. This type of p-note can also corrupt surrounding notes.
Auto p-notes
These p-notes will always yield an accuracy judgement, somewhere between 50 and 300, even if you don't press any keys. This happens when the timestamp of the p-note tail is very close to 0 ms. This behavior is equivalent to an LN auto-hit, so it isn't unique to p-notes.
End-of-map p-notes
If a p-note head is the last object in a map, the map will start fading out before the p-note can reach the judgement bar, possibly resulting in it never crossing the judgement bar. This may be because osu! looks at the position of single notes and LN tails when deciding to end the map, but not the position of LN heads.

Fake p-notes and end-of-map p-notes can cause a score calculation error at the end of the map. This will not prevent the map from ending or the score from being saved locally, but it may prevent scores from being submitted to the global leaderboard, which has been known to happen with similar glitches. We won't be able to verify this until a map with a fake p-note gets loved or ranked. This behavior has changed from earlier versions of osu!, where any fake p-note would cause the player to fail at the end of the map. Also, it is impossible to get 1,000,000 score on any map with fake p-notes.

Maps with fakes have been observed to end without a score calculation error, but the reason why is unknown. Also, there is some variability on whether a score calculation occurs if an end-of-map p-note crosses the judgement bar during the fading out period. This may be dependent on how close the p-note is to the previous, normal note.

As an aside, end-of-map p-notes can be exploited in a number of ways:

Types of Corrupted Notes

A fake p-note can cause nearby notes to exhibit glitchy behavior. These notes are called corrupted notes. This happens because fake p-notes create a corruption zone, which prevents the player from interacting with notes on any lane, whether by hitting them or missing them. See the section on the corruption zone for more info.

There are two main types of corrupted notes:

Fake notes
Like fake p-notes, fake notes can't be hit or missed.
J-notes
J-notes are notes that can be hit, but can't be late-missed.

J-notes are named after a similar phenomenon from the discontinued web game Feel the Beats, which was in turn named after FtB player Jxyden.

Tailless LNs

Tailless LNs start in the buffer zone of a long p-note and extend out of it

Tailless LNs are another type of glitchy note caused by proximity to p-notes. This is not technically a corrupted note, as this behavior is independent of the corruption zone. These are the criteria for a p-note to create a tailless LN:

An equivalent way of stating the second point is that when the p-note head reaches the judgement bar, the LN head must have passed the judgement bar, but not unloaded.

Tailless LNs act as if there is no LN tail, though the tail is still visible. If a player holds down a tailless LN to the end, the combo will stop going up, but there will be no accuracy judgement. This will happen regardless if the player correctly times the release or continues holding onto the LN. Additionally, the "holding a LN" effect will continue playing even after the LN ends, and even after the player releases the key.

Factors That Influence P-note Type

The following criteria can be used to determine what type of p-note is created. It is not known for sure which criteria take precedence over the others, but these sections have been arranged in order of descending priority to the best of our knowledge.

Position

If a p-note's tail is close to 0 ms, it is likely to become an auto p-note. Additionally, if a p-note's tail has a negative timestamp, the p-note is likely to become a fake. The specific criteria for these two situations have not been investigated.

On the other hand, if the very last object in a map is a p-note head or a group of p-note heads, the map will end before the heads reach the judgement line. In other words, osu! will take p-note tails into consideration when deciding when to end the map, but not p-note heads. The behavior of these end-of-map p-notes has not been investigated thoroughly.

If a p-note is not near the beginning or end of the map, then the position has no affect on its behavior.

Length

Unlike short p-notes, mini p-notes have head and tail judgement windows that overlap.

P-notes can be categorized by length:

Here is an equivalent definition of short and long p-notes, using the definition of the unloading thershold. The head of a short p-notes reaches the judgement bar before its tail can unload. However, the tail of a long p-notes unloads before its head reaches the judgement bar.

Due to random variation in unloading time, a p-note with a length that is within a few milliseconds of the unloading threshold may exhibit unstable behavior, acting like a short p-note in one playthrough and a long p-note in the next.

Note that there is no categorical distinction between mini and short p-notes. As you make a mini p-note longer and longer, it will gradually become more difficult to hit, as the judgement window overlap gets smaller. Eventually, it will become impossible to hit, at which point it is classified as a short p-note.

Overlapping LNs and P-notes

P-notes have been observed to exhibit unusual behavior around LNs. Sometimes, a LN that starts before the p-note head and ends after the p-note head will cause the p-note to unexpectedly become a bomb. The LN and p-note do not have to be on the same lane. This phenomenon is poorly understood and requires further investigation.

A p-note can have unexpected behavior if it is corrupted by another p-note.

Position of Other Objects

If all of the other criteria are inconclusive, then the behavior of a p-note is determined by worm theory. Loosely speaking, worm theory is an algorithm that decides whether the p-note is fake or bomb based on the relative positions of all the other objects in the map. Note that this only applies to long p-notes, since short p-notes are bombs by default. See the section on worm theory for more information.

Unloading Threshold

When an object crosses the judgement bar, it continues scrolling past the bottom of the screen for some time, then gets unloaded. The unloading threshold is, roughly, the amount of time between a note crossing the judgement bar and that note being unloaded.

Note that "unloading" in this context may not necessary correlate with the internal mechanics of osu, such as a sprite being unrendered or memory being freed up. We don't know much about why this threshold exists, or what it means internally. For now, we denote it as "unloading" for convenience.

This threshold is not a unique quality of p-notes, but it allows us to answer important questions about p-notes, such as:

While initially researching this topic, the experimental values in the first situation were offset from the observed values for the other situations by about +20 ms. It's not certain whether this is a simple offset by a constant, or whether there are more complex variables at play. Until more research is done, we are treating data from the second and third situations as the "canonical" unloading threshold.

Equation

The threshold is dependent on at least three variables:

Note that HitPosition is the vertical location of the judgement bar, and initial scroll speed is the scroll speed at the moment the map is loaded. Changing the scroll speed after loading the map does not affect the unloading threshold.

Finally, here is the equation for the threshold itself.

Unloading threshold equation

Variability

The unloading threshold is not completely consistent; the time that an object unloads can vary by a few milliseconds between playthroughs. So, when calculating the unloading threshold in your projects, you should give about ~5 ms of leeway in both directions.

The threshold is believed to be less consistent on lower framerates or frame limiting modes, and more consistent on higher framerates or frame limiting modes. This could be because objects are unloaded less regularly on lower framerates. This topic has not been investigated thoroughly.

Worm Theory

A diagram of some terms used in worm theory, as well as the corruption zone.
An example of a p-note with w = 1, B = 5, and A = 2. According to worm theory, this p-note is a bomb.

Worm theory is the final criteria for determining the type of a long p-note, as described in Factors That Influence P-note Type. Worm theory is an algorithm that uses these three variables to decide if a long p-note is a fake or a bomb:

For each of these calculations, only single notes, LN heads, and p-note heads are counted as "objects." If the object is at the same timestamp as the p-note head, then whether it's included in B or A depends on whether it comes before or after the p-note in the .osu file, respectively. P-notes are not included in their own calculations.

It is worth stressing that not every object in the buffer zone counts toward w. If the object is a fake p-note head, or if the object is also in the buffer zone of an earlier fake p-note, it does not count toward w.

Buffer Zone

The buffer zone is the section of the map immediately before the p-note head, with a length equal to the unloading threshold. When the p-note head reaches the judgement bar, objects in the buffer zone will have already crossed the judgement bar, but not unloaded yet.

Due to random variation in unloading time, placing notes very close to the the start of the buffer zone may cause the value of w to vary from playthrough to playthrough.

Diagram

This diagram can be used as a practical reference for p-note behavior, if the p-note is long and the other criteria for p-note type are inconclusive. Unfortunately, worm theory is not fully understood on a theoretical level, so only the limited range of values that has been empirically tested is presented here. However, it is known that the p-note is always fake if w = 0, and higher values of w are more likely to produce bombs than fakes.

Worm theory graphs

Note that some cells are grayed out because it's impossible for B to be less than w.

The "worms" in this graph are the reason why we call it worm theory!

Algorithm

A visual representation of the worm algorithm for w = 1. Starting with the top row of charts: If the left chart has an "f" on it, the p-note is a fake. Else, if the right chart has a "b" on it, the p-note is a bomb. Else, go to the next row and try again.

The algorithm for worm theory is not fully understood yet, and parts of it are likely incorrect. However, here is the most up-to-date hypothesis.

Worms can be sorted by generation, represented by the variable n. There are an infinite number of generations, starting from generation 0 and increasing from there. Each generation has 2^n worms in it.

Each worm is defined by a worm equation, a relation between A and B that also depends on n. The precise formula is unknown, but below is an approximation that is accurate for small values of A and B:

Worm equations

Note that when n = 0, both formulas above are identical.

In addition to the worm equation, each worm also has a bomb zone inequality, which is dependent on w as well as A and B.

Worm bomb zone equations

On the graph of A vs. B, the bomb zone is an area surrounding each worm within an approximate radius of w. Roughly speaking, bomb zones are where bombs are found.

Finally, here is the algorithm that determines if a long p-note is a fake or a bomb.

  1. Let n = 0
  2. Repeat the following:
    1. If the worm equation of any worm in generation n is fulfilled, the p-note is a fake
    2. Else, if the bomb zone inequality of any worm in generation n is fulfilled, the p-note is a bomb
    3. Else, increment n by 1 and repeat

Ongoing Research

The reason why the equations given above are only approximations is because of the "wiggly worm" phenomenon. For small values of A and B, the worms seem to follow a linear path. However, at higher values, the worms start to diverge slightly. The overall direction of the worms is still linear, but they do not follow the line as closely as possible. That is, the worms are wiggly. This needs further investigation.

The bomb zone concept is the latest attempt to explain the "worm social distancing" phenomenon, or the fact that no worms visibly touch each other in the graph of A vs. B. Furthermore, the amount of distance between the worms is proportional to w. According to the bomb zone hypothesis, this is because parts of higher-generation worms are hidden beneath the bomb zones of lower-generation worms. However, this hypothesis, and worm behavior for higher values of w, hasn't been investigated thoroughly. It has also been suggested that the graphs for w = 1, w = 2, and w = 3 look like they are "zooming in" on the same graph.

Graphing A vs. T and B vs. T yield somewhat more normal looking graphs, but they are not as practical to use as the graph of A vs B.

Corruption Zone

A diagram of the corruption zone, along with some terms from worm theory.

Fake p-notes create a corruption zone which prevents the player from interacting with notes on any lane, whether by hitting them or missing them. It's not known for sure if all fake p-notes exhibit this behavior, or only some of them.

The corruption zone starts APPROXIMATELY at the time the p-note tail unloads, and ends at the time the p-note head crosses the judgement line. In other words, there is a section of the map called the corruption buffer (not to be confused with the buffer zone) that starts immediately after the p-note tail, and has a size APPROXIMATELY equal to the unloading threshold. Then, the corruption zone is the section of the map between the end of the corruption buffer and the p-note head.

(As mentioned in the section on the unloading threshold, the size of the corruption buffer is actually slightly different from the unloading threshold, but the specific relationship is unknown.)

The presence of long notes in the map, particularly ones that are very long, has been observed to affect the size of the corruption zone. This has not been investigated yet, but it suggests our current understanding of the corruption zone, or the unloading threshold, is incomplete.

Corrupted Notes

A corrupted note's behavior is determined by how much of the judgement window overlaps with the corruption zone. Here, A is a normal note, B is a j-note, and C is a fake.

A note that falls in or near the corruption zone can become a corrupted note. There are two types of corrupted notes: fakes and j-notes (notes that can be hit but not late-missed).

This is how the behavior of a corrupted note is determined:

  1. If the note is after the p-note head, it will be a normal, non-corrupted note
  2. If the note is before the p-note head...
    1. ...and the start of its judgement window is AFTER the start of the corruption zone, it will be a fake
    2. ...and the start of its judgement window is BEFORE the start of the corruption zone, but the end of its judgement window is AFTER the start of the corruption zone, it will be a j-note
    3. ...and the end of its judgement window is BEFORE the start of the corruption zone, it will be a normal, non-corrupted note

J-notes have slightly variable behavior, depending on how much of its judgement window overlaps with the corruption zone. Specifically, the player can hit j-notes up until the start of the corruption zone; then they will be unable to interact with the j-note, whether by hitting or missing.

Here are a few examples.

Note that it is not possible to create a "reverse j-note" by putting a note near the end of the corruption zone; it will just be a fake. Also, due to random variation in unloading time, notes at the very boundary of the corruption zone can can exhibit different behavior from playthrough to playthrough.