.osu
is a human-readable file format containing information about a beatmap.
The first line of the file specifies the file format version. For example, osu file format v14
is the latest version.
The following content is separated into sections, indicated by section titles in square brackets.
Section | Description | Content type |
---|---|---|
[General] |
General information about the beatmap | key: value pairs |
[Editor] |
Saved settings for the beatmap editor | key: value pairs |
[Metadata] |
Information used to identify the beatmap | key:value pairs |
[Difficulty] |
Difficulty settings | key:value pairs |
[Events] |
Beatmap and storyboard graphic events | Comma-separated lists |
[TimingPoints] |
Timing and control points | Comma-separated lists |
[Colours] |
Combo and skin colours | key : value pairs |
[HitObjects] |
Hit objects | Comma-separated lists |
Option | Value type | Description | Default value |
---|---|---|---|
AudioFilename |
String | Location of the audio file relative to the current folder | |
AudioLeadIn |
Integer | Milliseconds of silence before the audio starts playing | 0 |
AudioHash |
String | Deprecated | |
PreviewTime |
Integer | Time in milliseconds when the audio preview should start | -1 |
Countdown |
Integer | Speed of the countdown before the first hit object (0 = no countdown, 1 = normal, 2 = half, 3 = double) |
1 |
SampleSet |
String | Sample set that will be used if timing points do not override it (Normal , Soft , Drum ) |
Normal |
StackLeniency |
Decimal | Multiplier for the threshold in time where hit objects placed close together stack (0–1) | 0.7 |
Mode |
Integer | Game mode (0 = osu!, 1 = osu!taiko, 2 = osu!catch, 3 = osu!mania) |
0 |
LetterboxInBreaks |
0 or 1 | Whether or not breaks have a letterboxing effect | 0 |
StoryFireInFront |
0 or 1 | Deprecated | 1 |
UseSkinSprites |
0 or 1 | Whether or not the storyboard can use the user's skin images | 0 |
AlwaysShowPlayfield |
0 or 1 | Deprecated | 0 |
OverlayPosition |
String | Draw order of hit circle overlays compared to hit numbers (NoChange = use skin setting, Below = draw overlays under numbers, Above = draw overlays on top of numbers) |
NoChange |
SkinPreference |
String | Preferred skin to use during gameplay | |
EpilepsyWarning |
0 or 1 | Whether or not a warning about flashing colours should be shown at the beginning of the map | 0 |
CountdownOffset |
Integer | Time in beats that the countdown starts before the first hit object | 0 |
SpecialStyle |
0 or 1 | Whether or not the "N+1" style key layout is used for osu!mania | 0 |
WidescreenStoryboard |
0 or 1 | Whether or not the storyboard allows widescreen viewing | 0 |
SamplesMatchPlaybackRate |
0 or 1 | Whether or not sound samples will change rate when playing with speed-changing mods | 0 |
These options are only relevant when opening maps in the beatmap editor. They do not affect gameplay.
Option | Value type | Description |
---|---|---|
Bookmarks |
Comma-separated list of integers | Time in milliseconds of bookmarks |
DistanceSpacing |
Decimal | Distance snap multiplier |
BeatDivisor |
Integer | Beat snap divisor |
GridSize |
Integer | Grid size |
TimelineZoom |
Decimal | Scale factor for the object timeline |
Option | Value type | Description |
---|---|---|
Title |
String | Romanised song title |
TitleUnicode |
String | Song title |
Artist |
String | Romanised song artist |
ArtistUnicode |
String | Song artist |
Creator |
String | Beatmap creator |
Version |
String | Difficulty name |
Source |
String | Original media the song was produced for |
Tags |
Space-separated list of strings | Search terms |
BeatmapID |
Integer | Difficulty ID |
BeatmapSetID |
Integer | Beatmap ID |
Option | Value type | Description |
---|---|---|
HPDrainRate |
Decimal | HP setting (0–10) |
CircleSize |
Decimal | CS setting (0–10) |
OverallDifficulty |
Decimal | OD setting (0–10) |
ApproachRate |
Decimal | AR setting (0–10) |
SliderMultiplier |
Decimal | Base slider velocity in hundreds of osu! pixels per beat |
SliderTickRate |
Decimal | Amount of slider ticks per beat |
Event syntax: eventType,startTime,eventParams
eventType
(String or Integer): Type of the event. Some events may be referred to by either a name or a number.startTime
(Integer): Start time of the event, in milliseconds from the beginning of the beatmap's audio. For events that do not use a start time, the default is 0
.eventParams
(Comma-separated list): Extra parameters specific to the event's type.Background syntax: 0,0,filename,xOffset,yOffset
filename
(String): Location of the background image relative to the beatmap directory. Double quotes are usually included surrounding the filename, but they are not required.xOffset
(Integer) and yOffset
(Integer): Offset in osu! pixels from the centre of the screen. For example, an offset of 50,100
would have the background shown 50 osu! pixels to the right and 100 osu! pixels down from the centre of the screen. If the offset is 0,0
, writing it is optional.Video syntax: Video,startTime,filename,xOffset,yOffset
Video
may be replaced by 1
.
filename
(String), xOffset
(Integer), and yOffset
(Integer) behave exactly as in backgrounds.Break syntax: 2,startTime,endTime
2
may be replaced by Break
.
endTime
(Integer): End time of the break, in milliseconds from the beginning of the beatmap's audio.For information about storyboard syntax, see Storyboard Scripting.
Storyboards can be defined in a separate optional storyboard file with the .osb
extension. External storyboards are shared between all difficulties in a beatmap.
Each beatmap may contain its own difficulty-specific storyboard, either in conjunction with the external storyboard or by itself.
Each timing point influences a specified portion of the map, commonly called a "timing section". The .osu
file format requires these to be sorted in chronological order.
Timing point syntax: time,beatLength,meter,sampleSet,sampleIndex,volume,uninherited,effects
time
(Integer): Start time of the timing section, in milliseconds from the beginning of the beatmap's audio. The end of the timing section is the next timing point's time (or never, if this is the last timing point).beatLength
(Decimal): This property has two meanings:
-50
would make all sliders in this timing section twice as fast as SliderMultiplier
.meter
(Integer): Amount of beats in a measure. Inherited timing points ignore this property.sampleSet
(Integer): Default sample set for hit objects (0 = beatmap default, 1 = normal, 2 = soft, 3 = drum).sampleIndex
(Integer): Custom sample index for hit objects. 0
indicates osu!'s default hitsounds.volume
(Integer): Volume percentage for hit objects.uninherited
(0 or 1): Whether or not the timing point is uninherited.effects
(Integer): Bit flags that give the timing point extra effects. See the effects section.Timing points have two extra effects that can be toggled using bits 0 and 3 (from least to most significant) in the effects
integer:
The rest of the bits are unused.
10000,333.33,4,0,0,100,1,1
12000,-25,4,3,0,100,0,1
The first timing point at 10 seconds is uninherited, and sets:
1 / 333.33 * 1000 * 60
)The second timing point at 12 seconds is inherited, changing the slider velocity to 4x and the sample set to drum.
All options in this section represent colours. They are comma-separated triplets of integers 0–255, representing the red, green, and blue components of the colours.
Option | Description |
---|---|
Combo# , where # is an integer |
Additive combo colours |
SliderTrackOverride |
Additive slider track colour |
SliderBorder |
Slider border colour |
Hit object syntax: x,y,time,type,hitSound,objectParams,hitSample
time
(Integer): Time when the object is to be hit, in milliseconds from the beginning of the beatmap's audio.type
(Integer): Bit flags indicating the type of the object. See the type section.hitSound
(Integer): Bit flags indicating the hitsound applied to the object. See the hitsound section.objectParams
(Comma-separated list): Extra parameters specific to the object's type.hitSample
(Colon-separated list): Information about which samples are played when the object is hit. It is closely related to hitSound
; see the hitsounds section. If it is not written, it defaults to 0:0:0:0:
.The hit object's type parameter is an 8-bit integer where each bit is a flag with special meaning.
Bit index | Meaning |
---|---|
0 | Marks the object as a hit circle |
1 | Marks the object as a slider |
2 | Marks the start of a new combo |
3 | Marks the object as a spinner |
4, 5, 6 | A 3-bit integer specifying how many combo colours to skip, a practice referred to as "colour hax". Only relevant if the object starts a new combo. |
7 | Marks the object as an osu!mania hold note. |
The hitSound
bit flags determine which sounds will play when the object is hit:
Bit index | Meaning |
---|---|
0 | Normal |
1 | Whistle |
2 | Finish |
3 | Clap |
If no bits are set, the normal hitsound is used by default.
In every mode except osu!mania, the LayeredHitSounds
skin property forces the normal sound to be included regardless of bit 0's setting. It is enabled by default.
Usage of hitSample
can further customise the sounds that play. It defaults to 0:0:0:0:
if it is not written.
Hit sample syntax: normalSet:additionSet:index:volume:filename
normalSet
(Integer): Sample set of the normal sound.additionSet
(Integer): Sample set of the whistle, finish, and clap sounds.index
(Integer): Index of the sample. If this is 0
, the timing point's sample index will be used instead.volume
(Integer): Volume of the sample from 1 to 100. If this is 0
, the timing point's volume will be used instead.filename
(String): Custom filename of the addition sound.normalSet
and additionSet
can be any of the following:
0
: No custom sample set
1
: Normal set2
: Soft set3
: Drum setAll of these options (besides volume) are used to determine which sound file to play for a given hitsound. The filename is <sampleSet>-hit<hitSound><index>.wav
, where:
sampleSet
is normal
, soft
, or drum
, determined by either normalSet
or additionSet
depending on which hitsound is playinghitSound
is normal
, whistle
, finish
, or clap
index
is the same index
as above, except it is not written if the value is 0
or 1
The sound file is loaded from the first of the following directories that contains a matching filename:
index
is not 0
index
removedindex
removedWhen filename
is given, no addition sounds will be played, and this file in the beatmap directory is played instead.
Hit circles do not have additional objectParams
.
Slider syntax: x,y,time,type,hitSound,curveType|curvePoints,slides,length,edgeSounds,edgeSets,hitSample
curveType
(Character): Type of curve used to construct this slider (B
= bézier, C
= centripetal catmull-rom, L
= linear, P
= perfect circle)curvePoints
(Pipe-separated list of strings): Anchor points used to construct the slider. Each point is in the format x:y
.slides
(Integer): Amount of times the player has to follow the slider's curve back-and-forth before the slider is complete. It can also be interpreted as the repeat count plus one.length
(Decimal): Visual length in osu! pixels of the slider.edgeSounds
(Pipe-separated list of integers): Hitsounds that play when hitting edges of the slider's curve. The first sound is the one that plays when the slider is first clicked, and the last sound is the one that plays when the slider's end is hit.edgeSets
(Pipe-separated list of strings): Sample sets used for the edgeSounds
. Each set is in the format normalSet:additionSet
, with the same meaning as in the hitsounds section.When constructing curves for a slider, x
and y
are used for the first point, and curvePoints
supply the rest.
There are four types of slider curves in osu!:
If the slider's length
is longer than the defined curve, the slider will extend in a straight line from the end of the curve until it reaches the target length.
Notice: The slider's length
can be used to determine the time it takes to complete the slider. length / (SliderMultiplier * 100 * SV) * beatLength
tells how many milliseconds it takes to complete one slide of the slider (where SV
is the slider velocity multiplier given by the effective inherited timing point, or 1
if there is none).
Apart from edge hitsounds, sliders also have an ongoing hitsound whenever the player is in range of the slider's follow circle. The sound file is looped for as long as it is active.
This hitsound uses the hit object's hitSound
and hitSample
properties, but only the normal and whistle sounds are supported. Its filename is <sampleSet>-slider<hitSound><index>.wav
, where hitSound
is either slide
for normal or whistle
for whistle.
Spinner syntax: x,y,time,type,hitSound,endTime,hitSample
endTime
(Integer): End time of the spinner, in milliseconds from the beginning of the beatmap's audio.x
and y
do not affect spinners. They default to the centre of the playfield, 256,192
.Hold syntax: x,y,time,type,hitSound,endTime:hitSample
endTime
(Integer): End time of the hold, in milliseconds from the beginning of the beatmap's audio.x
determines the index of the column that the hold will be in. It is computed by floor(x * columnCount / 512)
and clamped between 0
and columnCount - 1
.y
does not affect holds. It defaults to the centre of the playfield, 192
.256,192,11000,21,2
256,192,11200,8,12,12000,3:0:0:80:
100,100,12600,6,1,B|200:200|250:200|250:200|300:150,2,310.123,2|1|2,0:0|0:0|0:2,0:0:0:0:
The first object is a hit circle:
The second object is a spinner:
The third object is a slider:
osu!taiko's hit objects only use time
to determine how they are placed on the play field, so x
and y
are ignored. Likewise, the only significant part of slider curves is length
; curveType
and curvePoints
are only relevant when opening the map in the editor. Combo colours and new combos are ignored, and mode-specific hitsounds are used.
osu!catch's play field only uses the x-axis, so y
is not relevant. Slider curves may utilise vertical space to achieve horizontal acceleration when they are flattened to a one-dimensional play field.
Similarly to osu!catch, osu!mania hit objects do not use y
. x
is used to determine the column; see the Holds section.