-- Le jour te fatigue
-- La nuit te répare
do
setcps (90/60/4)
let scale = getScale (scaleTable ++ [("blues",[0, 3, 5, 6, 7, 10])])
let modIndex = pF "modIndex"
d1 $ gM1 $ gF1 -- Le pouvoir de voler
  $ midiOn  "^41" (<| "k k*<1!3 2> k <k k*2>")
  $ midiOff "^41" (<| "k . k(3,8)")
  $ fix (|* gain 1) "808bd"
  $ fix ((|* gain 0.8)) "909"
  $ "[jazz,909,808bd:4]"
  # gain 1.4
d2 $ gM2 $ gF1 -- Every superhero needs a clap
  $ midiOn "^42" (fast 2)
  $ "~ cp"
  # "h2ogmcp"
  -- # note (-2)
  # gain 1.1
d3 $ gM2 $ gF1 -- Gretsch frappe ton os pour le renforcer
  $ midiOn "^43" (fast "2")
  -- FIXME(#94) d3 drives more controls than the grid gives it (BT3 only — BL1-3 are the family mutes). ^44 now belongs to another orbit, so this step STILL FIRES ACROSS COLUMNS — turning ^44 for its new owner also moves this. NOT commented out: this is a `$`-step and something above it is a partial application waiting for it, so removing it would stop the whole block compiling. Fold it onto d3's own control with gSel.
  -- FIXME(#94) d3 drives more controls than the grid gives it (BT3 only — BL1-3 are the family mutes). ^44 now belongs to another orbit, so this step STILL FIRES ACROSS COLUMNS — turning ^44 for its new owner also moves this. NOT commented out: this is a `$`-step and something above it is a partial application waiting for it, so removing it would stop the whole block compiling. Fold it onto d3's own control with gSel.
  $ midiOn "^44" (fast "1 2")
  $ sometimesBy "^31" (ply "1 2 1 2")
  $ fix ((|* gain 0.86) . (# n "[4|5]")) "gretsch"
  $ "~ h ~ h ~ h ~ h*<1 2>" # "[hh,gretsch]"
  -- # midiG' "^80" 0 1.75
d4 $ gM3 $ gF2 -- BASSLINE VOLTAIQUE
  $ midiOn "^44" ((|+ note 12) . (# legato 4))
  $ note ("<bf g bf g bf g bf c c!4 g bf c6@2>" - 24)
  -- $ note ("c6")
  # "90s_matrix:3"
  # cut 4
  # pan 0.3
  # gain 1
  # lesliebus 41 (range "-1" 1 "^32")
  # lrate (slow 4 $ "<[0.7 1.2!3] 2.4 4.8 6.7>")
  # lpf 5000
  # lsizebus 42 (range 1.9 6.7 "^52")
  -- FIXME(#54) d4 drives more controls than the grid gives it (B4 + C4). ^53 now belongs to another orbit, so the line(s) below are COMMENTED OUT rather than left firing across columns. Nothing is lost — restore by removing the dashes once gSel folds this onto d4's own control.
  -- # crushbus 43 (range 16 2 ("^53" - 0.1 * (fast 4 perlin)))
  -- # lpfbus   44 (range 12000 200 "^53")
  # room 0.2
d5 $ gM3 $ gF3 -- BLUES RUN
  $ someCyclesBy (range 0.95 0.05 ("^18!15 1")) (mask "t(3,8)")
  $ slice 16 (run 16)
  $ midiOn "^89" (striate 2)
  $ superimpose (# modIndex (range 0 96 "^33"))
  $ ply "1 4"
  $ note (scale "blues" (
    -- arp
    -- up, down, updown, downup, converge, diverge, disconverge, pinkyup,
    arp "<up pinkyup downup thumbupdown>" "[0,1,2,<3 4>,<4 <5 6>>]")
  + "0!3 <0!3 <1 3>>"
  - 24
  )
  # "FMRhodes1"
  # crushbus 5 (range 16 4.2 "^53")
  # gain 1.85
  -- # pan (slow 8 $ range 0.5 1 (saw - (slow 2 perlin)))
  # pan (slow 16 $ range 1 0.8 saw)
d7 $ gM3 $ gF2 -- G0dz1ll4
  $ midiOn "^59" (off 1 (
    (|+ pan 0.3)
    . (# cut 91)
    . (|+| note "[0|12]*8")
    . (|* gain 0.9)
    . (# squizbus 92 (range 0 10 perlin))
    ))
  $ "90s_matrix:1/4"
  # cut 9
  # gain 0.55
  # crushbus 9 (range 16 2.5 "^35")
  # roombus 91 (slow 16 $ range 0 0.82 perlin)
  # dry 2
  # sz 0.9
  # pan 0.7
  # gain 1.2

let scale = getScale (scaleTable ++ [("blues",["c", "ef", "f", "fs", "g", "bf"])])

-- REGION SANDBOX
once
  $ note (fastcat )
  # "FMRhodes1"

once $ "90s_weird" # cut 4

once $ "90s_matrix:3" # cut 1
