Before you start scripting you should create a resource container where you put in all your files you need for your instrument (e.g graphic files or impulse responses etc.)
- start Kontakt and create a new instrument
- save your instrument into a new folder
- click on the wrench button, click on “instrument options” and click “create” (left image)
- chose the folder you have just stored your nki/instrument into and enter a name for the resource container. Click “save”
- when you are getting asked to create one, confirm it
Kontakt automatically creates a “Resources” folder and a “nkr” file. Both have the same purpose: they both contain all resources for your instrument like graphics, impulse responses or scripts. However you can only access the Resources folder and each time you click on the create button again, Kontakt will transfer (and “encrypt”) your resources into the “.nkr” file. Assuming that you have put in all your files correctly into the “Resources” folder and for pictures you also need to add a little text file for each picture (see below):
- you have to store all graphics or images into Resources\pictures\
- all impulse responses into Resources\ir_samples\
- scripts to be included into Resources\scripts\
- for each image you also have to add a *.txt file into Resources\pictures with the images’s filename. The text file is declaring the properties of the related image. So assuming you store an image called “wallpaper.png” you also have to add a “wallpaper.txt” with this content:
Has Alpha Channel: yes Number of Animations: 0 Horizontal Animation: no Vertical Resizable: no Horizontal Resizable: no Fixed Top: 0 Fixed Bottom: 0 Fixed Left: 0 Fixed Right: 0
the txt file should be in UTF-8 or ANSI.
When you open your instrument (nki), Kontakt will first look into the Resources folder. Only if Kontakt can’t find any files there, it will proceed looking into the nkr file. So the Resources folder has always priority which is very useful for developers because you don’t need to update the resources container (the nkr file) again and again after adding only one new file.
Purpose of the nkr file – publishing your instrument
Why do we need the nkr file at all? The nkr file simply “hides” and locks all your resources. There are many reasons for not letting everyone access your resources for example because probably you may not want others to use them for their own projects or you don’t want others to edit your files. So before publishing your instrument simply hit the “create” button again, check if all resources have been included into the nkr file and publish your instrument folder without the Resources folder (nki, nkr, nkc file + your samples).
Unless you want to share all your resources of course. In this case simply share your whole instrument folder including your Resources folder.
It’s also recommended to test if all files are included in the nkr file there before publishing your instrument. For this just copy your instrument folder (without the resources folder) to another location on your hard drive. Open the instrument (nki) from the new location and check if anything is missing. The most obvious you will notice instantly are missing images.