drums uses all limbs

master
Matthew Huntington 3 years ago
parent 2ca96d0177
commit 104b6f0880

@ -1,15 +1,21 @@
const numBeats = Math.ceil(Math.random()*9); const numBeats = Math.ceil(Math.random()*9);
let resultString = ''; let resultString = '';
const instructionPosibilities = [ 'n', 'p', 'm', 'b' ] const appendages = [ 'lh', 'rh', 'lf', 'rf' ];
for(let appendage of appendages){
let resultString = '';
for(let i = 1; i <= numBeats; i++){ for(let i = 1; i <= numBeats; i++){
const instructionIndex = Math.floor(Math.random()*instructionPosibilities.length); const hit = Math.floor(Math.random()*2);
if(hit === 1){
resultString += instructionPosibilities[instructionIndex] + ' '; resultString += appendage + ' ';
} else {
resultString += ' ';
} }
}
console.log(resultString); console.log(resultString);
}
const breakDown = (node)=>{ const breakDown = (node)=>{

Loading…
Cancel
Save