Skip to content

hud

Everything that isn't the notes: the score line, the song's title and time, the hearts of a fight, the cinematic bars - plus the angle and offset of the whole playfield. Fade it out for a quiet moment, tilt it for a drop, move single pieces out of the way of your stage art.

How to use it

hud is always there. The whole HUD: alpha, angle, x, y. One piece: scoreX ... healthScale, each moved and sized around its own middle.

Shortcuts: hideHud / showHud. The rating popups are judgments, the strip behind the lanes is the underlay.

Psych: camHUD.alpha, camHUD.angle, scoreTxt.visible, skipCountdown · Kade: camHudAngle, showOnlyStrums

Example code

-- A tilted HUD for a section, the score line moved to the top left and bigger.
tween(hud.angle, 8, beats(2), "backOut")
hud.scoreX = -260
hud.scoreY = -200
hud.scoreScale = 1.4
after(beats(16), function() reset(hud, beats(1), "sineInOut") end)

Properties

Property Kind Default
hud.angle number 0 The whole playfield turned, in degrees (clockwise). In fights the world camera rolls with …
hud.alpha number 1 The whole HUD's opacity: score line, title, hearts.
hud.extras switch true Whether the puppets, the opponent's receptors and the judgments turn along with …
hud.countdown switch true Whether the song's start shows the 3-2-1-GO and plays its sounds. false = the music …
hud.x number 0 The whole playfield moved to the right, in pixels.
hud.y number 0 The whole playfield moved down, in pixels.
hud.scoreAlpha number 1 Only the score line's opacity.
hud.titleAlpha number 1 Only the song title's and the time's opacity.
hud.healthAlpha number 1 Only the hearts' opacity (fights).
hud.scoreX number 0 The score line moved to the right, in pixels - on top of hud.x.
hud.scoreY number 0 The score line moved down, in pixels.
hud.scoreScale number 1 The score line's size, around its own middle. 0 = gone.
hud.titleX number 0 The title line moved to the right, in pixels.
hud.titleY number 0 The title line moved down, in pixels.
hud.titleScale number 1 The title line's size, around its own middle.
hud.healthX number 0 The hearts moved to the right, in pixels.
hud.healthY number 0 The hearts moved down, in pixels.
hud.healthScale number 1 The hearts' size, around their own middle.
hud.bars number 1 The black cinematic bars of a fight: 0 = gone, 1 = as usual, 2 = twice as high. Practice …

hud.angle

number hud.angle = 0

degrees

The whole playfield turned, in degrees (clockwise). In fights the world camera rolls with it.

hud.alpha

number hud.alpha = 1

0 – 1share of the screen

The whole HUD's opacity: score line, title, hearts.

hud.extras

switch hud.extras = true

kept at the song's end

Whether the puppets, the opponent's receptors and the judgments turn along with hud.angle. false = only your lanes turn.

hud.countdown

switch hud.countdown = true

Whether the song's start shows the 3-2-1-GO and plays its sounds. false = the music starts without it - onCountdown is still called, so a script can show its own.

Note

Set it in onStart - the countdown starts right after.

function onStart()
    hud.countdown = false
end

hud.x

number hud.x = 0

The whole playfield moved to the right, in pixels.

hud.y

number hud.y = 0

The whole playfield moved down, in pixels.

hud.scoreAlpha

number hud.scoreAlpha = 1

0 – 1share of the screen

Only the score line's opacity.

hud.titleAlpha

number hud.titleAlpha = 1

0 – 1share of the screen

Only the song title's and the time's opacity.

hud.healthAlpha

number hud.healthAlpha = 1

0 – 1share of the screen

Only the hearts' opacity (fights).

hud.scoreX

number hud.scoreX = 0

The score line moved to the right, in pixels - on top of hud.x.

hud.scoreY

number hud.scoreY = 0

The score line moved down, in pixels.

hud.scoreScale

number hud.scoreScale = 1

0 – 10

The score line's size, around its own middle. 0 = gone.

hud.titleX

number hud.titleX = 0

The title line moved to the right, in pixels.

hud.titleY

number hud.titleY = 0

The title line moved down, in pixels.

hud.titleScale

number hud.titleScale = 1

0 – 10

The title line's size, around its own middle.

hud.healthX

number hud.healthX = 0

The hearts moved to the right, in pixels.

hud.healthY

number hud.healthY = 0

The hearts moved down, in pixels.

hud.healthScale

number hud.healthScale = 1

0 – 10

The hearts' size, around their own middle.

hud.bars

number hud.bars = 1

0 – 3fights only

The black cinematic bars of a fight: 0 = gone, 1 = as usual, 2 = twice as high. Practice has none.