From 5548d30da8f54bdff31593e017bd89c4e1966ad5 Mon Sep 17 00:00:00 2001 From: Raphael Forment Date: Sun, 14 Apr 2024 23:58:40 +0200 Subject: [PATCH] Fixing some more broken stuff --- src/API/API.ts | 2 ++ src/Docs/learning/time/linear_time.ts | 2 +- src/Docs/patterns/patterns.ts | 6 +++--- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/API/API.ts b/src/API/API.ts index 74a42fd..72f826e 100644 --- a/src/API/API.ts +++ b/src/API/API.ts @@ -229,6 +229,7 @@ export class UserAPI { randI: any; rand: any; ir: any; + irand: any; r: any; seed: any; localSeededRandom: any; @@ -401,6 +402,7 @@ export class UserAPI { this.scope = Canvas.scope(this.app); this.randI = Randomness.randI(this); this.ir = this.randI; + this.irand = this.randI; this.rand = Randomness.rand(this); this.r = this.rand; this.seed = Randomness.seed(this); diff --git a/src/Docs/learning/time/linear_time.ts b/src/Docs/learning/time/linear_time.ts index ae9beb1..7c580e3 100644 --- a/src/Docs/learning/time/linear_time.ts +++ b/src/Docs/learning/time/linear_time.ts @@ -177,7 +177,7 @@ oncount([1,3,5.5,7,7.5,8],8) :: sound('hh').gain(irand(1.0,4.0)).out() ${makeExample( "Using oncount to create rhythms with a custom meter", ` -bpm(200) +tempo(200) oncount([1, 5, 9, 13],16) :: sound('808bd').n(4).shape(0.5).gain(1.0).out() oncount([5, 6, 13],16) :: sound('shaker').room(0.25).gain(0.9).out() oncount([2, 3, 3.5, 6, 7, 10, 15],16) :: sound('hh').n(8).gain(0.8).out() diff --git a/src/Docs/patterns/patterns.ts b/src/Docs/patterns/patterns.ts index 1b25690..1460644 100644 --- a/src/Docs/patterns/patterns.ts +++ b/src/Docs/patterns/patterns.ts @@ -184,7 +184,7 @@ ${makeExample( "Play pitches from scale created from cent intervals", ` rhythm([0.5,0.25].beat(1),14,16) :: sound('pluck') - .stretch(iR(1,5)).pitch(iR(0,6)).key(57) + .stretch(ir(1,5)).pitch(ir(0,6)).key(57) .cents(120,270,540,670,785,950,1215).out() `, true, @@ -213,8 +213,8 @@ flipbar(1) :: rhythm(.25,14,16) :: sound("ST10:30").stretch(3).gain(0.5) .octave(r(-6,6)) .edo(666,"rocritonic") .out() -rhythm(2.0,26,32) :: sound("ST20").n([22,5,24,34,31,5,11,19].pick()).stretch(rI(1,6)) -.pitch(rI(127,300)) +rhythm(2.0,26,32) :: sound("ST20").n([22,5,24,34,31,5,11,19].pick()).stretch(ir(1,6)) +.pitch(ir(127,300)) .edo(666) .out() `,