Note off on stop.
This commit is contained in:
parent
bcf68eb32a
commit
806324e7b1
|
@ -103,6 +103,12 @@ function timer:action_cb()
|
|||
matrix.redraw="YES"
|
||||
end
|
||||
|
||||
function silence()
|
||||
for i=1,#instruments do
|
||||
midiwire.note_off(mout, instruments[i][2], chan)
|
||||
end
|
||||
end
|
||||
|
||||
function playbtn:action()
|
||||
bpm.active="NO"
|
||||
factor.active="NO"
|
||||
|
@ -116,6 +122,7 @@ function stopbtn:action()
|
|||
len.active="YES"
|
||||
timer.run="NO"
|
||||
-- todo - tohle lépe
|
||||
silence()
|
||||
if step==1 then
|
||||
matrix:setcell(9, LEN-1, "")
|
||||
else
|
||||
|
@ -218,6 +225,7 @@ function pat_recall(patno)
|
|||
if not patterns[patno] then return end
|
||||
local was_running = timer.run == "YES"
|
||||
timer.run="NO" -- pause while recalling to not glitch
|
||||
silence()
|
||||
for x=1,8 do
|
||||
patterns[patno][x] = patterns[patno][x] or {}
|
||||
for y=1,32 do
|
||||
|
|
Loading…
Reference in New Issue