PICO-8 sfx()/music(): generic placeholder tone bank

A Vircon32-assembly targeting lua compiler

PICO-8 sfx()/music(): generic placeholder tone bank

Superseded when cart data is available. A .p8 compiled directly, or a .lua with --#p8 "cart.p8", now plays the cart’s own __sfx__/__music__ (SFX synthesized at compile time, music sequenced from them at run time) — see “Sound” in PICO8.md. This placeholder bank is only used when no such data exists (plain --#api pico8), and by the TIC-80 layer. A looped placeholder tone is what made music() sound like the same short sound repeating.

Problem

celeste.lua (and any stripped .lua export of a PICO-8 cart, as opposed to a full .p8 file) carries none of the original __music__/__sfx__ tracker data. There is no asset data to play back faithfully, at all.

Approach (per Matthew’s suggestion)

Since both consoles’ audio is closer to a tone generator than a tracker, PICO-8’s sfx()/music() don’t try to reproduce the original cart – they select from a small bank of generic placeholder tones instead:

sfx(n [, channel[, offset[, length]]])

music(n [, fade_len[, channel_mask]])

Known limitations

TIC-80

TIC-80’s sfx()/music() (previously empty stubs) now use the same bank: