rlo-engine 1.0.3 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (166) hide show
  1. package/README.md +15 -4
  2. package/dist/Core/AudioMath.d.ts +29 -0
  3. package/dist/Core/AudioMath.d.ts.map +1 -0
  4. package/dist/Core/AudioMath.js +64 -0
  5. package/dist/Core/AudioMath.js.map +1 -0
  6. package/dist/Core/InstrumentMap.d.ts +36 -0
  7. package/dist/Core/InstrumentMap.d.ts.map +1 -0
  8. package/dist/Core/InstrumentMap.js +62 -0
  9. package/dist/Core/InstrumentMap.js.map +1 -0
  10. package/dist/Core/RLOCore.d.ts +49 -0
  11. package/dist/Core/RLOCore.d.ts.map +1 -0
  12. package/dist/Core/RLOCore.js +188 -0
  13. package/dist/Core/RLOCore.js.map +1 -0
  14. package/dist/Core/SequenceBuilder.d.ts +23 -0
  15. package/dist/Core/SequenceBuilder.d.ts.map +1 -0
  16. package/dist/Core/SequenceBuilder.js +31 -0
  17. package/dist/Core/SequenceBuilder.js.map +1 -0
  18. package/dist/Instruments/Analog/AnalogSynthBase.d.ts +17 -7
  19. package/dist/Instruments/Analog/AnalogSynthBase.d.ts.map +1 -1
  20. package/dist/Instruments/Analog/AnalogSynthBase.js +27 -16
  21. package/dist/Instruments/Analog/AnalogSynthBase.js.map +1 -1
  22. package/dist/Instruments/Analog/BassSynth.d.ts +12 -5
  23. package/dist/Instruments/Analog/BassSynth.d.ts.map +1 -1
  24. package/dist/Instruments/Analog/BassSynth.js +17 -10
  25. package/dist/Instruments/Analog/BassSynth.js.map +1 -1
  26. package/dist/Instruments/Analog/ChiptuneSynth.d.ts +11 -4
  27. package/dist/Instruments/Analog/ChiptuneSynth.d.ts.map +1 -1
  28. package/dist/Instruments/Analog/ChiptuneSynth.js +12 -5
  29. package/dist/Instruments/Analog/ChiptuneSynth.js.map +1 -1
  30. package/dist/Instruments/Analog/FMSynth.d.ts +11 -4
  31. package/dist/Instruments/Analog/FMSynth.d.ts.map +1 -1
  32. package/dist/Instruments/Analog/FMSynth.js +14 -7
  33. package/dist/Instruments/Analog/FMSynth.js.map +1 -1
  34. package/dist/Instruments/Analog/FormantSynth.d.ts +11 -4
  35. package/dist/Instruments/Analog/FormantSynth.d.ts.map +1 -1
  36. package/dist/Instruments/Analog/FormantSynth.js +12 -5
  37. package/dist/Instruments/Analog/FormantSynth.js.map +1 -1
  38. package/dist/Instruments/Analog/LeadSynth.d.ts +11 -4
  39. package/dist/Instruments/Analog/LeadSynth.d.ts.map +1 -1
  40. package/dist/Instruments/Analog/LeadSynth.js +14 -7
  41. package/dist/Instruments/Analog/LeadSynth.js.map +1 -1
  42. package/dist/Instruments/Analog/OrganSynth.d.ts +11 -4
  43. package/dist/Instruments/Analog/OrganSynth.d.ts.map +1 -1
  44. package/dist/Instruments/Analog/OrganSynth.js +17 -10
  45. package/dist/Instruments/Analog/OrganSynth.js.map +1 -1
  46. package/dist/Instruments/Analog/PadSynth.js +7 -7
  47. package/dist/Instruments/Analog/PadSynth.js.map +1 -1
  48. package/dist/Instruments/Analog/ReeseBassSynth.d.ts +11 -4
  49. package/dist/Instruments/Analog/ReeseBassSynth.d.ts.map +1 -1
  50. package/dist/Instruments/Analog/ReeseBassSynth.js +13 -6
  51. package/dist/Instruments/Analog/ReeseBassSynth.js.map +1 -1
  52. package/dist/Instruments/Analog/StringSynth.js +4 -4
  53. package/dist/Instruments/Analog/StringSynth.js.map +1 -1
  54. package/dist/Instruments/Analog/WoodwindSynth.d.ts +11 -4
  55. package/dist/Instruments/Analog/WoodwindSynth.d.ts.map +1 -1
  56. package/dist/Instruments/Analog/WoodwindSynth.js +19 -12
  57. package/dist/Instruments/Analog/WoodwindSynth.js.map +1 -1
  58. package/dist/Instruments/CoreSynthBase.d.ts +31 -24
  59. package/dist/Instruments/CoreSynthBase.d.ts.map +1 -1
  60. package/dist/Instruments/CoreSynthBase.js +53 -34
  61. package/dist/Instruments/CoreSynthBase.js.map +1 -1
  62. package/dist/Instruments/Decay/AdditiveSynth.d.ts +12 -5
  63. package/dist/Instruments/Decay/AdditiveSynth.d.ts.map +1 -1
  64. package/dist/Instruments/Decay/AdditiveSynth.js +9 -2
  65. package/dist/Instruments/Decay/AdditiveSynth.js.map +1 -1
  66. package/dist/Instruments/Decay/BrassSynth.d.ts +11 -4
  67. package/dist/Instruments/Decay/BrassSynth.d.ts.map +1 -1
  68. package/dist/Instruments/Decay/BrassSynth.js +22 -15
  69. package/dist/Instruments/Decay/BrassSynth.js.map +1 -1
  70. package/dist/Instruments/Decay/ChromaticPercussionSynth.d.ts +12 -5
  71. package/dist/Instruments/Decay/ChromaticPercussionSynth.d.ts.map +1 -1
  72. package/dist/Instruments/Decay/ChromaticPercussionSynth.js +16 -9
  73. package/dist/Instruments/Decay/ChromaticPercussionSynth.js.map +1 -1
  74. package/dist/Instruments/Decay/DecaySynthBase.d.ts +14 -8
  75. package/dist/Instruments/Decay/DecaySynthBase.d.ts.map +1 -1
  76. package/dist/Instruments/Decay/DecaySynthBase.js +22 -15
  77. package/dist/Instruments/Decay/DecaySynthBase.js.map +1 -1
  78. package/dist/Instruments/Decay/ElectricGuitarSynth.d.ts +12 -5
  79. package/dist/Instruments/Decay/ElectricGuitarSynth.d.ts.map +1 -1
  80. package/dist/Instruments/Decay/ElectricGuitarSynth.js +19 -12
  81. package/dist/Instruments/Decay/ElectricGuitarSynth.js.map +1 -1
  82. package/dist/Instruments/Decay/EthnicSynth.d.ts +12 -5
  83. package/dist/Instruments/Decay/EthnicSynth.d.ts.map +1 -1
  84. package/dist/Instruments/Decay/EthnicSynth.js +13 -6
  85. package/dist/Instruments/Decay/EthnicSynth.js.map +1 -1
  86. package/dist/Instruments/Decay/GuitarSynth.d.ts +12 -5
  87. package/dist/Instruments/Decay/GuitarSynth.d.ts.map +1 -1
  88. package/dist/Instruments/Decay/GuitarSynth.js +14 -7
  89. package/dist/Instruments/Decay/GuitarSynth.js.map +1 -1
  90. package/dist/Instruments/Decay/KarplusSynth.d.ts +7 -0
  91. package/dist/Instruments/Decay/KarplusSynth.d.ts.map +1 -1
  92. package/dist/Instruments/Decay/KarplusSynth.js +16 -8
  93. package/dist/Instruments/Decay/KarplusSynth.js.map +1 -1
  94. package/dist/Instruments/Decay/PianoSynth.d.ts +12 -5
  95. package/dist/Instruments/Decay/PianoSynth.d.ts.map +1 -1
  96. package/dist/Instruments/Decay/PianoSynth.js +19 -12
  97. package/dist/Instruments/Decay/PianoSynth.js.map +1 -1
  98. package/dist/Instruments/Decay/SlapBassSynth.d.ts +12 -5
  99. package/dist/Instruments/Decay/SlapBassSynth.d.ts.map +1 -1
  100. package/dist/Instruments/Decay/SlapBassSynth.js +13 -6
  101. package/dist/Instruments/Decay/SlapBassSynth.js.map +1 -1
  102. package/dist/Instruments/ISynthInstrument.d.ts +6 -0
  103. package/dist/Instruments/ISynthInstrument.d.ts.map +1 -1
  104. package/dist/Instruments/Speciality/DrumSynth.d.ts +7 -0
  105. package/dist/Instruments/Speciality/DrumSynth.d.ts.map +1 -1
  106. package/dist/Instruments/Speciality/DrumSynth.js +30 -21
  107. package/dist/Instruments/Speciality/DrumSynth.js.map +1 -1
  108. package/dist/Instruments/Speciality/SoundEffectsSynth.d.ts +7 -0
  109. package/dist/Instruments/Speciality/SoundEffectsSynth.d.ts.map +1 -1
  110. package/dist/Instruments/Speciality/SoundEffectsSynth.js +20 -12
  111. package/dist/Instruments/Speciality/SoundEffectsSynth.js.map +1 -1
  112. package/dist/Instruments/Synthesizer.d.ts +5 -0
  113. package/dist/Instruments/Synthesizer.d.ts.map +1 -1
  114. package/dist/Instruments/Synthesizer.js +7 -1
  115. package/dist/Instruments/Synthesizer.js.map +1 -1
  116. package/dist/Players/RLOGameEngine.d.ts +35 -0
  117. package/dist/Players/RLOGameEngine.d.ts.map +1 -0
  118. package/dist/Players/RLOGameEngine.js +98 -0
  119. package/dist/Players/RLOGameEngine.js.map +1 -0
  120. package/dist/Players/RLOMusicPlayer.d.ts +35 -0
  121. package/dist/Players/RLOMusicPlayer.d.ts.map +1 -0
  122. package/dist/Players/RLOMusicPlayer.js +167 -0
  123. package/dist/Players/RLOMusicPlayer.js.map +1 -0
  124. package/dist/RLO-Transpiler.d.ts +37 -15
  125. package/dist/RLO-Transpiler.d.ts.map +1 -1
  126. package/dist/RLO-Transpiler.js +139 -117
  127. package/dist/RLO-Transpiler.js.map +1 -1
  128. package/dist/compiler.d.ts +50 -31
  129. package/dist/compiler.d.ts.map +1 -1
  130. package/dist/compiler.js +165 -230
  131. package/dist/compiler.js.map +1 -1
  132. package/dist/crush.d.ts +1 -5
  133. package/dist/crush.d.ts.map +1 -1
  134. package/dist/crush.js +10 -3
  135. package/dist/crush.js.map +1 -1
  136. package/dist/index.d.ts +15 -2
  137. package/dist/index.d.ts.map +1 -1
  138. package/dist/index.js +14 -3
  139. package/dist/index.js.map +1 -1
  140. package/dist/midi-parser.d.ts +14 -0
  141. package/dist/midi-parser.d.ts.map +1 -1
  142. package/dist/midi-parser.js +21 -0
  143. package/dist/midi-parser.js.map +1 -1
  144. package/dist/rlo-engine.min.js +441 -439
  145. package/dist/rlo-engine.min.js.map +1 -1
  146. package/dist/rlo-engine.min.umd.js +1 -1
  147. package/dist/rlo-engine.min.umd.js.map +1 -1
  148. package/dist/types.d.ts +21 -3
  149. package/dist/types.d.ts.map +1 -1
  150. package/dist/types.js +4 -0
  151. package/dist/types.js.map +1 -1
  152. package/dist/vite.config.d.ts.map +1 -1
  153. package/dist/vite.config.js +16 -3
  154. package/dist/vite.config.js.map +1 -1
  155. package/dist/vite.config.js13k.d.ts.map +1 -1
  156. package/dist/vite.config.js13k.js +1 -0
  157. package/dist/vite.config.js13k.js.map +1 -1
  158. package/package.json +1 -1
  159. package/dist/Instruments/InstrumentFactory.d.ts +0 -2
  160. package/dist/Instruments/InstrumentFactory.d.ts.map +0 -1
  161. package/dist/Instruments/InstrumentFactory.js +0 -4
  162. package/dist/Instruments/InstrumentFactory.js.map +0 -1
  163. package/dist/RLO-Player.d.ts +0 -298
  164. package/dist/RLO-Player.d.ts.map +0 -1
  165. package/dist/RLO-Player.js +0 -724
  166. package/dist/RLO-Player.js.map +0 -1
@@ -1,655 +1,657 @@
1
- class t {
2
- constructor(t2, s2, i2) {
3
- this.h = t2, this.o = s2, this.u = i2;
4
- }
5
- l(t2, s2, i2, h2, e2) {
6
- const n2 = 0.6 * e2 * Math.min(1, 1600 / i2), r2 = this.u[t2] || this.u[0];
7
- globalThis.DEBUG_MIDI, r2 && r2.l(this.h, this.o, s2, i2, h2, n2);
8
- }
1
+ function t(t2, s2 = false) {
2
+ const i2 = t2.notes.length / 5, e2 = s2 ? new Float32Array(i2) : new Uint8Array(i2), h2 = new Uint16Array(i2), n2 = new Uint16Array(i2), o2 = new Uint8Array(i2), a2 = new Uint8Array(i2);
3
+ let c2 = 0;
4
+ for (let r2 = 0, u2 = 0; r2 < i2; r2++, u2 += 5) {
5
+ const i3 = t2.notes[u2 + 1], l2 = t2.notes[u2];
6
+ e2[r2] = s2 ? l2 : l2 > 0 ? Math.max(0, Math.min(255, Math.round(12 * Math.log2(l2 / 440) + 69))) : 0;
7
+ const d2 = Math.max(0, Math.round(1e3 * i3));
8
+ h2[r2] = Math.min(65535, d2 - c2), n2[r2] = Math.min(65535, Math.max(0, Math.round(1e3 * t2.notes[u2 + 2]))), o2[r2] = Math.max(0, Math.min(255, Math.round(255 * t2.notes[u2 + 3]))), a2[r2] = t2.notes[u2 + 4], c2 += h2[r2];
9
+ }
10
+ return { durationSecs: t2.durationSecs, f: e2, t: h2, d: n2, v: o2, i: a2 };
9
11
  }
10
- const _s = class _s {
11
- static _(t2, s2 = "studio") {
12
- if ("concert" === s2 && this.p) return this.p;
13
- if ("studio" === s2 && this.M) return this.M;
14
- const i2 = "studio" === s2, h2 = t2.sampleRate * (i2 ? 0.2 : 1.5), e2 = i2 ? 8 : 4, n2 = t2.createBuffer(2, h2, t2.sampleRate);
15
- for (let t3 = 0; t3 < 2; t3++) {
16
- const s3 = n2.getChannelData(t3);
17
- let i3 = 0;
18
- for (let t4 = 0; t4 < h2; t4++) i3 += 0.3 * (2 * Math.random() - 1 - i3), s3[t4] = i3 * Math.exp(t4 / h2 * -e2) * (1 - t4 / h2);
19
- }
20
- return i2 ? this.M = n2 : this.p = n2;
21
- }
22
- };
23
- _s.p = null;
24
- _s.M = null;
25
- let s = _s;
26
- class i {
27
- static S(t2, s2 = false) {
28
- const i2 = t2.notes.length / 5, h2 = s2 ? new Float32Array(i2) : new Uint8Array(i2), e2 = new Uint16Array(i2), n2 = new Uint16Array(i2), r2 = new Uint8Array(i2), o2 = new Uint8Array(i2);
29
- let a2 = 0;
30
- for (let c2 = 0, u2 = 0; c2 < i2; c2++, u2 += 5) {
31
- const i3 = t2.notes[u2 + 1], l2 = t2.notes[u2];
32
- h2[c2] = s2 ? l2 : l2 > 0 ? Math.max(0, Math.min(255, Math.round(12 * Math.log2(l2 / 440) + 69))) : 0;
33
- const d2 = Math.max(0, Math.round(1e3 * i3));
34
- e2[c2] = Math.min(65535, d2 - a2), n2[c2] = Math.min(65535, Math.max(0, Math.round(1e3 * t2.notes[u2 + 2]))), r2[c2] = Math.max(0, Math.min(255, Math.round(255 * t2.notes[u2 + 3]))), o2[c2] = t2.notes[u2 + 4], a2 += e2[c2];
35
- }
36
- return { durationSecs: t2.durationSecs, f: h2, t: e2, d: n2, v: r2, i: o2 };
37
- }
38
- static U(t2, s2 = false) {
39
- const i2 = 1 === new Uint8Array(new Uint16Array([1]).buffer)[0], h2 = this.S(t2, s2), e2 = h2.f.length, n2 = new ArrayBuffer(12 + (s2 ? 10 : 7) * e2), r2 = new DataView(n2);
40
- if (r2.setUint8(0, 82), r2.setUint8(1, 76), r2.setUint8(2, 79), r2.setUint8(3, s2 ? 70 : 50), r2.setFloat32(4, h2.durationSecs, true), r2.setUint32(8, e2, true), i2) new Uint16Array(n2, 12, e2).set(h2.t), new Uint16Array(n2, 12 + 2 * e2, e2).set(h2.d), s2 && new Float32Array(n2, 12 + 4 * e2, e2).set(h2.f);
41
- else for (let t3 = 0; t3 < e2; t3++) r2.setUint16(12 + 2 * t3, h2.t[t3], true), r2.setUint16(12 + 2 * e2 + 2 * t3, h2.d[t3], true), s2 && r2.setFloat32(12 + 4 * e2 + 4 * t3, h2.f[t3], true);
42
- return s2 ? (new Uint8Array(n2, 12 + 8 * e2, e2).set(h2.v), new Uint8Array(n2, 12 + 9 * e2, e2).set(h2.i)) : (new Uint8Array(n2, 12 + 4 * e2, e2).set(h2.f), new Uint8Array(n2, 12 + 5 * e2, e2).set(h2.v), new Uint8Array(n2, 12 + 6 * e2, e2).set(h2.i)), n2;
43
- }
44
- static R(t2) {
45
- const s2 = new DataView(t2), i2 = String.fromCharCode(s2.getUint8(0), s2.getUint8(1), s2.getUint8(2), s2.getUint8(3));
46
- if ("RLO2" !== i2 && "RLOF" !== i2) throw Error("Invalid RLO Binary format. Please recompile tracks.");
47
- const h2 = "RLOF" === i2, e2 = s2.getFloat32(4, true), n2 = s2.getUint32(8, true), r2 = h2 ? null : new Uint8Array(t2, 12 + 4 * n2, n2), o2 = new Uint8Array(t2, 12 + (h2 ? 8 : 5) * n2, n2), a2 = new Uint8Array(t2, 12 + (h2 ? 9 : 6) * n2, n2), c2 = Array(5 * n2);
48
- let u2 = 0;
49
- for (let t3 = 0, i3 = 0; t3 < n2; t3++, i3 += 5) {
50
- const e3 = s2.getUint16(12 + 2 * t3, true), l2 = s2.getUint16(12 + 2 * n2 + 2 * t3, true), d2 = h2 ? s2.getFloat32(12 + 4 * n2 + 4 * t3, true) : r2[t3];
51
- u2 += e3 / 1e3, c2[i3] = h2 ? d2 : d2 > 0 ? 440 * Math.pow(2, (d2 - 69) / 12) : 0, c2[i3 + 1] = u2, c2[i3 + 2] = l2 / 1e3, c2[i3 + 3] = o2[t3] / 255, c2[i3 + 4] = a2[t3];
52
- }
53
- return { durationSecs: e2, notes: c2 };
54
- }
12
+ function s(s2, i2 = false) {
13
+ const e2 = 1 === new Uint8Array(new Uint16Array([1]).buffer)[0], h2 = t(s2, i2), n2 = h2.f.length, o2 = new ArrayBuffer(12 + (i2 ? 10 : 7) * n2), a2 = new DataView(o2);
14
+ if (a2.setUint8(0, 82), a2.setUint8(1, 76), a2.setUint8(2, 79), a2.setUint8(3, i2 ? 70 : 50), a2.setFloat32(4, h2.durationSecs, true), a2.setUint32(8, n2, true), e2) new Uint16Array(o2, 12, n2).set(h2.t), new Uint16Array(o2, 12 + 2 * n2, n2).set(h2.d), i2 && new Float32Array(o2, 12 + 4 * n2, n2).set(h2.f);
15
+ else for (let t2 = 0; t2 < n2; t2++) a2.setUint16(12 + 2 * t2, h2.t[t2], true), a2.setUint16(12 + 2 * n2 + 2 * t2, h2.d[t2], true), i2 && a2.setFloat32(12 + 4 * n2 + 4 * t2, h2.f[t2], true);
16
+ return i2 ? (new Uint8Array(o2, 12 + 8 * n2, n2).set(h2.v), new Uint8Array(o2, 12 + 9 * n2, n2).set(h2.i)) : (new Uint8Array(o2, 12 + 4 * n2, n2).set(h2.f), new Uint8Array(o2, 12 + 5 * n2, n2).set(h2.v), new Uint8Array(o2, 12 + 6 * n2, n2).set(h2.i)), o2;
55
17
  }
56
- const h = { l: () => {
57
- } };
58
- function e(t2) {
59
- const s2 = Array(129).fill(null);
60
- return t2.forEach((t3) => {
61
- t3.ids.forEach((i2) => s2[i2] = t3.synth);
62
- }), s2;
18
+ function i(t2) {
19
+ const s2 = new DataView(t2), i2 = String.fromCharCode(s2.getUint8(0), s2.getUint8(1), s2.getUint8(2), s2.getUint8(3));
20
+ if ("RLO2" !== i2 && "RLOF" !== i2) throw Error("Invalid RLO Binary format. Please recompile tracks.");
21
+ const e2 = "RLOF" === i2, h2 = s2.getFloat32(4, true), n2 = s2.getUint32(8, true), o2 = e2 ? null : new Uint8Array(t2, 12 + 4 * n2, n2), a2 = new Uint8Array(t2, 12 + (e2 ? 8 : 5) * n2, n2), c2 = new Uint8Array(t2, 12 + (e2 ? 9 : 6) * n2, n2), r2 = new Float32Array(5 * n2);
22
+ let u2 = 0;
23
+ for (let t3 = 0, i3 = 0; t3 < n2; t3++, i3 += 5) {
24
+ const h3 = s2.getUint16(12 + 2 * t3, true), l2 = s2.getUint16(12 + 2 * n2 + 2 * t3, true), d2 = e2 ? s2.getFloat32(12 + 4 * n2 + 4 * t3, true) : o2[t3];
25
+ u2 += h3 / 1e3, r2[i3] = e2 ? d2 : d2 > 0 ? 440 * Math.pow(2, (d2 - 69) / 12) : 0, r2[i3 + 1] = u2, r2[i3 + 2] = l2 / 1e3, r2[i3 + 3] = a2[t3] / 255, r2[i3 + 4] = c2[t3];
26
+ }
27
+ return { durationSecs: h2, notes: r2 };
63
28
  }
64
- function n(t2) {
65
- const s2 = Array(129).fill(null);
66
- t2.forEach((t3) => {
67
- for (let i2 = t3.start; i2 <= t3.end; i2++) s2[i2] = t3.synth;
68
- });
69
- for (let t3 = 0; t3 < 129; t3++) if (null === s2[t3]) {
70
- let i2 = null, h2 = 1 / 0;
71
- for (let e2 = 0; e2 < 129; e2++) if (null !== s2[e2]) {
72
- const n2 = Math.abs(t3 - e2);
73
- n2 < h2 && (h2 = n2, i2 = s2[e2]);
74
- }
75
- s2[t3] = i2;
29
+ class e {
30
+ constructor(t2, s2, i2) {
31
+ this.h = t2, this.o = s2, this.u = i2;
32
+ }
33
+ l(t2, s2, i2, e2, h2) {
34
+ const n2 = 0.6 * h2 * Math.min(1, 1600 / i2), o2 = this.u[t2] || this.u[0];
35
+ o2 && o2.l(this.h, this.o, s2, i2, e2, n2);
76
36
  }
77
- return s2;
78
- }
79
- function r(t2, s2) {
80
- const i2 = [...t2];
81
- return s2.forEach((t3) => {
82
- for (let s3 = t3.start; s3 <= t3.end; s3++) i2[s3] = t3.synth;
83
- }), i2;
84
37
  }
85
- let o = class {
38
+ let h = class {
86
39
  constructor(t2, s2 = []) {
87
- this.N = false, this.T = null, this.V = null, this.I = 0, this.L = 0, this.O = 0, this.j = [], this.q = 0.5, this.k = null, this.playbackRate = 1, this.X = null, this.h = t2, this.H = s2;
40
+ this.p = false, this._ = null, this.S = null, this.m = 0, this.M = 0, this.T = 0, this.k = [], this.V = 0.5, this.U = null, this.playbackRate = 1, this.R = null, this.h = t2, this.N = s2;
88
41
  }
89
- get J() {
42
+ get q() {
90
43
  return this.h.currentTime;
91
44
  }
92
45
  setVolume(t2) {
93
- this.q = t2;
46
+ this.V = t2;
94
47
  }
95
48
  seek(t2) {
96
- this.O > 0 && (this.k = Math.max(0, t2) % this.O);
49
+ this.T > 0 && (this.U = Math.max(0, t2) % this.T);
97
50
  }
98
51
  stop() {
99
- this.N = false, this.I++, this.T && clearTimeout(this.T), this.V && this.V.postMessage("stop");
100
- const t2 = this.j;
101
- this.j = [], t2.forEach((t3) => {
102
- try {
103
- t3.disconnect();
104
- } catch (t4) {
105
- }
106
- });
52
+ this.p = false, this.m++, this._ && clearTimeout(this._);
53
+ const t2 = this.k;
54
+ for (this.k = []; t2.length; ) try {
55
+ t2.pop().disconnect();
56
+ } catch (t3) {
57
+ }
107
58
  }
108
59
  dispose() {
109
- this.stop(), this.V && (this.V.terminate(), this.V = null), this.X && (URL.revokeObjectURL(this.X), this.X = null);
60
+ this.stop();
110
61
  }
111
- P() {
62
+ O() {
112
63
  return this.h.createGain();
113
64
  }
114
- $(t2, s2, i2) {
115
- t2.setValueAtTime(i2 > 0 ? 0 : s2, this.J), i2 > 0 && t2.linearRampToValueAtTime(s2, this.J + i2);
65
+ I(t2, s2, i2) {
66
+ t2.setValueAtTime(i2 > 0 ? 0 : s2, this.q), i2 > 0 && t2.linearRampToValueAtTime(s2, this.q + i2);
116
67
  }
117
- K(t2 = this.h) {
68
+ L(t2 = this.h) {
118
69
  const s2 = t2.createDynamicsCompressor();
119
70
  return s2.threshold.value = -24, s2.knee.value = 12, s2.ratio.value = 8, s2.attack.value = 1e-3, s2.release.value = 0.25, s2;
120
71
  }
121
- W(t2 = 0) {
122
- const s2 = this.P();
123
- return this.$(s2.gain, this.q, t2), s2.connect(this.h.destination), this.j.push(s2), { destination: s2 };
124
- }
125
- playSequence(s2, i2 = true, h2 = 0) {
126
- let e2 = true, n2 = h2;
127
- "object" == typeof i2 ? (e2 = i2.loop ?? true, n2 = i2.fadeInTime ?? 0, void 0 !== i2.playbackRate && (this.playbackRate = i2.playbackRate), void 0 !== i2.volume && this.setVolume(i2.volume)) : e2 = i2, this.stop(), "suspended" === this.h.state && this.h.resume(), this.N = true;
128
- const r2 = ++this.I;
129
- this.O = s2.durationSecs;
130
- const { destination: o2 } = this.W(n2), a2 = new t(this.h, o2, this.H);
131
- this.L = -0.05 * this.playbackRate;
132
- let c2 = this.J, u2 = 0, l2 = 0;
133
- const d2 = s2.notes, p2 = d2.length, y2 = () => {
134
- if (!this.N || this.I !== r2) return;
135
- const t2 = this.J, i3 = t2 - c2;
136
- if (c2 = t2, null !== this.k) {
137
- for (this.L = this.k, u2 = 0, l2 = 0; l2 < p2 && d2[l2 + 1] < this.k; ) l2 += 5;
138
- this.k = null;
139
- } else this.L += i3 * this.playbackRate;
140
- const h3 = s2.durationSecs;
72
+ j(t2 = 0) {
73
+ const s2 = this.O();
74
+ return this.I(s2.gain, this.V, t2), s2.connect(this.h.destination), this.k.push(s2), { destination: s2 };
75
+ }
76
+ playSequence(t2, s2 = true, i2 = 0) {
77
+ let h2 = true, n2 = i2;
78
+ "object" == typeof s2 ? (h2 = s2.loop ?? true, n2 = s2.fadeInTime ?? 0, this.playbackRate = s2.playbackRate ?? this.playbackRate, void 0 !== s2.volume && this.setVolume(s2.volume)) : h2 = s2, this.stop(), "suspended" === this.h.state && this.h.resume(), this.p = true;
79
+ const o2 = ++this.m;
80
+ this.T = t2.durationSecs;
81
+ const { destination: a2 } = this.j(n2), c2 = new e(this.h, a2, this.N);
82
+ this.M = -0.05 * this.playbackRate;
83
+ let r2 = this.q, u2 = 0, l2 = 0;
84
+ const d2 = t2.notes, p2 = d2.length, y2 = () => {
85
+ if (!this.p || this.m !== o2) return;
86
+ if (0 === p2) return;
87
+ const s3 = this.q, i3 = s3 - r2;
88
+ if (r2 = s3, null !== this.U) {
89
+ for (this.M = this.U, u2 = 0, l2 = 0; l2 < p2 && d2[l2 + 1] < this.U; ) l2 += 5;
90
+ this.U = null;
91
+ const t3 = a2;
92
+ t3.gain && (t3.gain.cancelScheduledValues(s3), t3.gain.setValueAtTime(1e-3, s3), t3.gain.exponentialRampToValueAtTime(this.V, s3 + 0.5));
93
+ } else this.M += i3 * this.playbackRate;
94
+ const e2 = t2.durationSecs;
141
95
  for (; l2 < p2; ) {
142
- const s3 = d2[l2], i4 = d2[l2 + 1], h4 = d2[l2 + 2], e3 = d2[l2 + 3], n3 = d2[l2 + 4], r3 = u2 + i4;
143
- if (!(r3 < this.L + 0.5 * this.playbackRate)) break;
144
- {
145
- const i5 = t2 + Math.max(0, (r3 - this.L) / this.playbackRate);
146
- a2.l(n3, i5, s3, h4 / this.playbackRate, e3), l2 += 5;
96
+ const t3 = u2 + d2[l2 + 1];
97
+ if (t3 >= this.M + 0.5 * this.playbackRate) break;
98
+ if (this.M - t3 <= 0.15 * this.playbackRate) {
99
+ const i4 = s3 + Math.max(0, (t3 - this.M) / this.playbackRate);
100
+ c2.l(d2[l2 + 4], i4, d2[l2], d2[l2 + 2] / this.playbackRate, d2[l2 + 3]);
147
101
  }
102
+ l2 += 5;
148
103
  }
149
- l2 >= p2 ? e2 ? (l2 = 0, u2 += h3, y2()) : this.V && this.V.postMessage("stop") : this.V || (this.T = setTimeout(y2, 50));
104
+ l2 >= p2 ? h2 && (l2 = 0, u2 += e2, y2()) : this._ = setTimeout(y2, 50);
150
105
  };
151
- this.V && (this.V.onmessage = () => y2(), this.V.postMessage("start")), y2();
106
+ y2();
107
+ }
108
+ };
109
+ const _n = class _n {
110
+ static J(t2, s2 = "studio") {
111
+ if ("concert" === s2 && this.X) return this.X;
112
+ if ("studio" === s2 && this.P) return this.P;
113
+ const i2 = "studio" === s2, e2 = t2.sampleRate * (i2 ? 0.2 : 1.5), h2 = i2 ? 8 : 4, n2 = t2.createBuffer(2, e2, t2.sampleRate);
114
+ for (let t3 = 0; t3 < 2; t3++) {
115
+ const s3 = n2.getChannelData(t3);
116
+ let i3 = 0;
117
+ for (let t4 = 0; t4 < e2; t4++) i3 += 0.3 * (2 * Math.random() - 1 - i3), s3[t4] = i3 * Math.exp(t4 / e2 * -h2) * (1 - t4 / e2);
118
+ }
119
+ return i2 ? this.P = n2 : this.X = n2;
152
120
  }
153
- }, a = class extends o {
154
- constructor(t2, i2 = []) {
155
- super(t2, i2), this.o = null, this.Y = null, this.Z = null, this.tt = /* @__PURE__ */ new Map(), this.st = 20, this.it = "concert", s._(this.h, "concert"), s._(this.h, "studio"), this.ht = () => {
156
- document.hidden ? this.h.suspend() : this.N && this.h.resume();
157
- }, "undefined" != typeof document && document.addEventListener("visibilitychange", this.ht);
121
+ };
122
+ _n.X = null;
123
+ _n.P = null;
124
+ let n = _n;
125
+ let o = class extends h {
126
+ constructor(t2, s2 = []) {
127
+ super(t2, s2), this.$ = null, this.H = null, this.K = null, this.W = /* @__PURE__ */ new Map(), this.Y = 20, this.Z = "concert", n.J(this.h, "concert"), n.J(this.h, "studio"), this.tt = () => {
128
+ document.hidden ? this.h.suspend() : this.p && this.h.resume();
129
+ }, "undefined" != typeof document && document.addEventListener("visibilitychange", this.tt);
158
130
  }
159
131
  setReverbMode(t2) {
160
- this.it = t2, this.Y && this.Z && (this.Y.buffer = s._(this.h, t2), this.Z.gain.setTargetAtTime("studio" === t2 ? 0.05 : 0.2, this.J, 0.1));
132
+ this.Z = t2, this.H && this.K && (this.H.buffer = n.J(this.h, t2), this.K.gain.setTargetAtTime("studio" === t2 ? 0.05 : 0.2, this.q, 0.1));
161
133
  }
162
134
  dispose() {
163
- super.dispose(), "undefined" != typeof document && document.removeEventListener("visibilitychange", this.ht), this.tt.clear();
135
+ super.dispose(), "undefined" != typeof document && document.removeEventListener("visibilitychange", this.tt), this.W.clear();
164
136
  }
165
137
  setVolume(t2) {
166
- super.setVolume(t2), this.o && this.o.gain.setTargetAtTime(t2, this.J, 0.1);
138
+ super.setVolume(t2), this.$ && this.$.gain.setTargetAtTime(t2, this.q, 0.1);
167
139
  }
168
140
  getCurrentTime() {
169
- return 0 !== this.O && this.N ? Math.max(0, this.L) % this.O : 0;
141
+ return 0 !== this.T && this.p ? Math.max(0, this.M) % this.T : 0;
170
142
  }
171
143
  getTotalDuration() {
172
- return this.O;
173
- }
174
- W(t2 = 0) {
175
- this.Y = this.h.createConvolver(), this.Y.buffer = s._(this.h, this.it), this.o = this.P(), this.j.push(this.Y, this.o), this.$(this.o.gain, this.q, t2), this.Z = this.P(), this.Z.gain.value = "studio" === this.it ? 0.05 : 0.2, this.j.push(this.Z);
176
- const i2 = this.h.createBiquadFilter();
177
- i2.type = "lowpass", i2.frequency.value = Math.min(this.h.sampleRate / 2 - 1, 6500), this.j.push(i2);
178
- const h2 = this.K();
179
- return this.j.push(h2), this.o.connect(i2).connect(h2).connect(this.h.destination), this.o.connect(this.Y).connect(this.Z).connect(i2), { destination: this.o };
180
- }
181
- async play(t2, s2 = 0, h2 = true) {
182
- let e2, n2 = 0, r2 = {};
183
- if ("object" == typeof s2 ? (n2 = s2.fadeInTime ?? 0, r2 = s2) : (n2 = s2, r2 = { fadeInTime: n2, loop: h2 }), "string" == typeof t2) if (this.tt.has(t2)) e2 = this.tt.get(t2);
144
+ return this.T;
145
+ }
146
+ j(t2 = 0) {
147
+ this.H = this.h.createConvolver(), this.H.buffer = n.J(this.h, this.Z), this.$ = this.O(), this.k.push(this.H, this.$), this.I(this.$.gain, this.V, t2), this.K = this.O(), this.K.gain.value = "studio" === this.Z ? 0.05 : 0.2, this.k.push(this.K);
148
+ const s2 = this.h.createBiquadFilter();
149
+ s2.type = "lowpass", s2.frequency.value = Math.min(this.h.sampleRate / 2 - 1, 6500), this.k.push(s2);
150
+ const i2 = this.L();
151
+ return this.k.push(i2), this.$.connect(s2).connect(i2).connect(this.h.destination), this.$.connect(this.H).connect(this.K).connect(s2), { destination: this.$ };
152
+ }
153
+ async play(t2, s2 = 0, e2 = true) {
154
+ let h2, n2 = 0, o2 = {};
155
+ if ("object" == typeof s2 ? (n2 = s2.fadeInTime ?? 0, o2 = s2) : (n2 = s2, o2 = { fadeInTime: n2, loop: e2 }), "string" == typeof t2) if (this.W.has(t2)) h2 = this.W.get(t2);
184
156
  else {
185
157
  const s3 = await fetch(t2);
186
- if (t2.toLowerCase().endsWith(".json")) {
158
+ if (void 0 !== window.__ENABLE_TRANSPILER__ && !window.__ENABLE_TRANSPILER__ || t2.toLowerCase().endsWith(".json")) {
187
159
  const t3 = await s3.text();
188
- e2 = JSON.parse(t3);
160
+ h2 = JSON.parse(t3);
189
161
  } else {
190
- const t3 = await s3.arrayBuffer(), h3 = new DataView(t3);
191
- if (h3.byteLength >= 3 && 82 === h3.getUint8(0) && 76 === h3.getUint8(1) && 79 === h3.getUint8(2)) e2 = i.R(t3);
162
+ const t3 = await s3.arrayBuffer(), e3 = new DataView(t3);
163
+ if (e3.byteLength >= 3 && 82 === e3.getUint8(0) && 76 === e3.getUint8(1) && 79 === e3.getUint8(2)) h2 = i(t3);
192
164
  else {
193
- const s4 = new window.DecompressionStream("gzip"), h4 = s4.writable.getWriter();
194
- h4.write(t3), h4.close(), e2 = i.R(await new Response(s4.readable).arrayBuffer());
165
+ const s4 = new window.DecompressionStream("gzip"), e4 = s4.writable.getWriter();
166
+ e4.write(t3), e4.close(), h2 = i(await new Response(s4.readable).arrayBuffer());
195
167
  }
196
168
  }
197
- if (this.tt.set(t2, e2), this.tt.size > this.st) {
198
- const t3 = this.tt.keys().next().value;
199
- t3 && this.tt.delete(t3);
169
+ if (this.W.set(t2, h2), this.W.size > this.Y) {
170
+ const t3 = this.W.keys().next().value;
171
+ t3 && this.W.delete(t3);
200
172
  }
201
173
  }
202
- else e2 = t2;
203
- this.playSequence(e2, r2);
174
+ else h2 = t2;
175
+ this.playSequence(h2, o2);
204
176
  }
205
177
  stop() {
206
- if (this.o) {
207
- const t2 = this.J;
208
- this.o.gain.cancelScheduledValues(t2), this.o.gain.setValueAtTime(0, t2), this.o = null, this.Z = null, this.Y = null;
178
+ if (this.$) {
179
+ const t2 = this.q;
180
+ this.$.gain.cancelScheduledValues(t2), this.$.gain.setValueAtTime(0, t2), this.$ = null, this.K = null, this.H = null;
209
181
  }
210
182
  super.stop();
211
183
  }
212
- }, c = class extends o {
213
- constructor(s2, i2 = []) {
214
- super(s2, i2), this.o = this.P(), this.o.gain.value = this.q;
215
- const h2 = this.K();
216
- this.o.connect(h2).connect(this.h.destination), this.et = this.P(), this.et.connect(this.o), this.nt = this.P(), this.nt.connect(this.o), this.rt = new t(this.h, this.nt, this.H);
184
+ }, a = class extends h {
185
+ constructor(t2, s2 = []) {
186
+ super(t2, s2), this.st = this.O(), this.st.gain.value = this.V;
187
+ const i2 = this.L();
188
+ this.st.connect(i2).connect(this.h.destination), this.it = this.O(), this.it.connect(this.st), this.et = this.O(), this.et.connect(this.st), this.ht = new e(this.h, this.et, this.N);
217
189
  }
218
190
  setVolume(t2) {
219
- super.setVolume(t2), this.o.gain.setTargetAtTime(t2, this.J, 0.1);
191
+ super.setVolume(t2), this.st.gain.setTargetAtTime(t2, this.q, 0.1);
220
192
  }
221
193
  setMusicVolume(t2) {
222
- this.et.gain.setTargetAtTime(t2, this.J, 0.1);
194
+ this.it.gain.setTargetAtTime(t2, this.q, 0.1);
223
195
  }
224
196
  setSFXVolume(t2) {
225
- this.nt.gain.setTargetAtTime(t2, this.J, 0.1);
197
+ this.et.gain.setTargetAtTime(t2, this.q, 0.1);
226
198
  }
227
- W(t2 = 0) {
228
- const s2 = this.P();
229
- return s2.connect(this.et), this.j.push(s2), this.$(s2.gain, 1, t2), { destination: s2 };
199
+ j(t2 = 0) {
200
+ const s2 = this.O();
201
+ return s2.connect(this.it), this.k.push(s2), this.I(s2.gain, 1, t2), { destination: s2 };
230
202
  }
231
- playSFX(t2, s2, i2, h2 = 1, e2 = 0) {
203
+ playSFX(t2, s2, i2, e2 = 1, h2 = 0) {
232
204
  "suspended" === this.h.state && this.h.resume();
233
- let n2 = 1, r2 = e2;
234
- "object" == typeof h2 ? (n2 = h2.velocity ?? 1, r2 = h2.timeOffset ?? 0) : n2 = h2, this.rt.l(t2, this.J + r2, function(t3) {
205
+ let n2 = 1, o2 = h2;
206
+ "object" == typeof e2 ? (n2 = e2.velocity ?? 1, o2 = e2.timeOffset ?? 0) : n2 = e2, this.ht.l(t2, this.q + o2, function(t3) {
235
207
  if ("number" == typeof t3) return t3;
236
208
  const s3 = t3.match(/^([a-gA-G])([#b]?)(\d)$/);
237
209
  if (!s3) return 0;
238
- const [, i3, h3, e3] = s3;
210
+ const [, i3, e3, h3] = s3;
239
211
  let n3 = { C: -9, D: -7, E: -5, F: -4, G: -2, A: 0, B: 2 }[i3.toUpperCase()];
240
- return "#" === h3 && n3++, "b" === h3 && n3--, n3 += 12 * (parseInt(e3, 10) - 4), +(440 * Math.pow(2, n3 / 12)).toFixed(2);
212
+ return "#" === e3 && n3++, "b" === e3 && n3--, n3 += 12 * (parseInt(h3, 10) - 4), +(440 * Math.pow(2, n3 / 12)).toFixed(2);
241
213
  }(s2), i2, n2);
242
214
  }
243
215
  playSFXSequence(t2, s2 = 0) {
244
216
  "suspended" === this.h.state && this.h.resume();
245
- const i2 = this.J + s2, h2 = t2.notes, e2 = h2.length;
246
- for (let t3 = 0; t3 < e2; t3 += 5) this.rt.l(h2[t3 + 4], i2 + h2[t3 + 1], h2[t3], h2[t3 + 2], h2[t3 + 3]);
217
+ const i2 = this.q + s2, e2 = t2.notes, h2 = e2.length;
218
+ for (let t3 = 0; t3 < h2; t3 += 5) this.ht.l(e2[t3 + 4], i2 + e2[t3 + 1], e2[t3], e2[t3 + 2], e2[t3 + 3]);
247
219
  }
248
220
  playMusic(t2, s2 = true, i2 = 0) {
249
- let h2 = s2;
250
- "object" == typeof s2 && void 0 !== s2.volume && (this.setMusicVolume(s2.volume), h2 = { ...s2 }, delete h2.volume), this.playSequence(t2, h2, i2);
221
+ let e2 = s2;
222
+ "object" == typeof s2 && void 0 !== s2.volume && (this.setMusicVolume(s2.volume), e2 = { ...s2 }, delete e2.volume), this.playSequence(t2, e2, i2);
251
223
  }
252
224
  stopMusic() {
253
225
  super.stop();
254
226
  }
255
227
  };
256
- var u = ((t2) => (t2[t2.Sine = 0] = "Sine", t2[t2.Square = 1] = "Square", t2[t2.Sawtooth = 2] = "Sawtooth", t2[t2.Triangle = 3] = "Triangle", t2))(u || {}), l = ((t2) => (t2[t2.Lowpass = 0] = "Lowpass", t2[t2.Highpass = 1] = "Highpass", t2[t2.Bandpass = 2] = "Bandpass", t2))(l || {});
228
+ const c = { l: () => {
229
+ } };
230
+ function r(t2) {
231
+ const s2 = Array(129).fill(null);
232
+ return t2.forEach((t3) => {
233
+ t3.ids.forEach((i2) => s2[i2] = t3.synth);
234
+ }), s2;
235
+ }
236
+ function u(t2) {
237
+ const s2 = Array(129).fill(null);
238
+ t2.forEach((t3) => {
239
+ for (let i2 = t3.start; i2 <= t3.end; i2++) s2[i2] = t3.synth;
240
+ });
241
+ for (let t3 = 0; t3 < 129; t3++) if (null === s2[t3]) {
242
+ let i2 = null, e2 = 1 / 0;
243
+ for (let h2 = 0; h2 < 129; h2++) if (null !== s2[h2]) {
244
+ const n2 = Math.abs(t3 - h2);
245
+ n2 < e2 && (e2 = n2, i2 = s2[h2]);
246
+ }
247
+ s2[t3] = i2;
248
+ }
249
+ return s2;
250
+ }
251
+ function l(t2, s2) {
252
+ const i2 = [...t2];
253
+ return s2.forEach((t3) => {
254
+ for (let s3 = t3.start; s3 <= t3.end; s3++) i2[s3] = t3.synth;
255
+ }), i2;
256
+ }
257
257
  class d {
258
- ot(t2, s2, i2, h2) {
259
- const e2 = t2.createOscillator();
260
- return e2.type = ["sine", "square", "sawtooth", "triangle"][s2], i2 && (e2.frequency.value = Math.min(22e3, i2)), h2 && e2.connect(h2), e2;
258
+ nt(t2, s2, i2, e2) {
259
+ const h2 = t2.createOscillator();
260
+ return h2.type = s2, i2 && (h2.frequency.value = Math.min(22e3, i2)), e2 && h2.connect(e2), h2;
261
261
  }
262
- P(t2, s2, i2) {
263
- const h2 = t2.createGain();
264
- return h2.gain.value = s2, i2 && h2.connect(i2), h2;
262
+ O(t2, s2, i2) {
263
+ const e2 = t2.createGain();
264
+ return e2.gain.value = s2, i2 && e2.connect(i2), e2;
265
265
  }
266
- ct(t2, s2) {
266
+ ot(t2, s2) {
267
267
  const i2 = t2.createBiquadFilter();
268
- return i2.type = ["lowpass", "highpass", "bandpass"][s2], i2;
268
+ return i2.type = s2, i2;
269
269
  }
270
- ut(t2, s2, i2) {
271
- const h2 = t2.createStereoPanner();
272
- return h2.pan.value = s2, i2 && h2.connect(i2), h2;
270
+ ct(t2, s2, i2) {
271
+ const e2 = t2.createStereoPanner();
272
+ return e2.pan.value = s2, i2 && e2.connect(i2), e2;
273
273
  }
274
- lt(t2, s2, ...i2) {
274
+ rt(t2, s2, ...i2) {
275
275
  i2.forEach((i3) => {
276
276
  i3.start(t2), i3.stop(s2);
277
277
  });
278
278
  }
279
- dt(t2, s2, i2) {
279
+ ut(t2, s2, i2) {
280
280
  t2.setValueAtTime(Math.min(22e3, s2), i2);
281
281
  }
282
- yt(t2, s2, i2) {
282
+ lt(t2, s2, i2) {
283
283
  t2.linearRampToValueAtTime(Math.min(22e3, s2), i2);
284
284
  }
285
- Mt(t2, s2, i2) {
285
+ dt(t2, s2, i2) {
286
286
  t2.exponentialRampToValueAtTime(Math.min(22e3, s2), i2);
287
287
  }
288
- ft(t2, s2, i2, h2, e2, n2, r2, o2 = 0) {
289
- const a2 = this.P(t2, 0, h2);
290
- this.dt(a2.gain, o2 > 0 ? 0 : n2, e2), o2 > 0 && this.yt(a2.gain, n2, e2 + o2), this.Mt(a2.gain, 1e-3, e2 + r2), this.lt(e2, e2 + r2, this.ot(t2, s2, i2, a2));
288
+ yt(t2, s2, i2, e2, h2, n2, o2, a2 = 0) {
289
+ const c2 = this.O(t2, 0, e2);
290
+ this.ut(c2.gain, a2 > 0 ? 0 : n2, h2), a2 > 0 && this.lt(c2.gain, n2, h2 + a2), this.dt(c2.gain, 1e-3, h2 + o2), this.rt(h2, h2 + o2, this.nt(t2, s2, i2, c2));
291
291
  }
292
- wt(t2, s2, i2, h2, e2, n2) {
293
- const r2 = this.ct(t2, s2);
294
- return this.dt(r2.frequency, i2, e2), this.Mt(r2.frequency, h2, e2 + n2), r2;
292
+ _t(t2, s2, i2, e2, h2, n2) {
293
+ const o2 = this.ot(t2, s2);
294
+ return this.ut(o2.frequency, i2, h2), this.dt(o2.frequency, e2, h2 + n2), o2;
295
295
  }
296
- _t(t2, s2, i2, h2, e2, n2) {
297
- return [this.ot(t2, s2, i2, this.ut(t2, -e2, n2)), this.ot(t2, s2, i2 * h2, this.ut(t2, e2, n2))];
296
+ wt(t2, s2, i2, e2, h2, n2) {
297
+ return [this.nt(t2, s2, i2, this.ct(t2, -h2, n2)), this.nt(t2, s2, i2 * e2, this.ct(t2, h2, n2))];
298
298
  }
299
- St(t2, s2, i2, h2, e2, n2, r2, o2 = 0) {
300
- const a2 = this.P(t2, 0, r2);
301
- return this.dt(a2.gain, 0, h2), o2 > 0 && this.dt(a2.gain, 0, h2 + o2), this.yt(a2.gain, i2, h2 + o2 + e2), this.lt(h2, n2, this.ot(t2, 0, s2, a2)), a2;
299
+ St(t2, s2, i2, e2, h2, n2, o2, a2 = 0) {
300
+ const c2 = this.O(t2, 0, o2);
301
+ return this.ut(c2.gain, 0, e2), a2 > 0 && this.ut(c2.gain, 0, e2 + a2), this.lt(c2.gain, i2, e2 + a2 + h2), this.rt(e2, n2, this.nt(t2, "sine", s2, c2)), c2;
302
302
  }
303
- vt(t2, s2, i2, ...h2) {
303
+ ft(t2, s2, i2, ...e2) {
304
304
  {
305
- const e2 = t2.createOscillator();
306
- e2.onended = () => {
307
- h2.forEach((t3) => {
305
+ const h2 = this.nt(t2, "sine", 0);
306
+ h2.onended = () => {
307
+ e2.forEach((t3) => {
308
308
  try {
309
- t3.disconnect();
309
+ t3 && "function" == typeof t3.disconnect && t3.disconnect();
310
310
  } catch (t4) {
311
311
  }
312
312
  });
313
- }, e2.start(s2), e2.stop(i2);
313
+ }, h2.start(s2), h2.stop(i2);
314
314
  }
315
315
  }
316
316
  }
317
317
  class p extends d {
318
318
  constructor() {
319
- super(...arguments), this.xt = { v: 0.5, a: 0.02, d: 0.2, m: 4 };
319
+ super(...arguments), this.Mt = { Tt: 0.5, xt: 0.02, kt: 0.2, Vt: 4 };
320
320
  }
321
- l(t2, s2, i2, h2, e2, n2) {
322
- const r2 = t2.createGain(), o2 = this.gt(), a2 = Math.max(1e-3, n2 * o2.v), c2 = Math.max(0.02, Math.min(e2, o2.m));
323
- this.dt(r2.gain, 0, i2), this.yt(r2.gain, a2, i2 + o2.a), this.At(r2.gain, a2, i2, o2.a, c2, o2.d);
324
- const u2 = i2 + c2 + o2.d + 0.1, l2 = this.Ut(t2, s2, r2, i2, h2, n2, c2, u2) || r2;
325
- l2.connect(s2), this.vt(t2, i2, u2 + 2, l2);
321
+ l(t2, s2, i2, e2, h2, n2) {
322
+ const o2 = t2.createGain(), a2 = this.At(), c2 = Math.max(1e-3, n2 * a2.Tt), r2 = Math.max(0.02, Math.min(h2, a2.Vt));
323
+ this.ut(o2.gain, 0, i2), this.lt(o2.gain, c2, i2 + a2.xt), this.gt(o2.gain, c2, i2, a2.xt, r2, a2.kt);
324
+ const u2 = i2 + r2 + a2.kt + 0.1, l2 = this.Dt(t2, s2, o2, i2, e2, n2, r2, u2) || o2;
325
+ l2.connect(s2), this.ft(t2, i2, u2 + 2, l2);
326
326
  }
327
- gt() {
328
- return this.xt;
327
+ At() {
328
+ return this.Mt;
329
329
  }
330
- At(t2, s2, i2, h2, e2, n2) {
331
- this.Mt(t2, 1e-3, i2 + e2 + n2);
330
+ gt(t2, s2, i2, e2, h2, n2) {
331
+ this.dt(t2, 1e-3, i2 + h2 + n2);
332
332
  }
333
333
  }
334
334
  class y extends p {
335
335
  constructor() {
336
- super(...arguments), this.xt = { v: 0.8, a: 0.015, d: 0.1, m: 5 };
336
+ super(...arguments), this.Mt = { Tt: 0.8, xt: 0.015, kt: 0.1, Vt: 5 };
337
337
  }
338
- Ut(t2, s2, i2, h2, e2, n2, r2, o2) {
339
- const a2 = this.wt(t2, l.Lowpass, e2 + 800 + 1e3 * n2, e2 + 200, h2, Math.min(r2, 1)), c2 = this.ot(t2, u.Triangle, e2, i2), d2 = this.P(t2, 0), p2 = this.ot(t2, u.Sine, 2.003 * e2, d2), y2 = this.ot(t2, u.Sine, 3.007 * e2, d2), M2 = this.ut(t2, Math.max(-0.8, Math.min(0.8, (e2 - 261.6) / 800)));
340
- return this.dt(d2.gain, 0, h2), this.yt(d2.gain, Math.max(1e-3, 0.15 * n2), h2 + 0.01), this.Mt(d2.gain, 1e-3, h2 + Math.min(r2, 0.5)), d2.connect(M2), this.ft(t2, u.Sine, 60, M2, h2, Math.max(1e-3, 0.4 * n2), 0.05, 5e-3), i2.connect(M2).connect(a2), this.lt(h2, o2, c2, p2, y2), a2;
338
+ Dt(t2, s2, i2, e2, h2, n2, o2, a2) {
339
+ const c2 = this._t(t2, "lowpass", h2 + 800 + 1e3 * n2, h2 + 200, e2, Math.min(o2, 1)), r2 = this.nt(t2, "triangle", h2, i2), u2 = this.O(t2, 0), l2 = this.nt(t2, "sine", 2.003 * h2, u2), d2 = this.nt(t2, "sine", 3.007 * h2, u2), p2 = this.ct(t2, Math.max(-0.8, Math.min(0.8, (h2 - 261.6) / 800)));
340
+ return this.ut(u2.gain, 0, e2), this.lt(u2.gain, Math.max(1e-3, 0.15 * n2), e2 + 0.01), this.dt(u2.gain, 1e-3, e2 + Math.min(o2, 0.5)), u2.connect(p2), this.yt(t2, "sine", 60, p2, e2, Math.max(1e-3, 0.4 * n2), 0.05, 5e-3), i2.connect(p2).connect(c2), this.rt(e2, a2, r2, l2, d2), c2;
341
341
  }
342
342
  }
343
- class M extends p {
343
+ class _ extends p {
344
344
  constructor() {
345
- super(...arguments), this.xt = { v: 0.7, a: 5e-3, d: 0.5, m: 6 };
345
+ super(...arguments), this.Mt = { Tt: 0.7, xt: 5e-3, kt: 0.5, Vt: 6 };
346
346
  }
347
- Ut(t2, s2, i2, h2, e2, n2, r2, o2) {
348
- const a2 = this.ot(t2, u.Sine, 0, i2);
349
- this.dt(a2.frequency, 1.1 * e2, h2), this.Mt(a2.frequency, e2, h2 + 0.02);
350
- const c2 = this.P(t2, 0, s2);
351
- this.dt(c2.gain, Math.max(1e-3, 0.25 * n2), h2), this.Mt(c2.gain, 1e-3, h2 + r2);
352
- const l2 = this.ot(t2, u.Sine, 2.76 * e2, c2);
353
- c2.connect(s2), this.lt(h2, o2, a2, l2);
347
+ Dt(t2, s2, i2, e2, h2, n2, o2, a2) {
348
+ const c2 = this.nt(t2, "sine", 0, i2);
349
+ this.ut(c2.frequency, 1.1 * h2, e2), this.dt(c2.frequency, h2, e2 + 0.02);
350
+ const r2 = this.O(t2, 0, s2);
351
+ this.ut(r2.gain, Math.max(1e-3, 0.25 * n2), e2), this.dt(r2.gain, 1e-3, e2 + o2);
352
+ const u2 = this.nt(t2, "sine", 2.76 * h2, r2);
353
+ r2.connect(s2), this.rt(e2, a2, c2, u2);
354
354
  }
355
355
  }
356
- class f extends d {
356
+ class w extends d {
357
357
  constructor() {
358
- super(...arguments), this.xt = { v: 0.5, a: 0.05, r: 0.1 };
358
+ super(...arguments), this.Mt = { Tt: 0.5, xt: 0.05, Ut: 0.1, Vt: 10 };
359
359
  }
360
- l(t2, s2, i2, h2, e2, n2) {
361
- const r2 = t2.createGain(), o2 = this.gt(e2), a2 = Math.max(1e-3, n2 * o2.v);
362
- this.dt(r2.gain, 0, i2), this.yt(r2.gain, a2, i2 + o2.a);
363
- const c2 = Math.max(o2.a, e2);
364
- this.dt(r2.gain, a2, i2 + c2), this.yt(r2.gain, 1e-3, i2 + c2 + o2.r);
365
- const u2 = i2 + c2 + o2.r, l2 = this.Ut(t2, r2, i2, h2, n2, c2, o2.r, u2) || r2;
366
- l2.connect(s2), this.vt(t2, i2, u2 + 0.1, l2);
360
+ l(t2, s2, i2, e2, h2, n2) {
361
+ const o2 = t2.createGain(), a2 = this.At(h2), c2 = Math.max(1e-3, n2 * a2.Tt), r2 = a2.Vt ? Math.min(h2, a2.Vt) : h2;
362
+ this.ut(o2.gain, 0, i2), this.lt(o2.gain, c2, i2 + a2.xt);
363
+ const u2 = Math.max(a2.xt, r2);
364
+ this.ut(o2.gain, c2, i2 + u2), this.lt(o2.gain, 1e-3, i2 + u2 + a2.Ut);
365
+ const l2 = i2 + u2 + a2.Ut, d2 = this.Dt(t2, o2, i2, e2, n2, u2, a2.Ut, l2) || o2;
366
+ d2.connect(s2), this.ft(t2, i2, l2 + 0.1, d2);
367
367
  }
368
- gt(t2) {
369
- return this.xt;
368
+ At(t2) {
369
+ return this.Mt;
370
370
  }
371
371
  }
372
- class w extends f {
372
+ class S extends w {
373
373
  constructor() {
374
- super(...arguments), this.xt = { v: 0.4, a: 0.01, r: 0.05 };
374
+ super(...arguments), this.Mt = { Tt: 0.4, xt: 0.01, Ut: 0.05 };
375
375
  }
376
- Ut(t2, s2, i2, h2, e2, n2, r2, o2) {
377
- const a2 = this.ot(t2, u.Sine, h2, s2), c2 = this.P(t2, 0.5, s2), l2 = this.ot(t2, u.Sine, 2 * h2, c2), d2 = this.P(t2, 0.25, s2), p2 = this.ot(t2, u.Sine, 3 * h2, d2), y2 = this.P(t2, 0.7);
378
- return this.St(t2, 6.5, 0.3, i2, 0, o2, y2.gain), s2.connect(y2), this.ft(t2, u.Square, 4e3, y2, i2, Math.max(1e-3, 0.1 * e2), 0.015), this.lt(i2, o2, a2, l2, p2), y2;
376
+ Dt(t2, s2, i2, e2, h2, n2, o2, a2) {
377
+ const c2 = this.nt(t2, "sine", e2, s2), r2 = this.O(t2, 0.5, s2), u2 = this.nt(t2, "sine", 2 * e2, r2), l2 = this.O(t2, 0.25, s2), d2 = this.nt(t2, "sine", 3 * e2, l2), p2 = this.O(t2, 0.7);
378
+ return this.St(t2, 6.5, 0.3, i2, 0, a2, p2.gain), s2.connect(p2), this.yt(t2, "square", 4e3, p2, i2, Math.max(1e-3, 0.1 * h2), 0.015), this.rt(i2, a2, c2, u2, d2), p2;
379
379
  }
380
380
  }
381
- class _ extends p {
381
+ class f extends p {
382
382
  constructor() {
383
- super(...arguments), this.xt = { v: 0.6, a: 0.02, d: 0.2, m: 4 };
383
+ super(...arguments), this.Mt = { Tt: 0.6, xt: 0.02, kt: 0.2, Vt: 4 };
384
384
  }
385
- Ut(t2, s2, i2, h2, e2, n2, r2, o2) {
386
- const a2 = this.wt(t2, l.Lowpass, 2e3 + 1e3 * n2, 200, h2, r2), c2 = this.ot(t2, u.Sawtooth, 0, i2);
387
- return this.dt(c2.frequency, 1.02 * e2, h2), this.Mt(c2.frequency, e2, h2 + 0.05), i2.connect(a2), this.ft(t2, u.Square, 3500, s2, h2, Math.max(1e-3, 0.25 * n2), 0.015), this.lt(h2, o2, c2), a2;
385
+ Dt(t2, s2, i2, e2, h2, n2, o2, a2) {
386
+ const c2 = this._t(t2, "lowpass", 2e3 + 1e3 * n2, 200, e2, o2), r2 = this.nt(t2, "sawtooth", 0, i2);
387
+ return this.ut(r2.frequency, 1.02 * h2, e2), this.dt(r2.frequency, h2, e2 + 0.05), i2.connect(c2), this.yt(t2, "square", 3500, s2, e2, Math.max(1e-3, 0.25 * n2), 0.015), this.rt(e2, a2, r2), c2;
388
388
  }
389
389
  }
390
- class S extends p {
390
+ class m extends p {
391
391
  constructor() {
392
- super(...arguments), this.xt = { v: 0.5, a: 0.02, d: 0.2, m: 4 };
392
+ super(...arguments), this.Mt = { Tt: 0.5, xt: 0.02, kt: 0.2, Vt: 4 };
393
393
  }
394
- At(t2, s2, i2, h2, e2, n2) {
395
- this.Mt(t2, Math.max(1e-3, 0.4 * s2), i2 + Math.min(0.5, e2)), this.Mt(t2, 1e-3, i2 + e2 + n2);
394
+ gt(t2, s2, i2, e2, h2, n2) {
395
+ this.dt(t2, Math.max(1e-3, 0.4 * s2), i2 + Math.min(0.5, h2)), this.dt(t2, 1e-3, i2 + h2 + n2);
396
396
  }
397
- Ut(t2, s2, i2, h2, e2, n2, r2, o2) {
398
- const a2 = this.wt(t2, l.Lowpass, 2500 + 1500 * n2, 600, h2, r2), [c2, d2] = this._t(t2, u.Sawtooth, 0, 1, 0, i2);
399
- return this.dt(c2.frequency, 1.02 * e2, h2), this.Mt(c2.frequency, e2, h2 + 0.05), this.dt(d2.frequency, 1.022 * e2, h2), this.Mt(d2.frequency, 1.002 * e2, h2 + 0.05), this.St(t2, 5, 0.015 * e2, h2, 0.2, o2, c2.frequency, 0.4).connect(d2.frequency), i2.connect(a2), this.ft(t2, u.Square, 3500, s2, h2, Math.max(1e-3, 0.25 * n2), 0.015), this.lt(h2, o2, c2, d2), a2;
397
+ Dt(t2, s2, i2, e2, h2, n2, o2, a2) {
398
+ const c2 = this._t(t2, "lowpass", 2500 + 1500 * n2, 600, e2, o2), [r2, u2] = this.wt(t2, "sawtooth", 0, 1, 0, i2);
399
+ return this.ut(r2.frequency, 1.02 * h2, e2), this.dt(r2.frequency, h2, e2 + 0.05), this.ut(u2.frequency, 1.022 * h2, e2), this.dt(u2.frequency, 1.002 * h2, e2 + 0.05), this.St(t2, 5, 0.015 * h2, e2, 0.2, a2, r2.frequency, 0.4).connect(u2.frequency), i2.connect(c2), this.yt(t2, "square", 3500, s2, e2, Math.max(1e-3, 0.25 * n2), 0.015), this.rt(e2, a2, r2, u2), c2;
400
400
  }
401
401
  }
402
- class m extends p {
402
+ class M extends p {
403
403
  constructor() {
404
- super(...arguments), this.xt = { v: 0.8, a: 0.05, d: 0.1, m: 4 };
404
+ super(...arguments), this.Mt = { Tt: 0.8, xt: 0.05, kt: 0.1, Vt: 4 };
405
405
  }
406
- Ut(t2, s2, i2, h2, e2, n2, r2, o2) {
407
- const a2 = this.wt(t2, l.Lowpass, 300 + 500 * n2, 100, h2, r2), c2 = this.ot(t2, u.Sawtooth, 0, i2);
408
- this.dt(c2.frequency, 0.92 * e2, h2), this.Mt(c2.frequency, e2, h2 + 0.04);
409
- const d2 = this.P(t2, 0.6, i2), p2 = this.ot(t2, u.Sine, 0, d2);
410
- return this.dt(p2.frequency, e2 / 2 * 0.92, h2), this.Mt(p2.frequency, e2 / 2, h2 + 0.04), i2.connect(a2), this.lt(h2, o2, c2, p2), a2;
406
+ Dt(t2, s2, i2, e2, h2, n2, o2, a2) {
407
+ const c2 = this._t(t2, "lowpass", 300 + 500 * n2, 100, e2, o2), r2 = this.nt(t2, "sawtooth", 0, i2);
408
+ this.ut(r2.frequency, 0.92 * h2, e2), this.dt(r2.frequency, h2, e2 + 0.04);
409
+ const u2 = this.O(t2, 0.6, i2), l2 = this.nt(t2, "sine", 0, u2);
410
+ return this.ut(l2.frequency, h2 / 2 * 0.92, e2), this.dt(l2.frequency, h2 / 2, e2 + 0.04), i2.connect(c2), this.rt(e2, a2, r2, l2), c2;
411
411
  }
412
412
  }
413
- class v extends f {
414
- gt(t2) {
413
+ class T extends w {
414
+ bt(t2) {
415
415
  return { v: 0.3, a: t2 < 0.4 ? 0.05 : 0.2, r: t2 < 0.4 ? 0.1 : 0.5 };
416
416
  }
417
- Ut(t2, s2, i2, h2, e2, n2, r2, o2) {
418
- const [a2, c2] = this._t(t2, u.Sawtooth, h2, 1.005, 0.6, s2);
419
- this.St(t2, 4.5, 0.012 * h2, i2, 0.3, o2, a2.frequency).connect(c2.frequency);
420
- const d2 = this.wt(t2, l.Lowpass, h2 + 1200 + 1e3 * e2, h2 + 800, i2, n2 + r2);
421
- return s2.connect(d2), this.lt(i2, o2, a2, c2), d2;
417
+ Dt(t2, s2, i2, e2, h2, n2, o2, a2) {
418
+ const [c2, r2] = this.wt(t2, "sawtooth", e2, 1.005, 0.6, s2);
419
+ this.St(t2, 4.5, 0.012 * e2, i2, 0.3, a2, c2.frequency).connect(r2.frequency);
420
+ const u2 = this._t(t2, "lowpass", e2 + 1200 + 1e3 * h2, e2 + 800, i2, n2 + o2);
421
+ return s2.connect(u2), this.rt(i2, a2, c2, r2), u2;
422
422
  }
423
423
  }
424
- class x extends f {
424
+ class x extends w {
425
425
  constructor() {
426
- super(...arguments), this.xt = { v: 0.5, a: 0.1, r: 0.1 };
426
+ super(...arguments), this.Mt = { Tt: 0.5, xt: 0.1, Ut: 0.1 };
427
427
  }
428
- Ut(t2, s2, i2, h2, e2, n2, r2, o2) {
429
- const a2 = this.ot(t2, u.Square, 0, s2);
430
- this.dt(a2.frequency, 0.95 * h2, i2), this.Mt(a2.frequency, h2, i2 + 0.05);
431
- const c2 = this.P(t2, 0, s2);
432
- this.dt(c2.gain, 0, i2), this.yt(c2.gain, Math.max(1e-3, 0.25 * e2), i2 + 0.05), this.Mt(c2.gain, 1e-3, i2 + 0.2);
433
- const d2 = this.ot(t2, u.Sawtooth, 2 * h2, c2), p2 = this.ct(t2, l.Lowpass);
434
- return this.dt(p2.frequency, h2 + 400, i2), this.yt(p2.frequency, h2 + 1500 + 1e3 * e2, i2 + 0.1), this.Mt(p2.frequency, h2 + 400, i2 + n2 + r2), s2.connect(p2), this.lt(i2, o2, a2), this.lt(i2, i2 + 0.2, d2), p2;
428
+ Dt(t2, s2, i2, e2, h2, n2, o2, a2) {
429
+ const c2 = this.nt(t2, "square", 0, s2);
430
+ this.ut(c2.frequency, 0.95 * e2, i2), this.dt(c2.frequency, e2, i2 + 0.05);
431
+ const r2 = this.O(t2, 0, s2);
432
+ this.ut(r2.gain, 0, i2), this.lt(r2.gain, Math.max(1e-3, 0.25 * h2), i2 + 0.05), this.dt(r2.gain, 1e-3, i2 + 0.2);
433
+ const u2 = this.nt(t2, "sawtooth", 2 * e2, r2), l2 = this.ot(t2, "lowpass");
434
+ return this.ut(l2.frequency, e2 + 400, i2), this.lt(l2.frequency, e2 + 1500 + 1e3 * h2, i2 + 0.1), this.dt(l2.frequency, e2 + 400, i2 + n2 + o2), s2.connect(l2), this.rt(i2, a2, c2), this.rt(i2, i2 + 0.2, u2), l2;
435
435
  }
436
436
  }
437
- class g extends f {
437
+ class k extends w {
438
438
  constructor() {
439
- super(...arguments), this.xt = { v: 0.7, a: 0.05, r: 0.1 };
440
- }
441
- Ut(t2, s2, i2, h2, e2, n2, r2, o2) {
442
- const a2 = this.ot(t2, u.Sine, h2, s2), c2 = this.P(t2, 0, s2);
443
- this.dt(c2.gain, 0.3, i2), this.Mt(c2.gain, 0.05, i2 + 0.2);
444
- const d2 = this.ot(t2, u.Triangle, h2, c2), p2 = this.ct(t2, l.Lowpass);
445
- this.dt(p2.frequency, h2 + 800, i2);
446
- const y2 = this.St(t2, 5.5, 0.015 * h2, i2, 0.4, o2, a2.frequency);
447
- y2.connect(d2.frequency);
448
- const M2 = this.P(t2, 1), f2 = this.P(t2, 0.15, M2.gain);
449
- return y2.connect(f2), s2.connect(M2).connect(p2), this.lt(i2, o2, a2, d2), p2;
439
+ super(...arguments), this.Mt = { Tt: 0.7, xt: 0.05, Ut: 0.1 };
440
+ }
441
+ Dt(t2, s2, i2, e2, h2, n2, o2, a2) {
442
+ const c2 = this.nt(t2, "sine", e2, s2), r2 = this.O(t2, 0, s2);
443
+ this.ut(r2.gain, 0.3, i2), this.dt(r2.gain, 0.05, i2 + 0.2);
444
+ const u2 = this.nt(t2, "triangle", e2, r2), l2 = this.ot(t2, "lowpass");
445
+ this.ut(l2.frequency, e2 + 800, i2);
446
+ const d2 = this.St(t2, 5.5, 0.015 * e2, i2, 0.4, a2, c2.frequency);
447
+ d2.connect(u2.frequency);
448
+ const p2 = this.O(t2, 1), y2 = this.O(t2, 0.15, p2.gain);
449
+ return d2.connect(y2), s2.connect(p2).connect(l2), this.rt(i2, a2, c2, u2), l2;
450
450
  }
451
451
  }
452
- class A extends f {
452
+ class V extends w {
453
453
  constructor() {
454
- super(...arguments), this.xt = { v: 0.4, a: 0.05, r: 0.1 };
454
+ super(...arguments), this.Mt = { Tt: 0.4, xt: 0.05, Ut: 0.1 };
455
455
  }
456
- Ut(t2, s2, i2, h2, e2, n2, r2, o2) {
457
- const a2 = this.ot(t2, u.Sawtooth, 0);
458
- this.dt(a2.frequency, h2, i2), this.St(t2, 5, 0.02 * h2, i2, 0.2, o2, a2.frequency);
459
- const c2 = this.wt(t2, l.Lowpass, h2, 3 * h2, i2, 0.05);
460
- this.Mt(c2.frequency, 1.5 * h2, i2 + n2), c2.Q.value = 3, a2.connect(c2).connect(s2), this.lt(i2, o2, a2);
456
+ Dt(t2, s2, i2, e2, h2, n2, o2, a2) {
457
+ const c2 = this.nt(t2, "sawtooth", 0);
458
+ this.ut(c2.frequency, e2, i2), this.St(t2, 5, 0.02 * e2, i2, 0.2, a2, c2.frequency);
459
+ const r2 = this._t(t2, "lowpass", e2, 3 * e2, i2, 0.05);
460
+ this.dt(r2.frequency, 1.5 * e2, i2 + n2), r2.Q.value = 3, c2.connect(r2).connect(s2), this.rt(i2, a2, c2);
461
461
  }
462
462
  }
463
- class U extends f {
464
- gt(t2) {
463
+ class A extends w {
464
+ bt(t2) {
465
465
  return { v: 0.4, a: t2 < 0.4 ? 0.05 : 0.3, r: t2 < 0.4 ? 0.1 : 0.8 };
466
466
  }
467
- Ut(t2, s2, i2, h2, e2, n2, r2, o2) {
468
- const [a2, c2] = this._t(t2, u.Triangle, h2, 1.01, 0.7, s2), d2 = this.ct(t2, l.Lowpass);
469
- return this.dt(d2.frequency, h2 + 400, i2), this.yt(d2.frequency, h2 + 1e3 + 500 * e2, i2 + n2), this.St(t2, 0.5, 10, i2, 0, o2, c2.frequency), this.St(t2, 0.1, 400, i2, 0, o2, d2.frequency), s2.connect(d2), this.lt(i2, o2, a2, c2), d2;
467
+ Dt(t2, s2, i2, e2, h2, n2, o2, a2) {
468
+ const [c2, r2] = this.wt(t2, "triangle", e2, 1.01, 0.7, s2), u2 = this.ot(t2, "lowpass");
469
+ return this.ut(u2.frequency, e2 + 400, i2), this.lt(u2.frequency, e2 + 1e3 + 500 * h2, i2 + n2), this.St(t2, 0.5, 10, i2, 0, a2, r2.frequency), this.St(t2, 0.1, 400, i2, 0, a2, u2.frequency), s2.connect(u2), this.rt(i2, a2, c2, r2), u2;
470
470
  }
471
471
  }
472
- class b extends d {
473
- l(t2, s2, i2, h2, e2, n2) {
474
- const r2 = this.P(t2, 0), o2 = this.ot(t2, u.Sawtooth, 0, r2);
475
- this.dt(o2.frequency, h2, i2), this.Mt(o2.frequency, Math.max(1, h2 / 2), i2 + Math.max(0.05, e2));
476
- const a2 = this.P(t2, 0.5, s2);
477
- this.St(t2, 15, 0.5, i2, 0, i2 + e2 + 0.2, a2.gain), r2.connect(a2), this.dt(r2.gain, 0, i2), this.yt(r2.gain, Math.max(1e-3, 0.5 * n2), i2 + 0.05), this.Mt(r2.gain, 1e-3, i2 + e2 + 0.2), this.lt(i2, i2 + e2 + 0.2, o2), this.vt(t2, i2, i2 + e2 + 0.3, r2, a2);
472
+ class g extends d {
473
+ l(t2, s2, i2, e2, h2, n2) {
474
+ const o2 = this.O(t2, 0), a2 = this.nt(t2, "sawtooth", 0, o2);
475
+ this.ut(a2.frequency, e2, i2), this.dt(a2.frequency, Math.max(1, e2 / 2), i2 + Math.max(0.05, h2));
476
+ const c2 = this.O(t2, 0.5, s2);
477
+ this.St(t2, 15, 0.5, i2, 0, i2 + h2 + 0.2, c2.gain), o2.connect(c2), this.ut(o2.gain, 0, i2), this.lt(o2.gain, Math.max(1e-3, 0.5 * n2), i2 + 0.05), this.dt(o2.gain, 1e-3, i2 + h2 + 0.2), this.rt(i2, i2 + h2 + 0.2, a2), this.ft(t2, i2, i2 + h2 + 0.3, o2, c2);
478
478
  }
479
479
  }
480
- class R extends p {
480
+ class D extends p {
481
481
  constructor() {
482
- super(...arguments), this.xt = { v: 0.6, a: 0.02, d: 0.1, m: 4 };
482
+ super(...arguments), this.Mt = { Tt: 0.6, xt: 0.02, kt: 0.1, Vt: 4 };
483
483
  }
484
- Ut(t2, s2, i2, h2, e2, n2, r2, o2) {
485
- const a2 = this.ot(t2, u.Square, 0, i2);
486
- this.dt(a2.frequency, 1.05 * e2, h2), this.Mt(a2.frequency, e2, h2 + 0.08);
487
- const c2 = this.wt(t2, l.Bandpass, 2.5 * e2, e2, h2, r2);
488
- c2.Q.value = 2, c2.connect(i2), this.lt(h2, o2, a2);
484
+ Dt(t2, s2, i2, e2, h2, n2, o2, a2) {
485
+ const c2 = this.nt(t2, "square", 0, i2);
486
+ this.ut(c2.frequency, 1.05 * h2, e2), this.dt(c2.frequency, h2, e2 + 0.08);
487
+ const r2 = this._t(t2, "bandpass", 2.5 * h2, h2, e2, o2);
488
+ r2.Q.value = 2, r2.connect(i2), this.rt(e2, a2, c2);
489
489
  }
490
490
  }
491
- const _N = class _N extends d {
492
- static Rt(t2) {
493
- if (!_N.bt || _N.bt.sampleRate !== t2.sampleRate) {
494
- const s2 = 1 * t2.sampleRate, i2 = t2.createBuffer(1, s2, t2.sampleRate), h2 = i2.getChannelData(0);
495
- for (let t3 = 0; t3 < s2; t3++) h2[t3] = 2 * Math.random() - 1;
496
- _N.bt = i2;
491
+ const _U = class _U extends d {
492
+ static Ft(t2) {
493
+ if (!_U.vt || _U.vt.sampleRate !== t2.sampleRate) {
494
+ const s2 = 1 * t2.sampleRate, i2 = t2.createBuffer(1, s2, t2.sampleRate), e2 = i2.getChannelData(0);
495
+ for (let t3 = 0; t3 < s2; t3++) e2[t3] = 2 * Math.random() - 1;
496
+ _U.vt = i2;
497
497
  }
498
- return _N.bt;
498
+ return _U.vt;
499
499
  }
500
- l(t2, s2, i2, h2, e2, n2) {
501
- if (h2 < 70) {
502
- const h3 = this.P(t2, 0, s2), e3 = this.ot(t2, u.Sine, 0, h3);
503
- this.dt(e3.frequency, 150, i2), this.Mt(e3.frequency, 30, i2 + 0.1), this.dt(h3.gain, Math.max(1e-3, 1.5 * n2), i2), this.Mt(h3.gain, 1e-3, i2 + 0.5), this.lt(i2, i2 + 0.5, e3), this.vt(t2, i2, i2 + 0.6, h3);
500
+ l(t2, s2, i2, e2, h2, n2) {
501
+ if (e2 < 70) {
502
+ const e3 = this.O(t2, 0, s2), h3 = this.nt(t2, "sine", 0, e3);
503
+ this.ut(h3.frequency, 150, i2), this.dt(h3.frequency, 30, i2 + 0.1), this.ut(e3.gain, Math.max(1e-3, 1.5 * n2), i2), this.dt(e3.gain, 1e-3, i2 + 0.5), this.rt(i2, i2 + 0.5, h3), this.ft(t2, i2, i2 + 0.6, e3);
504
504
  } else {
505
- const e3 = h2 < 90, r2 = t2.createBufferSource();
506
- r2.buffer = _N.Rt(t2);
507
- const o2 = this.P(t2, 0, s2), a2 = this.ct(t2, e3 ? l.Bandpass : l.Highpass), c2 = this.ut(t2, e3 ? 0 : 0.6 * Math.random() - 0.3);
508
- if (a2.frequency.value = e3 ? 1500 : 5e3, this.dt(o2.gain, Math.max(1e-3, n2), i2), this.Mt(o2.gain, 1e-3, i2 + (e3 ? 0.2 : 0.05)), r2.connect(a2).connect(o2).connect(c2), this.lt(i2, i2 + (e3 ? 0.2 : 0.05), r2), e3) {
509
- const s3 = this.ot(t2, u.Triangle, 0, o2);
510
- this.dt(s3.frequency, 300, i2), this.Mt(s3.frequency, 100, i2 + 0.1), this.lt(i2, i2 + 0.2, s3);
511
- } else this.ft(t2, u.Square, 7e3, c2, i2, Math.max(1e-3, 0.2 * n2), 0.05);
512
- this.vt(t2, i2, i2 + 0.4, a2, o2, c2);
505
+ const h3 = e2 < 90, o2 = t2.createBufferSource();
506
+ o2.buffer = _U.Ft(t2);
507
+ const a2 = this.O(t2, 0, s2), c2 = this.ot(t2, h3 ? "bandpass" : "highpass"), r2 = this.ct(t2, h3 ? 0 : 0.6 * Math.random() - 0.3);
508
+ if (c2.frequency.value = h3 ? 1500 : 5e3, this.ut(a2.gain, Math.max(1e-3, n2), i2), this.dt(a2.gain, 1e-3, i2 + (h3 ? 0.2 : 0.05)), o2.connect(c2).connect(a2).connect(r2), this.rt(i2, i2 + (h3 ? 0.2 : 0.05), o2), h3) {
509
+ const s3 = this.nt(t2, "triangle", 0, a2);
510
+ this.ut(s3.frequency, 300, i2), this.dt(s3.frequency, 100, i2 + 0.1), this.rt(i2, i2 + 0.2, s3);
511
+ } else this.yt(t2, "square", 7e3, r2, i2, Math.max(1e-3, 0.2 * n2), 0.05);
512
+ this.ft(t2, i2, i2 + 0.4, c2, a2, r2);
513
513
  }
514
514
  }
515
515
  };
516
- _N.bt = null;
517
- let N = _N;
518
- class T extends f {
516
+ _U.vt = null;
517
+ let U = _U;
518
+ class b extends w {
519
519
  constructor() {
520
- super(...arguments), this.xt = { v: 0.6, a: 0.01, r: 0.1 };
520
+ super(...arguments), this.Mt = { Tt: 0.6, xt: 0.01, Ut: 0.1 };
521
521
  }
522
- Ut(t2, s2, i2, h2, e2, n2, r2, o2) {
523
- const a2 = this.ot(t2, u.Sine, h2, s2), c2 = 2 * h2, l2 = 4 * c2, d2 = this.P(t2, 0, a2.frequency);
524
- this.dt(d2.gain, l2 * e2, i2), this.Mt(d2.gain, 0.01, i2 + n2);
525
- const p2 = this.ot(t2, u.Sine, c2, d2);
526
- this.lt(i2, o2, a2, p2);
522
+ Dt(t2, s2, i2, e2, h2, n2, o2, a2) {
523
+ const c2 = this.nt(t2, "sine", e2, s2), r2 = 2 * e2, u2 = 4 * r2, l2 = this.O(t2, 0, c2.frequency);
524
+ this.ut(l2.gain, u2 * h2, i2), this.dt(l2.gain, 0.01, i2 + n2);
525
+ const d2 = this.nt(t2, "sine", r2, l2);
526
+ this.rt(i2, a2, c2, d2);
527
527
  }
528
528
  }
529
- class F extends p {
529
+ class v extends p {
530
530
  constructor() {
531
- super(...arguments), this.xt = { v: 0.6, a: 5e-3, d: 0.5, m: 5 };
532
- }
533
- Ut(t2, s2, i2, h2, e2, n2, r2, o2) {
534
- const a2 = [1, 0.6, 0.4, 0.2, 0.1];
535
- [1, 2.76, 5.4, 8.9, 13.3].forEach((s3, o3) => {
536
- const c2 = e2 * s3;
537
- if (c2 < 22e3) {
538
- const s4 = Math.max(1e-3, n2 * (1 / (o3 + 1.5))), e3 = Math.max(0.1, r2 * a2[o3]);
539
- this.ft(t2, u.Sine, c2, i2, h2, s4, e3, 5e-3);
531
+ super(...arguments), this.Mt = { Tt: 0.6, xt: 5e-3, kt: 0.5, Vt: 5 };
532
+ }
533
+ Dt(t2, s2, i2, e2, h2, n2, o2, a2) {
534
+ const c2 = [1, 0.6, 0.4, 0.2, 0.1];
535
+ [1, 2.76, 5.4, 8.9, 13.3].forEach((s3, a3) => {
536
+ const r2 = h2 * s3;
537
+ if (r2 < 22e3) {
538
+ const s4 = Math.max(1e-3, n2 * (1 / (a3 + 1.5))), h3 = Math.max(0.1, o2 * c2[a3]);
539
+ this.yt(t2, "sine", r2, i2, e2, s4, h3, 5e-3);
540
540
  }
541
541
  });
542
542
  }
543
543
  }
544
- class V extends d {
545
- l(t2, s2, i2, h2, e2, n2) {
546
- const r2 = 1 / h2, o2 = t2.createBuffer(1, Math.max(1, t2.sampleRate * r2), t2.sampleRate), a2 = o2.getChannelData(0);
547
- for (let t3 = 0; t3 < a2.length; t3++) a2[t3] = (2 * Math.random() - 1) * n2;
548
- const c2 = t2.createBufferSource();
549
- c2.buffer = o2;
550
- const u2 = t2.createDelay(r2);
551
- u2.delayTime.value = r2;
552
- const d2 = this.ct(t2, l.Lowpass);
553
- d2.frequency.value = Math.min(22e3, 6 * h2);
554
- const p2 = this.P(t2, 0.98);
555
- c2.connect(u2).connect(d2).connect(p2).connect(u2);
556
- const y2 = this.P(t2, 0, s2);
557
- this.dt(y2.gain, 1, i2), this.Mt(y2.gain, 1e-3, i2 + e2), u2.connect(y2), this.lt(i2, i2 + e2, c2), this.vt(t2, i2, i2 + e2 + 3, y2, u2, d2, p2);
544
+ class F extends d {
545
+ l(t2, s2, i2, e2, h2, n2) {
546
+ const o2 = 1 / e2, a2 = t2.createBuffer(1, Math.max(1, t2.sampleRate * o2), t2.sampleRate), c2 = a2.getChannelData(0);
547
+ for (let t3 = 0; t3 < c2.length; t3++) c2[t3] = (2 * Math.random() - 1) * n2;
548
+ const r2 = t2.createBufferSource();
549
+ r2.buffer = a2;
550
+ const u2 = t2.createDelay(o2);
551
+ u2.delayTime.value = o2;
552
+ const l2 = this.ot(t2, "lowpass");
553
+ l2.frequency.value = Math.min(22e3, 6 * e2);
554
+ const d2 = this.O(t2, 0.98);
555
+ r2.connect(u2).connect(l2).connect(d2).connect(u2);
556
+ const p2 = this.O(t2, 0, s2);
557
+ this.ut(p2.gain, 1, i2), this.dt(p2.gain, 1e-3, i2 + h2), u2.connect(p2), this.rt(i2, i2 + h2, r2), this.ft(t2, i2, i2 + h2 + 3, p2, u2, l2, d2);
558
558
  }
559
559
  }
560
- class B extends f {
560
+ class R extends w {
561
561
  constructor() {
562
- super(...arguments), this.xt = { v: 0.7, a: 0.05, r: 0.2 };
562
+ super(...arguments), this.Mt = { Tt: 0.7, xt: 0.05, Ut: 0.2 };
563
563
  }
564
- Ut(t2, s2, i2, h2, e2, n2, r2, o2) {
565
- const a2 = this.ct(t2, l.Lowpass);
566
- this.dt(a2.frequency, 2 * h2, i2), this.St(t2, 6, 3 * h2, i2, 0, o2, a2.frequency);
567
- const [c2, d2] = this._t(t2, u.Sawtooth, h2 / 2, 1.015, 0.4, a2);
568
- a2.connect(s2), this.lt(i2, o2, c2, d2);
564
+ Dt(t2, s2, i2, e2, h2, n2, o2, a2) {
565
+ const c2 = this.ot(t2, "lowpass");
566
+ this.ut(c2.frequency, 2 * e2, i2), this.St(t2, 6, 3 * e2, i2, 0, a2, c2.frequency);
567
+ const [r2, u2] = this.wt(t2, "sawtooth", e2 / 2, 1.015, 0.4, c2);
568
+ c2.connect(s2), this.rt(i2, a2, r2, u2);
569
569
  }
570
570
  }
571
- class D extends f {
571
+ class N extends w {
572
572
  constructor() {
573
- super(...arguments), this.xt = { v: 0.8, a: 0.1, r: 0.4 };
573
+ super(...arguments), this.Mt = { Tt: 0.8, xt: 0.1, Ut: 0.4 };
574
574
  }
575
- Ut(t2, s2, i2, h2, e2, n2, r2, o2) {
576
- const a2 = this.ot(t2, u.Sawtooth, h2);
577
- this.St(t2, 5, 0.015 * h2, i2, 0.2, o2, a2.frequency), [730, 1090, 2440].forEach((i3) => {
575
+ Dt(t2, s2, i2, e2, h2, n2, o2, a2) {
576
+ const c2 = this.nt(t2, "sawtooth", e2);
577
+ this.St(t2, 5, 0.015 * e2, i2, 0.2, a2, c2.frequency), [730, 1090, 2440].forEach((i3) => {
578
578
  if (i3 < 22e3) {
579
- const h3 = this.ct(t2, l.Bandpass);
580
- h3.frequency.value = i3, h3.Q.value = 12, a2.connect(h3).connect(s2);
579
+ const e3 = this.ot(t2, "bandpass");
580
+ e3.frequency.value = i3, e3.Q.value = 12, c2.connect(e3).connect(s2);
581
581
  }
582
- }), this.lt(i2, o2, a2);
582
+ }), this.rt(i2, a2, c2);
583
583
  }
584
584
  }
585
- class I extends f {
585
+ class q extends w {
586
586
  constructor() {
587
- super(...arguments), this.xt = { v: 0.4, a: 5e-3, r: 0.05 };
587
+ super(...arguments), this.Mt = { Tt: 0.4, xt: 5e-3, Ut: 0.05 };
588
588
  }
589
- Ut(t2, s2, i2, h2, e2, n2, r2, o2) {
590
- const a2 = this.ot(t2, u.Square, 0, s2);
591
- this.dt(a2.frequency, 2 * h2, i2), this.dt(a2.frequency, h2, i2 + 0.02), this.lt(i2, o2, a2);
589
+ Dt(t2, s2, i2, e2, h2, n2, o2, a2) {
590
+ const c2 = this.nt(t2, "square", 0, s2);
591
+ this.ut(c2.frequency, 2 * e2, i2), this.ut(c2.frequency, e2, i2 + 0.02), this.rt(i2, a2, c2);
592
592
  }
593
593
  }
594
- class L extends p {
594
+ class O extends p {
595
595
  constructor() {
596
- super(...arguments), this.xt = { v: 0.9, a: 5e-3, d: 0.15, m: 3 };
596
+ super(...arguments), this.Mt = { Tt: 0.9, xt: 5e-3, kt: 0.15, Vt: 3 };
597
597
  }
598
- Ut(t2, s2, i2, h2, e2, n2, r2, o2) {
599
- const a2 = this.wt(t2, l.Lowpass, 8 * e2 + 3e3 * n2, e2 + 100, h2, 0.1);
600
- a2.Q.value = 3;
601
- const c2 = this.ot(t2, u.Sawtooth, e2, i2), d2 = this.ot(t2, u.Sine, e2 / 2, i2);
602
- return this.ft(t2, u.Square, 3.5 * e2, a2, h2, Math.max(1e-3, 0.4 * n2), 0.04), i2.connect(a2), this.lt(h2, o2, c2, d2), a2;
598
+ Dt(t2, s2, i2, e2, h2, n2, o2, a2) {
599
+ const c2 = this._t(t2, "lowpass", 8 * h2 + 3e3 * n2, h2 + 100, e2, 0.1);
600
+ c2.Q.value = 3;
601
+ const r2 = this.nt(t2, "sawtooth", h2, i2), u2 = this.nt(t2, "sine", h2 / 2, i2);
602
+ return this.yt(t2, "square", 3.5 * h2, c2, e2, Math.max(1e-3, 0.4 * n2), 0.04), i2.connect(c2), this.rt(e2, a2, r2, u2), c2;
603
603
  }
604
604
  }
605
- const O = n([{ synth: new y(), start: 0, end: 7 }, { synth: new M(), start: 8, end: 15 }, { synth: new w(), start: 16, end: 23 }, { synth: new _(), start: 24, end: 26 }, { synth: new S(), start: 27, end: 31 }, { synth: new m(), start: 32, end: 39 }, { synth: new v(), start: 40, end: 55 }, { synth: new x(), start: 56, end: 71 }, { synth: new g(), start: 72, end: 79 }, { synth: new A(), start: 83, end: 87 }, { synth: new U(), start: 88, end: 95 }, { synth: new b(), start: 96, end: 103 }, { synth: new b(), start: 120, end: 127 }, { synth: new R(), start: 104, end: 111 }, { synth: new N(), start: 112, end: 119 }, { synth: new N(), start: 128, end: 128 }]), j = n([{ synth: new I(), start: 0, end: 127 }, { synth: new N(), start: 128, end: 128 }]);
606
- class q extends o {
605
+ const I = u([{ synth: new y(), start: 0, end: 7 }, { synth: new _(), start: 8, end: 15 }, { synth: new S(), start: 16, end: 23 }, { synth: new f(), start: 24, end: 26 }, { synth: new m(), start: 27, end: 31 }, { synth: new M(), start: 32, end: 39 }, { synth: new T(), start: 40, end: 55 }, { synth: new x(), start: 56, end: 71 }, { synth: new k(), start: 72, end: 79 }, { synth: new V(), start: 83, end: 87 }, { synth: new A(), start: 88, end: 95 }, { synth: new g(), start: 96, end: 103 }, { synth: new g(), start: 120, end: 127 }, { synth: new D(), start: 104, end: 111 }, { synth: new U(), start: 112, end: 119 }, { synth: new U(), start: 128, end: 128 }]), L = u([{ synth: new q(), start: 0, end: 127 }, { synth: new U(), start: 128, end: 128 }]);
606
+ class j extends h {
607
607
  constructor(t2, s2) {
608
- super(t2, s2 || O);
608
+ super(t2, s2 || I);
609
609
  }
610
610
  }
611
- class k extends a {
611
+ class C extends o {
612
612
  constructor(t2, s2) {
613
- super(t2, s2 || O);
613
+ super(t2, s2 || I);
614
614
  }
615
615
  }
616
- class X extends c {
616
+ class B extends a {
617
617
  constructor(t2, s2) {
618
- super(t2, s2 || O);
618
+ super(t2, s2 || I);
619
619
  }
620
620
  }
621
621
  export {
622
- F as AdditiveSynth,
623
- m as BassSynth,
622
+ v as AdditiveSynth,
623
+ M as BassSynth,
624
624
  x as BrassSynth,
625
- I as ChiptuneSynth,
626
- M as ChromaticPercussionSynth,
627
- N as DrumSynth,
628
- S as ElectricGuitarSynth,
629
- R as EthnicSynth,
630
- T as FMSynth,
631
- D as FormantSynth,
632
- _ as GuitarSynth,
633
- V as KarplusSynth,
634
- A as LeadSynth,
635
- O as MasterInstrumentMap,
636
- w as OrganSynth,
637
- U as PadSynth,
625
+ q as ChiptuneSynth,
626
+ _ as ChromaticPercussionSynth,
627
+ U as DrumSynth,
628
+ m as ElectricGuitarSynth,
629
+ D as EthnicSynth,
630
+ b as FMSynth,
631
+ N as FormantSynth,
632
+ f as GuitarSynth,
633
+ F as KarplusSynth,
634
+ V as LeadSynth,
635
+ I as MasterInstrumentMap,
636
+ S as OrganSynth,
637
+ A as PadSynth,
638
638
  y as PianoSynth,
639
- q as RLOCore,
640
- X as RLOGameEngine,
641
- k as RLOMusicPlayer,
642
- i as RLOTranspiler,
643
- B as ReeseBassSynth,
644
- j as RetroInstrumentMap,
645
- h as SilentSynth,
646
- L as SlapBassSynth,
647
- b as SoundEffectsSynth,
648
- O as StandardInstrumentMap,
649
- v as StringSynth,
650
- g as WoodwindSynth,
651
- e as createDirectMap,
652
- n as createInstrumentMap,
653
- r as extendInstrumentMap
639
+ j as RLOCore,
640
+ B as RLOGameEngine,
641
+ C as RLOMusicPlayer,
642
+ R as ReeseBassSynth,
643
+ L as RetroInstrumentMap,
644
+ c as SilentSynth,
645
+ O as SlapBassSynth,
646
+ g as SoundEffectsSynth,
647
+ I as StandardInstrumentMap,
648
+ T as StringSynth,
649
+ k as WoodwindSynth,
650
+ r as createDirectMap,
651
+ u as createInstrumentMap,
652
+ i as decodeBinary,
653
+ s as encodeToBinary,
654
+ t as encodeToSoA,
655
+ l as extendInstrumentMap
654
656
  };
655
657
  //# sourceMappingURL=rlo-engine.min.js.map