Skip to content

Commit

Permalink
changed the behavior of reloop
Browse files Browse the repository at this point in the history
  • Loading branch information
h67ma committed Sep 4, 2021
1 parent 8b7a3b9 commit 3b7c39c
Showing 1 changed file with 13 additions and 10 deletions.
23 changes: 13 additions & 10 deletions res/controllers/Numark-Mixtrack-Pro-FX-scripts.js
Original file line number Diff line number Diff line change
Expand Up @@ -290,21 +290,24 @@ MixtrackProFX.Deck = function(number) {
this.loop = new components.Button({
outKey: "loop_enabled",
midi: [0x94 + channel, 0x40],
shift: function() {
this.inKey = "loop_in_goto";
this.input = components.Button.prototype.input;
},
unshift: function() {
this.input = function(channel, control, value, status, group) {
if (!this.isPress(channel, control, value)) {
return;
}
input: function(channel, control, value, status, group) {
if (!this.isPress(channel, control, value)) {
return;
}

if (!MixtrackProFX.shifted) {
if (engine.getValue(group, "loop_enabled") === 0) {
script.triggerControl(group, "beatloop_activate");
} else {
script.triggerControl(group, "beatlooproll_activate");
}
};
} else {
if (engine.getValue(group, "loop_enabled") === 0) {
script.triggerControl(group, "reloop_toggle");
} else {
script.triggerControl(group, "reloop_andstop");
}
}
},
shiftControl: true,
sendShifted: true,
Expand Down

0 comments on commit 3b7c39c

Please sign in to comment.