Hi. I’ve gotten about this far: Using lua to create 64 empty samples into an instrument. After that I need to click on DrumKit in the samplemappings. But how would I go about creating this drumkit-empty-sample-instrument directly without mouse clicking?
Also,extra bonus question: how do I copy the current table1 (note-on mappings) to table 2 (note-off mappings) so that I’m still able to retain control over say the pitch?
from what i understand it’s not a function you can trigger but it’s renoise going through each zone and applies an incrementing note range value for each sample.
for the 2nd question i wonder if you can just assign the 1nd layer table to the 2nd. probably not.
The note-on mappings are in table 1, the note-off mappings are in table 2.
Something like instruments[insno].mappings[2].x = instruments[insno].mappings[1].x
This is out of the back of my head, usually where it says [2] Taktik uses the constant NOTE_OFF and where it says [1] this represents [NOTE_ON].
Have a look at my slices to instruments script, it works with mappings pretty straight forward, or inspect MXB’s import script which also works with the layers.
The Drumkit mappings is something that you have to script completely from the ground up yourself. The drumkit function isn’t approachable through LUA.
You may be able to use some of the old code that i used for the extended drumkit mapper in 2.6, but the script is not Renoise 2.7 ready as it doesn’t deal with the layers.