Created
April 12, 2017 01:25
-
-
Save klahrich/41aea39eddbfc0b5424992ec08ba7244 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use_bpm 80 | |
k = 0 | |
k2 = 0 | |
beat_duration = 1 | |
live_loop :main do | |
k2 = 0 | |
2.times do | |
sleep beat_duration.to_f/2 | |
k2 = k2 + 1 | |
end | |
k = k + 1 | |
end | |
loop0 = Hash.new(){} | |
loop0[:hits] = [true, false, false, false, | |
true, false, true, false, | |
true, false, false, false, | |
false, false, false, false].ring | |
loop0[:beats]=4 | |
live_loop :loop0 do | |
sync :main | |
with_fx :distortion do | |
loop0[:hits].length.times do |i| | |
sample :drum_bass_hard, cutoff:130 - (i/4)*10 if loop0[:hits].tick | |
sleep beat_duration * loop0[:beats] / loop0[:hits].length.to_f | |
end | |
end | |
end | |
loop1 = Hash.new(){} | |
loop1[:hits] = [false, false, false, true, | |
false, false, false, false, | |
false, false, false, false, | |
true, false, false, false].ring | |
loop1[:beats]=4 | |
live_loop :loop1 do | |
sync :main | |
with_fx :echo, phase:0.25, mix:0.125 do | |
with_fx :krush do | |
with_fx :distortion, amp:5 do | |
loop1[:hits].length.times do | |
sample :drum_snare_hard, cutoff:[130, 100].ring.look if loop1[:hits].tick | |
sleep beat_duration * loop1[:beats] / loop1[:hits].length.to_f | |
end | |
end | |
end | |
end | |
end | |
loop2 = Hash.new(){} | |
loop2[:hits] = [true, true, false, false, | |
false, false, false, false, | |
false, true, true, false, | |
false, false, true, false].ring | |
loop2[:beats]=4 | |
live_loop :loop2 do | |
sync :main | |
with_fx :echo, phase:0.25, mix:0.125 do | |
with_fx :krush do | |
with_fx :distortion, amp:5 do | |
loop2[:hits].length.times do | |
sample :drum_cymbal_closed, cutoff:[130, 100, 70, 70].ring.look if loop2[:hits].tick | |
sleep beat_duration * loop2[:beats] / loop2[:hits].length.to_f | |
end | |
end | |
end | |
end | |
end | |
loop3 = Hash.new(){} | |
loop3[:hits] = [true, true, false, true, | |
true, false, true, true, | |
true, true, false, true, | |
true, false, true, true].ring | |
loop3[:cutoffs] = [70, 100, 0, 100, | |
110, 0, 90, 100, | |
70, 90, 0, 100, | |
90, 0, 80, 90].ring | |
loop3[:beats]=2 | |
live_loop :loop3 do | |
sync :main | |
loop3[:hits].length.times do | |
hit = loop3[:hits].tick | |
c = loop3[:cutoffs].look | |
sample :drum_cymbal_closed, cutoff:c if hit | |
sleep beat_duration * loop3[:beats] / loop3[:hits].length.to_f | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment