on persistence_changed, select button
Hi everybody! I'm looking to select a button by default. I'd been using an "on persistence_changed" then "play_note" to trigger a keyswitch
on persistence_changed play_note (0,127,0,0) end on
But as EvilDragon pointed out, this play_note interferes with the ks_list. And I'd much rather select a button on default, something like this...
on persistence_changed sel_btn = 0 end on
Does anyone have any suggestions on how to do this properly? Thank you!
Best Answer
-
If you have your keyswitch stored in a persistent variable, all you need to do is loop through all your (I'm assuming articulation) buttons and set the right one to 1. For example:
for i := 0 to NUM_ARTICS - 1 if i = sel_ks ID[i] -> value := 1 else ID[i] -> value := 0 end if end for
This example assumes SublimeKSP usage.
Also, in this case, your buttons don't even need to be made persistent, as long as your
sel_ks
is persistent.1
Answers
-
If you have your keyswitch stored in a persistent variable, all you need to do is loop through all your (I'm assuming articulation) buttons and set the right one to 1. For example:
for i := 0 to NUM_ARTICS - 1 if i = sel_ks ID[i] -> value := 1 else ID[i] -> value := 0 end if end for
This example assumes SublimeKSP usage.
Also, in this case, your buttons don't even need to be made persistent, as long as your
sel_ks
is persistent.1
Categories
- All Categories
- 19 Welcome
- 1.5K Hangout
- 62 NI News
- 785 Tech Talks
- 4.1K Native Access
- 16.6K Komplete
- 2K Komplete General
- 4.3K Komplete Kontrol
- 5.7K Kontakt
- 1.6K Reaktor
- 379 Battery 4
- 846 Guitar Rig & FX
- 429 Massive X & Synths
- 1.3K Other Software & Hardware
- 5.8K Maschine
- 7.3K Traktor
- 7.3K Traktor Software & Hardware
- Check out everything you can do
- Create an account
- See member benefits
- Answer questions
- Ask the community
- See product news
- Connect with creators