How do I script outputs for the kontakt sampler?

I'm designing a sample based plugin within Kontakt for a uni project.
So far I've coded basic volume sliders, bypass buttons, and effects knobs. As my sample based instrument are drums, I want to have a drop down menu section for each element of the kit, which has options for routing within kontakt, to then go to whatever DAW it is in, similar to how GGD is setup and able to be routed to multiple tracks.
Ideally, within the drop down menus, I want there to be a "Default" option for each element of the kit, which routes just to the first stereo output within Kontakt (1/2, or whatever it is), so that default is set for all tracks, but then within the dropdown menus, I want the other outputs within kontakt to be available.
Is there a simpler way to make multi channel outputs possible via scripting? I've routed my sample groups to buses, and I'll try to show how I've done that in an attachment here.
This is the first time I've ever written a script or code for something, so forgive me if this is all a bit strange/stupid, or out of the ordinary.
Thanks for the help.
Comments
-
Here's an updated version of my script
on initmake_perfview
set_ui_height_px (232)
set_ui_width_px (1000)
declare ui_slider $Kick (0, 1000000)
move_control_px ($Kick, 528,46)
make_persistent ($Kick)
declare ui_slider $Snare1 (0, 1000000)
move_control_px ($Snare1, 528,63)
make_persistent ($Snare1)
declare ui_slider $Snare2 (0, 1000000)
move_control_px ($Snare2, 528,80)
make_persistent ($Snare2)
declare ui_slider $Hats1 (0, 1000000)
move_control_px ($Hats1, 528,97)
make_persistent ($Hats1)
declare ui_slider $Hats2 (0, 1000000)
move_control_px ($hats2, 528,114)
make_persistent ($Hats2)
declare ui_slider $RackTom (0, 1000000)
move_control_px ($RackTom, 528,131)
make_persistent ($RackTom)
declare ui_slider $FloorTom (0, 1000000)
move_control_px ($FloorTom, 528,148)
make_persistent ($FloorTom)
declare ui_slider $Crash1 (0, 1000000)
move_control_px ($Crash1, 528,165)
make_persistent ($Crash1)
declare ui_slider $Crash2 (0, 1000000)
move_control_px ($Crash2, 528,182)
make_persistent ($Crash2)
declare ui_slider $Ride1 (0, 1000000)
move_control_px ($Ride1, 528,198)
make_persistent ($Ride1)
declare ui_slider $Ride2 (0, 1000000)
move_control_px ($Ride2, 528,214)
make_persistent ($Ride2)
declare ui_knob $Warmth (0, 1000000,1)
make_persistent ($Warmth)
move_control_px ($Warmth, 750, 45)
declare ui_knob $Time (0, 1000000, 1)
make_persistent ($Time)
move_control_px ($Time, 840, 45)
declare ui_knob $DelayFeedback (0, 1000000, 1)
make_persistent ($DelayFeedback)
move_control_px ($DelayFeedback, 870, 110)
set_text ($DelayFeedback, "Delay FB")
declare ui_knob $Decay (0, 1000000, 1)
make_persistent ($Decay)
move_control_px ($Decay, 920, 45)
declare ui_button $TapeBypass
move_control_px ($TapeBypass, 745, 82)
make_persistent ($TapeBypass)
set_text ($TapeBypass, "Tape Bypass")
declare ui_button $DelayBypass
move_control_px ($DelayBypass, 830, 82)
make_persistent ($DelayBypass)
set_text ($DelayBypass, "Delay Bypass")
declare ui_button $ReverbBypass
move_control_px ($ReverbBypass, 915, 82)
make_persistent ($ReverbBypass)
set_text ($ReverbBypass, "Reverb Bypass")
declare const $GROUP_KICK := 0
declare const $GROUP_SNARE_CENTER := 1
declare const $GROUP_SNARE_RIM := 2
declare const $GROUP_HATS_CLOSED := 3
declare const $GROUP_HATS_OPEN := 4
declare const $GROUP_RACK_TOM := 5
declare const $GROUP_FLOOR_TOM := 6
declare const $GROUP_CRASH := 7
declare const $GROUP_CRASH_BELL := 8
declare const $GROUP_RIDE := 9
declare const $GROUP_RIDE_BELL := 10
declare const $BUS_KICK := 1
declare const $BUS_SNARE := 2
declare const $BUS_HATS := 3
declare const $BUS_RACK := 4
declare const $BUS_FLOOR := 5
declare const $BUS_CRASH := 6
declare const $BUS_RIDE := 7
declare ui_menu $Output_Kick
move_control_px($Output_Kick, 768, 115)
make_persistent ($Output_Kick)
declare ui_menu $Output_Snare
move_control_px($Output_Snare, 768, 130)
make_persistent ($Output_Snare)
declare ui_menu $Output_HH
move_control_px($Output_HH, 768, 145)
make_persistent ($Output_HH)
declare ui_menu $Output_Rack
move_control_px($Output_Rack, 768, 160)
make_persistent ($Output_Rack)
declare ui_menu $Output_Floor
move_control_px($Output_Floor, 768, 175)
make_persistent ($Output_Floor)
declare ui_menu $Output_Crash
move_control_px($Output_Crash, 768, 190)
make_persistent ($Output_Crash)
declare ui_menu $Output_Ride
move_control_px($Output_Ride, 768, 205)
make_persistent ($Output_Ride)
add_menu_item($Output_Kick, "Default (1/2)", 0)
add_menu_item($Output_Snare, "Default (1/2)", 0)
add_menu_item($Output_HH, "Default (1/2)", 0)
add_menu_item($Output_Rack, "Default (1/2)", 0)
add_menu_item($Output_Floor, "Default (1/2)", 0)
add_menu_item($Output_Crash, "Default (1/2)", 0)
add_menu_item($Output_Ride, "Default (1/2)", 0)
declare $i
declare $output_id
declare $output_name
add_menu_item($Output_Kick, $output_name, $output_id)
add_menu_item($Output_Snare, $output_name, $output_id)
add_menu_item($Output_HH, $output_name, $output_id)
add_menu_item($Output_Rack, $output_name, $output_id)
add_menu_item($Output_Floor, $output_name, $output_id)
add_menu_item($Output_Crash, $output_name, $output_id)
add_menu_item($Output_Ride, $output_name, $output_id)
$Output_Kick := 0
$Output_Snare := 0
$Output_HH := 0
$Output_Rack := 0
$Output_Floor := 0
$Output_Crash := 0
$Output_Ride := 0
end on
on ui_control ($Kick)
set_engine_par ($ENGINE_PAR_VOLUME,$Kick,0,-1,-1)
end on
on ui_control ($Snare1)
set_engine_par ($ENGINE_PAR_VOLUME,$Snare1,1,-1,-1)
end on
on ui_control ($Snare2)
set_engine_par ($ENGINE_PAR_VOLUME,$Snare2,2,-1,-1)
end on
on ui_control ($Hats1)
set_engine_par ($ENGINE_PAR_VOLUME,$Hats1,3,-1,-1)
end on
on ui_control ($Hats2)
set_engine_par ($ENGINE_PAR_VOLUME,$Hats2,4,-1,-1)
end on
on ui_control ($RackTom)
set_engine_par ($ENGINE_PAR_VOLUME,$RackTom,5,-1,-1)
end on
on ui_control ($FloorTom)
set_engine_par ($ENGINE_PAR_VOLUME,$FloorTom,6,-1,-1)
end on
on ui_control ($Crash1)
set_engine_par ($ENGINE_PAR_VOLUME,$Crash1,7,-1,-1)
end on
on ui_control ($Crash2)
set_engine_par ($ENGINE_PAR_VOLUME,$Crash2,8,-1,-1)
end on
on ui_control ($Ride1)
set_engine_par ($ENGINE_PAR_VOLUME,$Ride1,9,-1,-1)
end on
on ui_control ($Ride2)
set_engine_par ($ENGINE_PAR_VOLUME,$Ride2,10,-1,-1)
end on
on ui_control ($Warmth)
set_engine_par ($ENGINE_PAR_TP_WARMTH , $Warmth, -1, 0, 1)
end on
on ui_control ($Time)
set_engine_par ($ENGINE_PAR_PSYDL_TIME , $Time, -1, 1, 1)
end on
on ui_control ($DelayFeedback)
set_engine_par ($ENGINE_PAR_PSYDL_FEEDBACK , $DelayFeedback, -1, 1, 1)
end on
on ui_control ($Decay)
set_engine_par ($ENGINE_PAR_PR_DECAY , $Decay, -1, 2, 1)
end on
on ui_control ($TapeBypass)
if ($TapeBypass=1)
set_engine_par ($ENGINE_PAR_EFFECT_BYPASS, 1, -1, 0, 0)
else
set_engine_par($ENGINE_PAR_EFFECT_BYPASS, 0, -1, 0, 0)
end if
end on
on ui_control ($DelayBypass)
if ($DelayBypass=1)
set_engine_par ($ENGINE_PAR_EFFECT_BYPASS, 1, -1, 1, 0)
else
set_engine_par($ENGINE_PAR_EFFECT_BYPASS, 0, -1, 1, 0)
end if
end on
on ui_control ($ReverbBypass)
if ($ReverbBypass=1)
set_engine_par ($ENGINE_PAR_EFFECT_BYPASS, 1, -1, 2, 0)
else
set_engine_par($ENGINE_PAR_EFFECT_BYPASS, 0, -1, 2, 0)
end if
end on
0
Categories
- All Categories
- 18 Welcome
- 1.6K Hangout
- 66 NI News
- 858 Tech Talks
- 4.4K Native Access
- 17.5K Komplete
- 2.1K Komplete General
- 4.6K Komplete Kontrol
- 6.1K Kontakt
- 1.6K Reaktor
- 398 Battery 4
- 887 Guitar Rig & FX
- 450 Massive X & Synths
- 1.4K Other Software & Hardware
- 6.1K Maschine
- 7.8K Traktor
- 7.8K 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