Cinderfox

Music

The Music workspace (⌘4) writes a game’s music in the editor, on the sound chips of old consoles and arcades — or a synth, a drum kit, or a SoundFont — and exports it into the game as a sound file. Songs are kept in the game’s songs/ folder.

Start a song

With no song open, the workspace offers three ways in: type a name and press New song; open one of the game’s songs; or Bring in from PlayScore… to import a PlayScore track. Across the top of a song: its Name, Tempo, Metre and Key, and Play, which plays it from the playhead.

Parts

A song is parts — a bass line, a lead, a drum kit — each a lane in the arrangement. + Part adds one, choosing what plays it:

YM2151 FM, as in the arcades
YM2612 FM, as in the Mega Drive
SID the Commodore 64
SN76489 the Master System
2A03 the NES
Synth a plain synthesiser
Sampler drum kits
SoundFont General MIDI instruments

Each comes with ready-made sounds to start from. Cinderfox has a small SoundFont built in; the SoundFont menu can fetch a fuller one (GeneralUser GS, 32 MB) or add any .sf2 you have.

Writing notes

Select a part and its tabs open below:

  • Notes — a piano roll (or, for a drum kit, a grid of drums). Click to place a note, drag to move or lengthen it; velocity along the bottom is how hard each is played. How to edit lists every gesture.
  • A part plays a pattern, which can be any number of bars. New starts another, Copy makes one to vary.
  • Sound — the instrument itself: every setting the chip has, and Hear it to try it.
  • Mix — each part’s gain, pan, mute and solo, which bus it goes to, and effects (reverb, delay, compression), up to the master.

⌘Z undoes within the song, and Save (⌘S) writes it.

The song is checked as you write. Anything worth a look — a part playing notes outside the song’s key, a part with more notes at once than its chip has voices — is listed above the arrangement, by bar.

Into the game

Export audio… renders the song with the same engine Play uses and writes it where the game reads sounds:

  • As Ogg Vorbis (small, for the game) or WAV.
  • Of a loop, which plays seamlessly round and round as background music, or the whole song. Bars says which.
  • Listen plays the result before you write it.

Then play it from a script like any sound:

audio.play("theme", { loop = true, bus = "music" })

The assistant writes music too

The Assistant can read and write songs — “add a bass line under the lead”, “make the drums half-time” — through the same tools you use, each turn one ⌘Z.