KSP is a rather simple procedural scripting language for Native Instrument’s Kontakt e.g. to create your own Instruments like those you are probably using all day long already.
The on ui_control callback gets executed whenever any ui element is used. So it is an important callback when it comes to creating a custom UI. This articles explains all you need to know about this callback.
Read more »
The Basic code structure is very simple. We basicaly put most of our code into callbacks
All callbacks look like this on <callback> ... end on
In general the code inside callbacks gets executed when specific events happen. For example playing a note on our keyboard always executes the “on note” callback.
So callbacks build a framework for our instrument and are mostly needed to communicate with different parts of the Kontakt engine.
Like with any other programming languages in KSP there are also variables, arrays and constants.
They can only be declared inside the on init callback and can then be used throughout the whole script. So they are all on global scope by default and can even be used inside custom functions.
Read more »