set_script_title("VIP")
make_perfview
set_ui_height_px(532)
message("")
set_control_par_str($INST_WALLPAPER_ID,$CONTROL_PAR_PICTURE,"background")
set_key_color(24,$KEY_COLOR_RED)
set_key_color(25,$KEY_COLOR_RED)
set_key_color(26,$KEY_COLOR_RED)
set_key_color(27,$KEY_COLOR_RED)
set_key_color(28,$KEY_COLOR_RED)
set_key_color(29,$KEY_COLOR_RED)
set_key_color(30,$KEY_COLOR_RED)
set_key_color(32,$KEY_COLOR_NONE)
set_key_color(34,$KEY_COLOR_NONE)
declare $PitchSwitch
declare $SkinOffset := 600
declare $i
declare $ii
declare $count
declare $c
declare $ANIMplay := 0
declare ui_label $Anim(0, 0)
move_control_px($Anim,119,207)
set_control_par_str(get_ui_id($Anim),$CONTROL_PAR_TEXT,"")
set_control_par_str(get_ui_id($Anim),$CONTROL_PAR_PICTURE,"Key Animation")
set_control_par(get_ui_id($Anim),$CONTROL_PAR_WIDTH,500)
set_control_par(get_ui_id($Anim),$CONTROL_PAR_HEIGHT,20)
set_listener($NI_SIGNAL_TIMER_MS,50000)
declare $ANIMplay2 := 0
declare ui_label $Anim2(0, 0)
move_control_px($Anim2,0,28)
set_control_par_str(get_ui_id($Anim2),$CONTROL_PAR_TEXT,"")
set_control_par_str(get_ui_id($Anim2),$CONTROL_PAR_PICTURE,"Load Animation")
set_control_par(get_ui_id($Anim2),$CONTROL_PAR_WIDTH,500)
set_control_par(get_ui_id($Anim2),$CONTROL_PAR_HEIGHT,20)
pgs_create_key(INITa, 1)
pgs_create_key(MONOLEGATOv, 5)
pgs_create_key(UNICHECK, 1)
pgs_create_key(INITb, 1)
pgs_create_key(CHORD, 8)
pgs_create_key(CHORDx, 1)
declare $ActiveArpPage
declare $ActiveTab
make_persistent($ActiveTab)
read_persistent_var($ActiveTab)
declare %main[29]
declare %main2[29]
declare %tfx[7]
declare %arp[120]
declare $steps := 16
declare $gate_length
{TFX}
make_persistent($tfx1)
read_persistent_var($tfx1)
make_persistent($tfx2)
read_persistent_var($tfx2)
make_persistent($tfx3)
read_persistent_var($tfx3)
make_persistent($tfx4)
read_persistent_var($tfx4)
make_persistent($tfx5)
read_persistent_var($tfx5)
make_persistent($tfx6)
read_persistent_var($tfx6)
make_persistent($tfx7)
read_persistent_var($tfx7)
%tfx[0] := get_ui_id($tfx1)
%tfx[1] := get_ui_id($tfx2)
%tfx[2] := get_ui_id($tfx3)
%tfx[3] := get_ui_id($tfx4)
%tfx[4] := get_ui_id($tfx5)
%tfx[5] := get_ui_id($tfx6)
%tfx[6] := get_ui_id($tfx7)
$i := 0
while ($i < 7)
set_control_par_str(%tfx[$i],$CONTROL_PAR_TEXT,"")
set_control_par(%tfx[$i],$CONTROL_PAR_WIDTH,115)
set_control_par(%tfx[$i],$CONTROL_PAR_HEIGHT,115)
inc ($i)
end while
set_control_par_str(%tfx[0],$CONTROL_PAR_PICTURE,"KFX Small")
set_control_par_str(%tfx[1],$CONTROL_PAR_PICTURE,"KFX Big")
set_control_par_str(%tfx[2],$CONTROL_PAR_PICTURE,"KFX Small")
set_control_par_str(%tfx[3],$CONTROL_PAR_PICTURE,"KFX Big")
set_control_par_str(%tfx[4],$CONTROL_PAR_PICTURE,"KFX Small")
set_control_par_str(%tfx[5],$CONTROL_PAR_PICTURE,"KFX Small")
set_control_par_str(%tfx[6],$CONTROL_PAR_PICTURE,"KFX Big")
{set_control_par_str(%tfx[0],$CONTROL_PAR_PICTURE,"EQ sweep")
set_control_par_str(%tfx[1],$CONTROL_PAR_PICTURE,"Pitch Env")
set_control_par_str(%tfx[2],$CONTROL_PAR_PICTURE,"glitcher")
set_control_par_str(%tfx[3],$CONTROL_PAR_PICTURE,"cabinet")
set_control_par_str(%tfx[4],$CONTROL_PAR_PICTURE,"panner")
set_control_par_str(%tfx[5],$CONTROL_PAR_PICTURE,"filter")
set_control_par_str(%tfx[6],$CONTROL_PAR_PICTURE,"dirt")}
move_control_px($tfx1,32,420)
move_control_px($tfx2,64,295)
move_control_px($tfx3,146,435)
move_control_px($tfx4,275,275)
move_control_px($tfx5,417,435)
move_control_px($tfx6,530,420)
move_control_px($tfx7,483,300)
{NAVIGATION}
{ENV}
declare ui_slider $attack(5000, 1000000)
move_control_px($attack,15,278)
set_control_par_str(get_ui_id($attack),$CONTROL_PAR_TEXT,"")
set_control_par_str(get_ui_id($attack),$CONTROL_PAR_PICTURE,"Big Red Knob")
set_control_par(get_ui_id($attack),$CONTROL_PAR_WIDTH,55)
set_control_par(get_ui_id($attack),$CONTROL_PAR_HEIGHT,55)
set_control_par(get_ui_id($attack),$CONTROL_PAR_MOUSE_BEHAVIOUR,-800)
set_control_par(get_ui_id($attack),$CONTROL_PAR_DEFAULT_VALUE,5000)
make_persistent($attack)
read_persistent_var($attack)
%main[0] := get_ui_id($attack)
{FILTERS}
declare ui_slider $LPFilterCutoff(0, 1000000)
move_control_px($LPFilterCutoff,19,410)
set_control_par_str(get_ui_id($LPFilterCutoff),$CONTROL_PAR_TEXT,"")
set_control_par_str(get_ui_id($LPFilterCutoff),$CONTROL_PAR_PICTURE,"Purple
Knob")
set_control_par(get_ui_id($LPFilterCutoff),$CONTROL_PAR_WIDTH,45)
set_control_par(get_ui_id($LPFilterCutoff),$CONTROL_PAR_HEIGHT,45)
set_control_par(get_ui_id($LPFilterCutoff),$CONTROL_PAR_MOUSE_BEHAVIOUR,-600)
set_control_par(get_ui_id($LPFilterCutoff),$CONTROL_PAR_DEFAULT_VALUE,1000000)
make_persistent($LPFilterCutoff)
read_persistent_var($LPFilterCutoff)
%main[4] := get_ui_id($LPFilterCutoff)
{CONTROLS}
declare ui_switch $Mono
move_control_px($Mono,255,438)
set_control_par_str(get_ui_id($Mono),$CONTROL_PAR_TEXT,"")
set_control_par_str(get_ui_id($Mono),$CONTROL_PAR_PICTURE,"switch")
set_control_par(get_ui_id($Mono),$CONTROL_PAR_WIDTH,65)
set_control_par(get_ui_id($Mono),$CONTROL_PAR_HEIGHT,65)
make_persistent($Mono)
read_persistent_var($Mono)
%main[8] := get_ui_id($Mono)
{EFFECTS}
declare ui_slider $Delay(0, 397000)
move_control_px($Delay,522,410)
set_control_par_str(get_ui_id($Delay),$CONTROL_PAR_TEXT,"")
set_control_par_str(get_ui_id($Delay),$CONTROL_PAR_PICTURE,"Purple Knob")
set_control_par(get_ui_id($Delay),$CONTROL_PAR_WIDTH,45)
set_control_par(get_ui_id($Delay),$CONTROL_PAR_HEIGHT,45)
set_control_par(get_ui_id($Delay),$CONTROL_PAR_MOUSE_BEHAVIOUR,-1000)
set_control_par(get_ui_id($Delay),$CONTROL_PAR_DEFAULT_VALUE,397000)
make_persistent($Delay)
read_persistent_var($Delay)
%main2[0] := get_ui_id($Delay)
{EQ}
declare ui_slider $EQlo(0, 1000000)
move_control_px($EQlo,15,278)
set_control_par_str(get_ui_id($EQlo),$CONTROL_PAR_TEXT,"")
set_control_par_str(get_ui_id($EQlo),$CONTROL_PAR_PICTURE,"Big Red Knob")
set_control_par(get_ui_id($EQlo),$CONTROL_PAR_WIDTH,55)
set_control_par(get_ui_id($EQlo),$CONTROL_PAR_HEIGHT,55)
set_control_par(get_ui_id($EQlo),$CONTROL_PAR_MOUSE_BEHAVIOUR,-800)
set_control_par(get_ui_id($EQlo),$CONTROL_PAR_DEFAULT_VALUE,500000)
make_persistent($EQlo)
read_persistent_var($EQlo)
%main2[7] := get_ui_id($EQlo)
{PITCHENV}
declare ui_slider $PitchAttack(0, 900000)
move_control_px($PitchAttack,249,294)
set_control_par_str(get_ui_id($PitchAttack),$CONTROL_PAR_TEXT,"")
set_control_par_str(get_ui_id($PitchAttack),$CONTROL_PAR_PICTURE,"Small Red
Knob")
set_control_par(get_ui_id($PitchAttack),$CONTROL_PAR_WIDTH,55)
set_control_par(get_ui_id($PitchAttack),$CONTROL_PAR_HEIGHT,55)
set_control_par(get_ui_id($PitchAttack),$CONTROL_PAR_MOUSE_BEHAVIOUR,-800)
set_control_par(get_ui_id($PitchAttack),$CONTROL_PAR_DEFAULT_VALUE,450000)
make_persistent($PitchAttack)
read_persistent_var($PitchAttack)
%main2[11] := get_ui_id($PitchAttack)
{ARP}
declare %orderArp[7] := (1, 2, 3, 4, 5, 16, 14)
declare $orderArpI
make_persistent($orderArpI)
read_persistent_var($orderArpI)
if ($orderArpI = 0)
$orderArpI := 1
end if
declare %led_lbl_ids[16]
%led_lbl_ids[0] := get_ui_id($led_0_lbl)
%led_lbl_ids[1] := get_ui_id($led_1_lbl)
%led_lbl_ids[2] := get_ui_id($led_2_lbl)
%led_lbl_ids[3] := get_ui_id($led_3_lbl)
%led_lbl_ids[4] := get_ui_id($led_4_lbl)
%led_lbl_ids[5] := get_ui_id($led_5_lbl)
%led_lbl_ids[6] := get_ui_id($led_6_lbl)
%led_lbl_ids[7] := get_ui_id($led_7_lbl)
%led_lbl_ids[8] := get_ui_id($led_8_lbl)
%led_lbl_ids[9] := get_ui_id($led_9_lbl)
%led_lbl_ids[10] := get_ui_id($led_10_lbl)
%led_lbl_ids[11] := get_ui_id($led_11_lbl)
%led_lbl_ids[12] := get_ui_id($led_12_lbl)
%led_lbl_ids[13] := get_ui_id($led_13_lbl)
%led_lbl_ids[14] := get_ui_id($led_14_lbl)
%led_lbl_ids[15] := get_ui_id($led_15_lbl)
declare %led[16]
$count := 0
while ($count < 16)
set_control_par_str(%led_lbl_ids[$count],
$CONTROL_PAR_PICTURE,"Arp_LED")
set_control_par(%led_lbl_ids[$count],
$CONTROL_PAR_MOUSE_BEHAVIOUR,-1000)
set_control_par_str(%led_lbl_ids[$count],$CONTROL_PAR_TEXT,"")
set_control_par(%led_lbl_ids[$count],$CONTROL_PAR_POS_X,80+
($count*30))
set_control_par(%led_lbl_ids[$count],$CONTROL_PAR_POS_Y,381)
inc($count)
end while
declare ui_slider $arp_rhythm_0_sld (0,127)
declare ui_slider $arp_rhythm_1_sld (0,127)
declare ui_slider $arp_rhythm_2_sld (0,127)
declare ui_slider $arp_rhythm_3_sld (0,127)
declare ui_slider $arp_rhythm_4_sld (0,127)
declare ui_slider $arp_rhythm_5_sld (0,127)
declare ui_slider $arp_rhythm_6_sld (0,127)
declare ui_slider $arp_rhythm_7_sld (0,127)
declare ui_slider $arp_rhythm_8_sld (0,127)
declare ui_slider $arp_rhythm_9_sld (0,127)
declare ui_slider $arp_rhythm_10_sld (0,127)
declare ui_slider $arp_rhythm_11_sld (0,127)
declare ui_slider $arp_rhythm_12_sld (0,127)
declare ui_slider $arp_rhythm_13_sld (0,127)
declare ui_slider $arp_rhythm_14_sld (0,127)
declare ui_slider $arp_rhythm_15_sld (0,127)
make_persistent($arp_rhythm_0_sld)
read_persistent_var($arp_rhythm_0_sld)
make_persistent($arp_rhythm_1_sld)
read_persistent_var($arp_rhythm_1_sld)
make_persistent($arp_rhythm_2_sld)
read_persistent_var($arp_rhythm_2_sld)
make_persistent($arp_rhythm_3_sld)
read_persistent_var($arp_rhythm_3_sld)
make_persistent($arp_rhythm_4_sld)
read_persistent_var($arp_rhythm_4_sld)
make_persistent($arp_rhythm_5_sld)
read_persistent_var($arp_rhythm_5_sld)
make_persistent($arp_rhythm_6_sld)
read_persistent_var($arp_rhythm_6_sld)
make_persistent($arp_rhythm_7_sld)
read_persistent_var($arp_rhythm_7_sld)
make_persistent($arp_rhythm_8_sld)
read_persistent_var($arp_rhythm_8_sld)
make_persistent($arp_rhythm_9_sld)
read_persistent_var($arp_rhythm_9_sld)
make_persistent($arp_rhythm_10_sld)
read_persistent_var($arp_rhythm_10_sld)
make_persistent($arp_rhythm_11_sld)
read_persistent_var($arp_rhythm_11_sld)
make_persistent($arp_rhythm_12_sld)
read_persistent_var($arp_rhythm_12_sld)
make_persistent($arp_rhythm_13_sld)
read_persistent_var($arp_rhythm_13_sld)
make_persistent($arp_rhythm_14_sld)
read_persistent_var($arp_rhythm_14_sld)
make_persistent($arp_rhythm_15_sld)
read_persistent_var($arp_rhythm_15_sld)
declare %rhythm_sld_ids[16]
%rhythm_sld_ids[0] := get_ui_id($arp_rhythm_0_sld)
%rhythm_sld_ids[1] := get_ui_id($arp_rhythm_1_sld)
%rhythm_sld_ids[2] := get_ui_id($arp_rhythm_2_sld)
%rhythm_sld_ids[3] := get_ui_id($arp_rhythm_3_sld)
%rhythm_sld_ids[4] := get_ui_id($arp_rhythm_4_sld)
%rhythm_sld_ids[5] := get_ui_id($arp_rhythm_5_sld)
%rhythm_sld_ids[6] := get_ui_id($arp_rhythm_6_sld)
%rhythm_sld_ids[7] := get_ui_id($arp_rhythm_7_sld)
%rhythm_sld_ids[8] := get_ui_id($arp_rhythm_8_sld)
%rhythm_sld_ids[9] := get_ui_id($arp_rhythm_9_sld)
%rhythm_sld_ids[10] := get_ui_id($arp_rhythm_10_sld)
%rhythm_sld_ids[11] := get_ui_id($arp_rhythm_11_sld)
%rhythm_sld_ids[12] := get_ui_id($arp_rhythm_12_sld)
%rhythm_sld_ids[13] := get_ui_id($arp_rhythm_13_sld)
%rhythm_sld_ids[14] := get_ui_id($arp_rhythm_14_sld)
%rhythm_sld_ids[15] := get_ui_id($arp_rhythm_15_sld)
$count := 0
while ($count < 16)
set_control_par_str(%rhythm_sld_ids[$count],
$CONTROL_PAR_PICTURE,"Arp_Slider")
set_control_par(%rhythm_sld_ids[$count],
$CONTROL_PAR_MOUSE_BEHAVIOUR,-1300)
set_control_par_str(%rhythm_sld_ids[$count],
$CONTROL_PAR_TEXT,"as")
set_control_par(%rhythm_sld_ids[$count],$CONTROL_PAR_POS_X,74+
($count*30))
set_control_par(%rhythm_sld_ids[$count],$CONTROL_PAR_POS_Y,400)
inc($count)
end while
declare %duration[16]
make_persistent($arp_duration_0_sld)
read_persistent_var($arp_duration_0_sld)
make_persistent($arp_duration_1_sld)
read_persistent_var($arp_duration_1_sld)
make_persistent($arp_duration_2_sld)
read_persistent_var($arp_duration_2_sld)
make_persistent($arp_duration_3_sld)
read_persistent_var($arp_duration_3_sld)
make_persistent($arp_duration_4_sld)
read_persistent_var($arp_duration_4_sld)
make_persistent($arp_duration_5_sld)
read_persistent_var($arp_duration_5_sld)
make_persistent($arp_duration_6_sld)
read_persistent_var($arp_duration_6_sld)
make_persistent($arp_duration_7_sld)
read_persistent_var($arp_duration_7_sld)
make_persistent($arp_duration_8_sld)
read_persistent_var($arp_duration_8_sld)
make_persistent($arp_duration_9_sld)
read_persistent_var($arp_duration_9_sld)
make_persistent($arp_duration_10_sld)
read_persistent_var($arp_duration_10_sld)
make_persistent($arp_duration_11_sld)
read_persistent_var($arp_duration_11_sld)
make_persistent($arp_duration_12_sld)
read_persistent_var($arp_duration_12_sld)
make_persistent($arp_duration_13_sld)
read_persistent_var($arp_duration_13_sld)
make_persistent($arp_duration_14_sld)
read_persistent_var($arp_duration_14_sld)
make_persistent($arp_duration_15_sld)
read_persistent_var($arp_duration_15_sld)
declare %duration_sld_ids[16]
%duration_sld_ids[0] := get_ui_id($arp_duration_0_sld)
%duration_sld_ids[1] := get_ui_id($arp_duration_1_sld)
%duration_sld_ids[2] := get_ui_id($arp_duration_2_sld)
%duration_sld_ids[3] := get_ui_id($arp_duration_3_sld)
%duration_sld_ids[4] := get_ui_id($arp_duration_4_sld)
%duration_sld_ids[5] := get_ui_id($arp_duration_5_sld)
%duration_sld_ids[6] := get_ui_id($arp_duration_6_sld)
%duration_sld_ids[7] := get_ui_id($arp_duration_7_sld)
%duration_sld_ids[8] := get_ui_id($arp_duration_8_sld)
%duration_sld_ids[9] := get_ui_id($arp_duration_9_sld)
%duration_sld_ids[10] := get_ui_id($arp_duration_10_sld)
%duration_sld_ids[11] := get_ui_id($arp_duration_11_sld)
%duration_sld_ids[12] := get_ui_id($arp_duration_12_sld)
%duration_sld_ids[13] := get_ui_id($arp_duration_13_sld)
%duration_sld_ids[14] := get_ui_id($arp_duration_14_sld)
%duration_sld_ids[15] := get_ui_id($arp_duration_15_sld)
$count := 0
while ($count < 16)
set_control_par_str(%duration_sld_ids[$count],
$CONTROL_PAR_PICTURE,"Arp_Slider")
set_control_par(%duration_sld_ids[$count],
$CONTROL_PAR_MOUSE_BEHAVIOUR,-1300)
set_control_par_str(%duration_sld_ids[$count],
$CONTROL_PAR_TEXT,"as")
set_control_par(%duration_sld_ids[$count],$CONTROL_PAR_POS_X,51+
($count*34))
set_control_par(%duration_sld_ids[$count],$CONTROL_PAR_POS_Y,306)
inc($count)
end while
declare $played_pitch
declare %arp_pitch[16]
make_persistent(%arp_pitch)
read_persistent_var(%arp_pitch)
declare %arp_pitch_ids[16]
make_persistent($arp_pitch0)
read_persistent_var($arp_pitch0)
make_persistent($arp_pitch1)
read_persistent_var($arp_pitch1)
make_persistent($arp_pitch2)
read_persistent_var($arp_pitch2)
make_persistent($arp_pitch3)
read_persistent_var($arp_pitch3)
make_persistent($arp_pitch4)
read_persistent_var($arp_pitch4)
make_persistent($arp_pitch5)
read_persistent_var($arp_pitch5)
make_persistent($arp_pitch6)
read_persistent_var($arp_pitch6)
make_persistent($arp_pitch7)
read_persistent_var($arp_pitch7)
make_persistent($arp_pitch8)
read_persistent_var($arp_pitch8)
make_persistent($arp_pitch9)
read_persistent_var($arp_pitch9)
make_persistent($arp_pitch10)
read_persistent_var($arp_pitch10)
make_persistent($arp_pitch11)
read_persistent_var($arp_pitch11)
make_persistent($arp_pitch12)
read_persistent_var($arp_pitch12)
make_persistent($arp_pitch13)
read_persistent_var($arp_pitch13)
make_persistent($arp_pitch14)
read_persistent_var($arp_pitch14)
make_persistent($arp_pitch15)
read_persistent_var($arp_pitch15)
%arp_pitch_ids[0] := get_ui_id($arp_pitch0)
%arp_pitch_ids[1] := get_ui_id($arp_pitch1)
%arp_pitch_ids[2] := get_ui_id($arp_pitch2)
%arp_pitch_ids[3] := get_ui_id($arp_pitch3)
%arp_pitch_ids[4] := get_ui_id($arp_pitch4)
%arp_pitch_ids[5] := get_ui_id($arp_pitch5)
%arp_pitch_ids[6] := get_ui_id($arp_pitch6)
%arp_pitch_ids[7] := get_ui_id($arp_pitch7)
%arp_pitch_ids[8] := get_ui_id($arp_pitch8)
%arp_pitch_ids[9] := get_ui_id($arp_pitch9)
%arp_pitch_ids[10] := get_ui_id($arp_pitch10)
%arp_pitch_ids[11] := get_ui_id($arp_pitch11)
%arp_pitch_ids[12] := get_ui_id($arp_pitch12)
%arp_pitch_ids[13] := get_ui_id($arp_pitch13)
%arp_pitch_ids[14] := get_ui_id($arp_pitch14)
%arp_pitch_ids[15] := get_ui_id($arp_pitch15)
$i := 0
while ($i < 16)
set_control_par_str(%arp_pitch_ids[$i],$CONTROL_PAR_TEXT,"")
set_control_par_str(%arp_pitch_ids[$i],$CONTROL_PAR_PICTURE,"pitch")
set_control_par(%arp_pitch_ids[$i],$CONTROL_PAR_WIDTH,55)
set_control_par(%arp_pitch_ids[$i],$CONTROL_PAR_HEIGHT,55)
set_control_par(%arp_pitch_ids[$i],$CONTROL_PAR_POS_X,80+($i*30))
set_control_par(%arp_pitch_ids[$i],$CONTROL_PAR_POS_Y,503)
set_control_par(%arp_pitch_ids[$i],$CONTROL_PAR_MOUSE_BEHAVIOUR,-200)
set_control_par(%arp_pitch_ids[$i],$CONTROL_PAR_DEFAULT_VALUE,0)
inc($i)
end while
{ARP}
declare !tempo_names[18]
!tempo_names[0] := "1/128"
!tempo_names[1] := "1/64"
!tempo_names[2] := "1/32"
!tempo_names[3] := "1/16 T"
!tempo_names[4] := "1/16"
!tempo_names[5] := "1/8 T"
!tempo_names[6] := "1/8"
!tempo_names[7] := "1/4 T"
!tempo_names[8] := "1/4"
!tempo_names[9] := "1/2 T"
!tempo_names[10] := "1/2"
!tempo_names[11] := "3/4"
!tempo_names[12] := "Bar"
declare %rhythm[16]
make_persistent(%rhythm)
read_persistent_var(%rhythm)
declare !note_class[12]
!note_class[0] := "C"
!note_class[1] := "Db"
!note_class[2] := "D"
!note_class[3] := "Eb"
!note_class[4] := "E"
!note_class[5] := "F"
!note_class[6] := "Gb"
!note_class[7] := "G"
!note_class[8] := "Ab"
!note_class[9] := "A"
!note_class[10] := "Bb"
!note_class[11] := "B"
declare !note_names [128]
$count := 0
while ($count < 128)
!note_names[$count] := !note_class[$count mod 12] & (($count/12)-2)
inc ($count)
end while
declare $Swing := 0
declare ui_knob $Octave (-6,6,1)
make_persistent($Octave)
$Octave := 0
set_knob_defval($Octave,0)
set_control_par_str(get_ui_id($note_order),$CONTROL_PAR_PICTURE,"knob_mode")
declare $last_note_order := 2
$note_order := 2
make_persistent($note_order)
make_persistent($last_note_order)
declare $fill_buffer := 11
make_persistent($fill_buffer)
{**** from retrigger script*********}
declare %pressed_id[128]
declare %note_buffer[512]
declare %ordered[128]
declare %velo[128]
declare $cursor
declare $old_latch_time
declare $a
declare $aa
declare $sema
declare $rand
declare $bb
declare $b
declare $loop_cursor
declare %loop_buffer[512]
declare $id
declare $check_id
declare $min
declare $min_note
declare $max_note
declare $helper
declare %help_buffer[512]
declare $step_length
declare $strike_count
declare $duration
declare $note
declare $velo
declare $act_step
declare $last_order
declare $oct_cursor
declare $swing_cursor
$a := 0
read_persistent_var($Sync_knob)
read_persistent_var($Sync_knob2)
set_knob_label ($Sync_knob,!tempo_names[$Sync_knob])
$Rate_knob := ($sync_knob *1000001) / 17
set_knob_defval ($Rate_knob,(5 *1000001) / 17)
set_knob_label ($Rate_knob,!tempo_names[$sync_knob])
set_knob_unit($Rate_knob,$KNOB_UNIT_NONE)
set_knob_label ($Sync_knob2,!tempo_names[$Sync_knob])
$Rate_knob := ($sync_knob2 *1000001) / 17
move_control($note_order,0,0)
move_control($strike,0,0)
move_control($Octave,0,0)
move_control($Velo_button,0,0)
move_control($Rate_knob,0,0)
move_control($Sync_knob,0,0)
move_control($Sync_knob2,0,0)
declare $Unison := 0
declare $Voices := 1
declare $Detune := 0
if ($Mono = 0)
pgs_set_key_val(MONOLEGATOv, 0, 0)
else
pgs_set_key_val(MONOLEGATOv, 0, 1+$Legato)
end if
pgs_set_key_val(MONOLEGATOv, 1, $Glide)
pgs_set_key_val(UNICHECK, 0, $Unison)
pgs_set_key_val(MONOLEGATOv, 2, $Voices)
pgs_set_key_val(MONOLEGATOv, 3, $Detune)
pgs_set_key_val(MONOLEGATOv, 4, 1)
pgs_set_key_val(INITa, 0, 1)
declare $cicciput := -5
end on
function closearp
select ($ActiveArpPage)
case 1
$count := 0
while ($count < 16)
set_control_par(%rhythm_sld_ids[$count],$CONTROL_PAR_HIDE,
$HIDE_WHOLE_CONTROL)
inc($count)
end while
$count := 0
while ($count < 16)
set_control_par(%duration_sld_ids[$count],$CONTROL_PAR_HIDE,
$HIDE_PART_NOTHING)
inc($count)
end while
set_control_par(%arp[0],$CONTROL_PAR_HIDE,$HIDE_PART_NOTHING)
set_control_par(%arp[2],$CONTROL_PAR_HIDE,$HIDE_PART_NOTHING)
set_control_par(%arp[1],$CONTROL_PAR_HIDE,$HIDE_WHOLE_CONTROL)
set_control_par(%arp[3],$CONTROL_PAR_HIDE,$HIDE_WHOLE_CONTROL)
case 2
$count := 0
while ($count < 16)
set_control_par(%rhythm_sld_ids[$count],$CONTROL_PAR_HIDE,
$HIDE_PART_NOTHING)
inc($count)
end while
$count := 0
while ($count < 16)
set_control_par(%duration_sld_ids[$count],$CONTROL_PAR_HIDE,
$HIDE_WHOLE_CONTROL)
inc($count)
end while
set_control_par(%arp[1],$CONTROL_PAR_HIDE,$HIDE_PART_NOTHING)
set_control_par(%arp[3],$CONTROL_PAR_HIDE,$HIDE_PART_NOTHING)
set_control_par(%arp[0],$CONTROL_PAR_HIDE,$HIDE_WHOLE_CONTROL)
set_control_par(%arp[2],$CONTROL_PAR_HIDE,$HIDE_WHOLE_CONTROL)
end select
end function
function closetabs
$Tab1 := 0
$Tab2 := 0
$Tab3 := 0
$Tab4 := 0
set_skin_offset($SkinOffset*($ActiveTab-1))
$count := 0
while ($count < 19)
set_control_par(%main[$count],$CONTROL_PAR_HIDE,$HIDE_WHOLE_CONTROL)
inc($count)
end while
$count := 0
while ($count < 19)
set_control_par(%main2[$count],$CONTROL_PAR_HIDE,$HIDE_WHOLE_CONTROL)
inc($count)
end while
$count := 0
while ($count < 7)
set_control_par(%tfx[$count],$CONTROL_PAR_HIDE,$HIDE_WHOLE_CONTROL)
inc($count)
end while
$count := 0
while ($count < 40)
set_control_par(%arp[$count],$CONTROL_PAR_HIDE,$HIDE_WHOLE_CONTROL)
inc($count)
end while
$count := 0
while ($count < 16)
set_control_par(%arp_pitch_ids[$count],$CONTROL_PAR_HIDE,
$HIDE_WHOLE_CONTROL)
inc($count)
end while
$count := 0
while ($count < 16)
set_control_par(%led_lbl_ids[$count],$CONTROL_PAR_HIDE,$HIDE_WHOLE_CONTROL)
inc($count)
end while
$count := 0
while ($count < 16)
set_control_par(%rhythm_sld_ids[$count],$CONTROL_PAR_HIDE,
$HIDE_WHOLE_CONTROL)
inc($count)
end while
$count := 0
while ($count < 16)
set_control_par(%duration_sld_ids[$count],$CONTROL_PAR_HIDE,
$HIDE_WHOLE_CONTROL)
inc($count)
end while
select ($ActiveTab)
case 1
$tab1 := 1
$count := 0
while ($count < 19)
set_control_par(%main[$count],$CONTROL_PAR_HIDE,$HIDE_PART_NOTHING)
inc($count)
end while
case 2
$tab2 := 1
$count := 0
while ($count < 19)
set_control_par(%main2[$count],$CONTROL_PAR_HIDE,
$HIDE_PART_NOTHING)
inc($count)
end while
case 3
$tab3 := 1
$count := 0
while ($count < 40)
set_control_par(%arp[$count],$CONTROL_PAR_HIDE,$HIDE_PART_NOTHING)
inc($count)
end while
$count := 0
while ($count < 16)
set_control_par(%arp_pitch_ids[$count],$CONTROL_PAR_HIDE,
$HIDE_PART_NOTHING)
inc($count)
end while
$count := 0
while ($count < 16)
set_control_par(%led_lbl_ids[$count],$CONTROL_PAR_HIDE,
$HIDE_PART_NOTHING)
inc($count)
end while
$count := 0
while ($count < 16)
set_control_par(%rhythm_sld_ids[$count],$CONTROL_PAR_HIDE,
$HIDE_PART_NOTHING)
inc($count)
end while
call closearp
case 4
$count := 0
while ($count < 7)
set_control_par(%tfx[$count],$CONTROL_PAR_HIDE,$HIDE_PART_NOTHING)
inc($count)
end while
end select
message ("")
end function
on ui_control($Tab1)
$ActiveTab := 1
call closetabs
end on
on ui_control($Tab2)
$ActiveTab := 2
call closetabs
end on
on ui_control($Tab3)
$ActiveTab := 3
call closetabs
end on
on ui_control($Tab4)
$ActiveTab := 4
call closetabs
end on
function ANIM
if ($ii > 64)
$ii := 0
end if
while ($ANIMplay > 0)
wait(25000)
set_control_par(get_ui_id($Anim),$CONTROL_PAR_PICTURE_STATE,$ii)
inc($ii)
if ($ii > 64)
$ii := 0
end if
message($ii)
end while
end function
function ANIM2
while ($cicciput < 80)
wait(25000)
set_control_par(get_ui_id($Anim2),$CONTROL_PAR_PICTURE_STATE,$cicciput)
inc($cicciput)
wait(1000000)
end while
end function
on note
set_engine_par($ENGINE_PAR_MOD_TARGET_INTENSITY,1000000,$i,1,0)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,0,$i,2,0)
inc ($i)
end while
set_key_color(24,$KEY_COLOR_GREEN)
$tfx1 := 1
else
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_MOD_TARGET_INTENSITY,0,$i,1,0)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,$i,2,0)
inc ($i)
end while
set_key_color(24,$KEY_COLOR_RED)
$tfx1 := 0
end if
case 25
if ($tfx2 = 0)
$tfx2 := 1
else
$tfx2 := 0
end if
if ($tfx2 = 1)
$PitchSwitch := 0
set_key_color(25,$KEY_COLOR_GREEN)
else
$PitchSwitch := 1
set_key_color(25,$KEY_COLOR_RED)
end if
if ($PitchSwitch = 0)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_MOD_TARGET_INTENSITY,0,$i,0,0)
inc ($i)
end while
else
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_MOD_TARGET_INTENSITY,1000000,$i,0,0)
inc ($i)
end while
end if
case 26
if ($tfx3 = 0)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,0,$i,3,0)
inc ($i)
end while
set_key_color(26,$KEY_COLOR_GREEN)
$tfx3 := 1
else
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,$i,3,0)
inc ($i)
end while
set_key_color(26,$KEY_COLOR_RED)
$tfx3 := 0
end if
case 27
if ($tfx4 = 0)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,0,$i,4,0)
inc ($i)
end while
set_key_color(27,$KEY_COLOR_GREEN)
$tfx4 := 1
else
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,$i,4,0)
inc ($i)
end while
set_key_color(27,$KEY_COLOR_RED)
$tfx4 := 0
end if
case 28
if ($tfx5 = 0)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_MOD_TARGET_INTENSITY,1000000,$i,5,0)
inc ($i)
end while
set_key_color(28,$KEY_COLOR_GREEN)
$tfx5 := 1
else
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_MOD_TARGET_INTENSITY,0,$i,5,0)
inc ($i)
end while
set_key_color(28,$KEY_COLOR_RED)
$tfx5 := 0
end if
case 29
if ($tfx6 = 0)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,0,$i,6,0)
inc ($i)
end while
set_key_color(30,$KEY_COLOR_GREEN)
$tfx6 := 1
else
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,$i,6,0)
inc ($i)
end while
set_key_color(30,$KEY_COLOR_RED)
$tfx6 := 0
end if
case 30
if ($tfx7 = 0)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,0,$i,5,0)
inc ($i)
end while
set_key_color(29,$KEY_COLOR_GREEN)
$tfx7 := 1
else
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,$i,5,0)
inc ($i)
end while
set_key_color(29,$KEY_COLOR_RED)
$tfx7 := 0
end if
end select
exit
end if
if ($latch_mode = 0)
exit
end if
%velo[$EVENT_NOTE] := $EVENT_VELOCITY
{only one event per Note}
set_event_par($EVENT_ID,0,2)
ignore_event($EVENT_ID)
if (%pressed_id[$EVENT_NOTE] > 0)
exit
else
%pressed_id[$EVENT_NOTE] := $EVENT_ID
end if
{which notes should be in the buffer}
select ($latch_mode)
case 1
%note_buffer[$cursor] := $EVENT_NOTE
inc($cursor)
case 2
if ($ENGINE_UPTIME - $old_latch_time > $LATCH_TIME)
$a := 0
while($a < $cursor)
%note_buffer[$a] := 0
inc($a)
end while
$cursor := 0
end if
%note_buffer[$cursor] := $EVENT_NOTE
inc($cursor)
$old_latch_time := $ENGINE_UPTIME
end select
if ($cursor < 2 and $check_id = 0)
$check_id := $EVENT_ID
$aa := 0
$act_step := 0
$oct_cursor := 0
$last_order := -1
$swing_cursor := 0
wait($REC_TIME*1)
while($cursor > 0)
$played_pitch := %arp_pitch[$act_step]
{$duration := %duration[$act_step]*2000
if ($duration < 20000)
$duration := 20000
end if}
select ($Sync_knob2)
case 0
$duration:= $DURATION_SIXTEENTH/8
case 1
$duration:= $DURATION_SIXTEENTH/4
case 2
$duration:= $DURATION_SIXTEENTH/2
case 3
$duration:= $DURATION_QUARTER/6
case 4
$duration:= $DURATION_SIXTEENTH
case 5
$duration:= $DURATION_QUARTER/3
case 6
$duration:= $DURATION_EIGHTH
case 7
$duration:= $DURATION_QUARTER*2/3
case 8
$duration:= $DURATION_QUARTER
case 9
$duration:= $DURATION_QUARTER*4/3
case 10
$duration:= $DURATION_QUARTER*2
case 11
$duration:= $DURATION_QUARTER*3
case 12
$duration:= $DURATION_BAR
end select
if ($act_step = 0)
$i := $act_step
while ($i < 16)
set_control_par(%led_lbl_ids[$i],$CONTROL_PAR_PICTURE_STATE,0)
inc($i)
end while
set_control_par(%led_lbl_ids[$act_step],$CONTROL_PAR_PICTURE_STATE,1)
else
set_control_par(%led_lbl_ids[$act_step-1],$CONTROL_PAR_PICTURE_STATE,0)
set_control_par(%led_lbl_ids[$act_step],$CONTROL_PAR_PICTURE_STATE,1)
end if
$a := 0
while($a < 128)
if ($a < $cursor)
%ordered[$a] := %note_buffer[$a]
else
%ordered[$a] := 0
%note_buffer[$a] := 0
end if
inc($a)
end while
$min_note := %ordered[$cursor-1]
$max_note := %ordered[0]
sort(%ordered,1)
select ($note_order)
case 1
$loop_cursor := $cursor
$a := 0
while($a < $cursor)
%loop_buffer[$a] := %note_buffer[$a]
inc($a)
end while
case 2 {up }
$loop_cursor := $cursor
$a := 0
while($a < $cursor )
%loop_buffer[$a] := %ordered[$cursor - 1 - $a]
inc($a)
end while
case 3 {down }
$loop_cursor := $cursor
$a := 0
while($a < $cursor )
%loop_buffer[$a] := %ordered[$a]
inc($a)
end while
case 4 {up_down }
$loop_cursor := $cursor
$a := 0
while($a < $cursor )
%loop_buffer[$a] := %ordered[$cursor -1 - $a]
inc($a)
end while
if ($cursor > 2)
select ($repeat)
case 1
$loop_cursor := ($cursor*2)-2
$a := 0
while($a < $cursor-2 )
%loop_buffer[$a+$cursor] :=
%ordered[$a+1]
inc($a)
end while
case 2
$loop_cursor := ($cursor*2)-1
$a := 0
while($a < $cursor-1 )
%loop_buffer[$a+$cursor] :=
%ordered[$a]
inc($a)
end while
case 3
$loop_cursor := ($cursor*2)-1
$a := 0
while($a < $cursor-1 )
%loop_buffer[$a+$cursor] :=
%ordered[$a+1]
inc($a)
end while
case 5
$loop_cursor := ($cursor*2)
$a := 0
while($a < $cursor )
%loop_buffer[$a+$cursor] :=
%ordered[$a]
inc($a)
end while
end select
end if
case 5 {down_up }
$loop_cursor := $cursor
$a := 0
while($a < $cursor )
%loop_buffer[$a] := %ordered[$a]
inc($a)
end while
if ($cursor > 2)
select ($repeat)
case 1
$loop_cursor := ($cursor*2)-2
$a := 0
while($a < $cursor-2 )
%loop_buffer[$a+$cursor] :=
%ordered[$cursor -2- $a]
inc($a)
end while
case 3
$loop_cursor := ($cursor*2)-1
$a := 0
while($a < $cursor-1 )
%loop_buffer[$a+$cursor] :=
%ordered[$cursor -1 - $a]
inc($a)
end while
case 2
$loop_cursor := ($cursor*2)-1
$a := 0
while($a < $cursor-1 )
%loop_buffer[$a+$cursor] :=
%ordered[$cursor -2- $a]
inc($a)
end while
case 5
$loop_cursor := ($cursor*2)
$a := 0
while($a < $cursor )
%loop_buffer[$a+$cursor] :=
%ordered[$cursor -1- $a]
inc($a)
end while
end select
end if
case 14
$loop_cursor := 1
%loop_buffer[$aa+1] := %ordered[random(0,$cursor-1)]
%loop_buffer[0] := %ordered[random(0,$cursor-1)]
case 16
$loop_cursor := $cursor
$a := 0
while($a < $cursor )
%loop_buffer[$a] := %note_buffer[$a]
inc($a)
end while
end select
$last_order := $note_order
select ($Sync_knob)
case 0
$step_length := $DURATION_SIXTEENTH/8
case 1
$step_length := $DURATION_SIXTEENTH/4
case 2
$step_length := $DURATION_SIXTEENTH/2
case 3
$step_length := $DURATION_QUARTER/6
case 4
$step_length := $DURATION_SIXTEENTH
case 5
$step_length := $DURATION_QUARTER/3
case 6
$step_length := $DURATION_EIGHTH
case 7
$step_length := $DURATION_QUARTER*2/3
case 8
$step_length := $DURATION_QUARTER
case 9
$step_length := $DURATION_QUARTER*4/3
case 10
$step_length := $DURATION_QUARTER*2
case 11
$step_length := $DURATION_QUARTER*3
case 12
$step_length := $DURATION_BAR
end select
if ($swing_cursor mod 2 = 0)
$step_length := $step_length + ($step_length*$Swing)/100
else
$step_length := $step_length + ($step_length*(-$Swing))/100
end if
inc($swing_cursor)
inc($act_step)
if ($act_step >= $steps)
$act_step := 0
end if
wait($step_length)
end while
$check_id := 0
end if
end on
on release
if ($PLAYED_VOICES_INST = 0)
$ANIMplay := 0
end if
{only one event per Note}
if (%EVENT_PAR[0] = 2)
{ignore_event($EVENT_ID)}
if (%pressed_id[$EVENT_NOTE] = 0)
exit
else
%pressed_id[$EVENT_NOTE] := 0
end if
else
exit
end if
if ($latch_mode = 0)
exit
end if
{which notes should be in the buffer}
select ($latch_mode)
case 1
$a := 0
$b := $cursor
$cursor := 0
while($a < $b)
if ($EVENT_NOTE # %note_buffer[$a])
%note_buffer[$cursor] := %note_buffer[$a]
inc($cursor)
end if
inc($a)
end while
case 2 to 3
exit
end select
end on
on ui_control ($Sync_knob)
set_knob_label ($Sync_knob,!tempo_names[$Sync_knob])
end on
on ui_control ($note_order)
if ($note_order # 99)
$last_note_order := $note_order
else
$note_order:= $last_note_order
end if
end on
on ui_control ($rate_knob)
$sync_knob := ($Rate_knob * 18) /1000001
set_knob_label ($Rate_knob,!tempo_names[$sync_knob])
end on
{END OF SCRIPT}
on ui_control ($ClearVel)
$ii := 0
while ($ii < 16)
while (%rhythm[$ii] > 0)
dec(%rhythm[$ii])
set_control_par(%rhythm_sld_ids[$ii],$CONTROL_PAR_VALUE,%rhythm[$ii])
wait (100)
end while
inc ($ii)
end while
wait (100000)
$ClearVel := 0
message ("")
end on
on ui_control ($InitVel)
$ii := 0
while ($ii < 16)
while (%rhythm[$ii] < 127)
inc(%rhythm[$ii])
set_control_par(%rhythm_sld_ids[$ii],$CONTROL_PAR_VALUE,%rhythm[$ii])
wait (100)
end while
inc ($ii)
end while
wait (50000)
$InitVel := 0
message ("")
end on
on ui_control ($ClearPitch)
$i := 0
while ($i < 16)
while (%arp_pitch[$i] > 0)
dec(%arp_pitch[$i])
set_control_par(%arp_pitch_ids[$i],$CONTROL_PAR_VALUE,%arp_pitch[$i])
wait (1500)
end while
while (%arp_pitch[$i] < 0)
inc(%arp_pitch[$i])
set_control_par(%arp_pitch_ids[$i],$CONTROL_PAR_VALUE,%arp_pitch[$i])
wait (1500)
end while
set_control_par(%arp_pitch_ids[$i],$CONTROL_PAR_VALUE,0)
inc ($i)
end while
wait (200000)
$ClearPitch := 0
message ("")
end on
on ui_control ($ARPmode)
$latch_mode := $ARPmode
select ($latch_mode)
case 0
$a := 0
while($a < $cursor)
%note_buffer[$a] := 0
inc($a)
end while
$cursor := 0
case 1
$b := $cursor
$cursor := 0
$a := 0
while($a < $b)
if (%pressed_id[%note_buffer[$a]] > 0)
%note_buffer[$cursor] := %note_buffer[$a]
inc($cursor)
end if
inc($a)
end while
end select
end on
on ui_control ($ARPrate)
$Sync_knob := ($ARPrate * -1)
end on
on ui_control ($ARPorder)
if ($ARPorder = 99)
$ARPorder := 1
end if
$note_order := $ARPorder
$orderArpI := search(%orderArp,$ARPorder)
end on
on ui_control ($ARPoctave)
$Octave := $ARPoctave
end on
{------------------------}
on ui_control ($arp_rhythm_0_sld)
if (get_control_par(get_ui_id($arp_rhythm_0_sld),$CONTROL_PAR_KEY_ALT) = 1)
%rhythm[0] := 127
$arp_rhythm_0_sld := 127
else
%rhythm[0] := $arp_rhythm_0_sld
end if
end on
on ui_control ($arp_rhythm_1_sld)
if (get_control_par(get_ui_id($arp_rhythm_1_sld),$CONTROL_PAR_KEY_ALT) = 1)
%rhythm[1] := 127
$arp_rhythm_1_sld := 127
else
%rhythm[1] := $arp_rhythm_1_sld
end if
end on
on ui_control ($arp_rhythm_2_sld)
if (get_control_par(get_ui_id($arp_rhythm_2_sld),$CONTROL_PAR_KEY_ALT) = 1)
%rhythm[2] := 127
$arp_rhythm_2_sld := 127
else
%rhythm[2] := $arp_rhythm_2_sld
end if
end on
on ui_control ($arp_rhythm_3_sld)
if (get_control_par(get_ui_id($arp_rhythm_3_sld),$CONTROL_PAR_KEY_ALT) = 1)
%rhythm[3] := 127
$arp_rhythm_3_sld := 127
else
%rhythm[3] := $arp_rhythm_3_sld
end if
end on
on ui_control ($arp_rhythm_4_sld)
if (get_control_par(get_ui_id($arp_rhythm_4_sld),$CONTROL_PAR_KEY_ALT) = 1)
%rhythm[4] := 127
$arp_rhythm_4_sld := 127
else
%rhythm[4] := $arp_rhythm_4_sld
end if
end on
on ui_control ($arp_rhythm_5_sld)
if (get_control_par(get_ui_id($arp_rhythm_5_sld),$CONTROL_PAR_KEY_ALT) = 1)
%rhythm[5] := 127
$arp_rhythm_5_sld := 127
else
%rhythm[5] := $arp_rhythm_5_sld
end if
end on
on ui_control ($arp_rhythm_6_sld)
if (get_control_par(get_ui_id($arp_rhythm_6_sld),$CONTROL_PAR_KEY_ALT) = 1)
%rhythm[6] := 127
$arp_rhythm_6_sld := 127
else
%rhythm[6] := $arp_rhythm_6_sld
end if
end on
on ui_control ($arp_rhythm_7_sld)
if (get_control_par(get_ui_id($arp_rhythm_7_sld),$CONTROL_PAR_KEY_ALT) = 1)
%rhythm[7] := 127
$arp_rhythm_7_sld := 127
else
%rhythm[7] := $arp_rhythm_7_sld
end if
end on
on ui_control ($arp_rhythm_8_sld)
if (get_control_par(get_ui_id($arp_rhythm_8_sld),$CONTROL_PAR_KEY_ALT) = 1)
%rhythm[8] := 127
$arp_rhythm_8_sld := 127
else
%rhythm[8] := $arp_rhythm_8_sld
end if
end on
on ui_control ($arp_rhythm_9_sld)
if (get_control_par(get_ui_id($arp_rhythm_9_sld),$CONTROL_PAR_KEY_ALT) = 1)
%rhythm[9] := 127
$arp_rhythm_9_sld := 127
else
%rhythm[9] := $arp_rhythm_9_sld
end if
end on
on ui_control ($arp_rhythm_10_sld)
if (get_control_par(get_ui_id($arp_rhythm_10_sld),$CONTROL_PAR_KEY_ALT) = 1)
%rhythm[10] := 127
$arp_rhythm_10_sld := 127
else
%rhythm[10] := $arp_rhythm_10_sld
end if
end on
on ui_control ($arp_rhythm_11_sld)
if (get_control_par(get_ui_id($arp_rhythm_11_sld),$CONTROL_PAR_KEY_ALT) = 1)
%rhythm[11] := 127
$arp_rhythm_11_sld := 127
else
%rhythm[11] := $arp_rhythm_11_sld
end if
end on
on ui_control ($arp_rhythm_12_sld)
if (get_control_par(get_ui_id($arp_rhythm_12_sld),$CONTROL_PAR_KEY_ALT) = 1)
%rhythm[12] := 127
$arp_rhythm_12_sld := 127
else
%rhythm[12] := $arp_rhythm_12_sld
end if
end on
on ui_control ($arp_rhythm_13_sld)
if (get_control_par(get_ui_id($arp_rhythm_13_sld),$CONTROL_PAR_KEY_ALT) = 1)
%rhythm[13] := 127
$arp_rhythm_13_sld := 127
else
%rhythm[13] := $arp_rhythm_13_sld
end if
end on
on ui_control ($arp_rhythm_14_sld)
if (get_control_par(get_ui_id($arp_rhythm_14_sld),$CONTROL_PAR_KEY_ALT) = 1)
%rhythm[14] := 127
$arp_rhythm_14_sld := 127
else
%rhythm[14] := $arp_rhythm_14_sld
end if
end on
on ui_control ($arp_rhythm_15_sld)
if (get_control_par(get_ui_id($arp_rhythm_15_sld),$CONTROL_PAR_KEY_ALT) = 1)
%rhythm[15] := 127
$arp_rhythm_15_sld := 127
else
%rhythm[15] := $arp_rhythm_15_sld
end if
end on
on ui_control ($arp_duration_0_sld)
if (get_control_par(get_ui_id($arp_duration_0_sld),$CONTROL_PAR_KEY_ALT) = 1)
%duration[0] := 127
$arp_duration_0_sld := 127
else
%duration[0] := $arp_duration_0_sld
end if
end on
on ui_control ($arp_duration_1_sld)
if (get_control_par(get_ui_id($arp_duration_1_sld),$CONTROL_PAR_KEY_ALT) = 1)
%duration[1] := 127
$arp_duration_1_sld := 127
else
%duration[1] := $arp_duration_1_sld
end if
end on
on ui_control ($arp_duration_2_sld)
if (get_control_par(get_ui_id($arp_duration_2_sld),$CONTROL_PAR_KEY_ALT) = 1)
%duration[2] := 127
$arp_duration_2_sld := 127
else
%duration[2] := $arp_duration_2_sld
end if
end on
on ui_control ($arp_duration_3_sld)
if (get_control_par(get_ui_id($arp_duration_3_sld),$CONTROL_PAR_KEY_ALT) = 1)
%duration[3] := 127
$arp_duration_3_sld := 127
else
%duration[3] := $arp_duration_3_sld
end if
end on
on ui_control ($arp_duration_4_sld)
if (get_control_par(get_ui_id($arp_duration_4_sld),$CONTROL_PAR_KEY_ALT) = 1)
%duration[4] := 127
$arp_duration_4_sld := 127
else
%duration[4] := $arp_duration_4_sld
end if
end on
on ui_control ($arp_duration_5_sld)
if (get_control_par(get_ui_id($arp_duration_5_sld),$CONTROL_PAR_KEY_ALT) = 1)
%duration[5] := 127
$arp_duration_5_sld := 127
else
%duration[5] := $arp_duration_5_sld
end if
end on
on ui_control ($arp_duration_6_sld)
if (get_control_par(get_ui_id($arp_duration_6_sld),$CONTROL_PAR_KEY_ALT) = 1)
%duration[6] := 127
$arp_duration_6_sld := 127
else
%duration[6] := $arp_duration_6_sld
end if
end on
on ui_control ($arp_duration_7_sld)
if (get_control_par(get_ui_id($arp_duration_7_sld),$CONTROL_PAR_KEY_ALT) = 1)
%duration[7] := 127
$arp_duration_7_sld := 127
else
%duration[7] := $arp_duration_7_sld
end if
end on
on ui_control ($arp_duration_8_sld)
if (get_control_par(get_ui_id($arp_duration_8_sld),$CONTROL_PAR_KEY_ALT) = 1)
%duration[8] := 127
$arp_duration_8_sld := 127
else
%duration[8] := $arp_duration_8_sld
end if
end on
on ui_control ($arp_duration_9_sld)
if (get_control_par(get_ui_id($arp_duration_9_sld),$CONTROL_PAR_KEY_ALT) = 1)
%duration[9] := 127
$arp_duration_9_sld := 127
else
%duration[9] := $arp_duration_9_sld
end if
end on
on ui_control ($arp_duration_10_sld)
if (get_control_par(get_ui_id($arp_duration_10_sld),$CONTROL_PAR_KEY_ALT) =
1)
%duration[10] := 127
$arp_duration_10_sld := 127
else
%duration[10] := $arp_duration_10_sld
end if
end on
on ui_control ($arp_duration_11_sld)
if (get_control_par(get_ui_id($arp_duration_11_sld),$CONTROL_PAR_KEY_ALT) =
1)
%duration[11] := 127
$arp_duration_11_sld := 127
else
%duration[11] := $arp_duration_11_sld
end if
end on
on ui_control ($arp_duration_12_sld)
if (get_control_par(get_ui_id($arp_duration_12_sld),$CONTROL_PAR_KEY_ALT) =
1)
%duration[12] := 127
$arp_duration_12_sld := 127
else
%duration[12] := $arp_duration_12_sld
end if
end on
on ui_control ($arp_duration_13_sld)
if (get_control_par(get_ui_id($arp_duration_13_sld),$CONTROL_PAR_KEY_ALT) =
1)
%duration[13] := 127
$arp_duration_13_sld := 127
else
%duration[13] := $arp_duration_13_sld
end if
end on
on ui_control ($arp_duration_14_sld)
if (get_control_par(get_ui_id($arp_duration_14_sld),$CONTROL_PAR_KEY_ALT) =
1)
%duration[14] := 127
$arp_duration_14_sld := 127
else
%duration[14] := $arp_duration_14_sld
end if
end on
on ui_control ($arp_duration_15_sld)
if (get_control_par(get_ui_id($arp_duration_15_sld),$CONTROL_PAR_KEY_ALT) =
1)
%duration[15] := 127
$arp_duration_15_sld := 127
else
%duration[15] := $arp_duration_15_sld
end if
end on
on ui_control ($arp_pitch0)
%arp_pitch[0] := $arp_pitch0
end on
on ui_control ($arp_pitch1)
%arp_pitch[1] := $arp_pitch1
end on
on ui_control ($arp_pitch2)
%arp_pitch[2] := $arp_pitch2
end on
on ui_control ($arp_pitch3)
%arp_pitch[3] := $arp_pitch3
end on
on ui_control ($arp_pitch4)
%arp_pitch[4] := $arp_pitch4
end on
on ui_control ($arp_pitch5)
%arp_pitch[5] := $arp_pitch5
end on
on ui_control ($arp_pitch6)
%arp_pitch[6] := $arp_pitch6
end on
on ui_control ($arp_pitch7)
%arp_pitch[7] := $arp_pitch7
end on
on ui_control ($arp_pitch8)
%arp_pitch[8] := $arp_pitch8
end on
on ui_control ($arp_pitch9)
%arp_pitch[9] := $arp_pitch9
end on
on ui_control ($arp_pitch10)
%arp_pitch[10] := $arp_pitch10
end on
on ui_control ($arp_pitch11)
%arp_pitch[11] := $arp_pitch11
end on
on ui_control ($arp_pitch12)
%arp_pitch[12] := $arp_pitch12
end on
on ui_control ($arp_pitch13)
%arp_pitch[13] := $arp_pitch13
end on
on ui_control ($arp_pitch14)
%arp_pitch[14] := $arp_pitch14
end on
on ui_control ($arp_pitch15)
%arp_pitch[15] := $arp_pitch15
end on
on ui_control($ARPgateS)
on ui_control($ARPrateS)
on ui_control($ARPgate)
end on
on ui_control($ARPrate)
end on
on ui_control ($EQlo)
set_engine_par($ENGINE_PAR_SEQ_LF_GAIN,$EQlo,-1,5,-1)
set_text($status,$EQlo/10000&"%")
end on
on ui_control ($EQlomid)
set_engine_par($ENGINE_PAR_SEQ_LMF_GAIN,$EQlomid,-1,5,-1)
set_text($status,$EQlomid/10000&"%")
end on
on ui_control ($EQhimid)
set_engine_par($ENGINE_PAR_SEQ_HMF_GAIN,$EQhimid,-1,5,-1)
set_text($status,$EQhimid/10000&"%")
end on
on ui_control ($EQhi)
set_engine_par($ENGINE_PAR_SEQ_HF_GAIN,$EQhi,-1,5,-1)
set_text($status,$EQhi/10000&"%")
end on
on ui_control ($Mono)
if ($Mono = 0)
pgs_set_key_val(MONOLEGATOv, 0, 0)
else
pgs_set_key_val(MONOLEGATOv, 0, 1+$Legato)
end if
end on
on ui_control ($Legato)
if ($Mono = 1)
pgs_set_key_val(MONOLEGATOv, 0, 0)
else
pgs_set_key_val(MONOLEGATOv, 0, 1+$Legato)
end if
end on
on ui_control ($Glide)
pgs_set_key_val(MONOLEGATOv, 1, $Glide)
end on
on ui_control ($attack)
message ("")
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_ATTACK,$attack,$i,8,-1)
inc ($i)
end while
set_text($status,$attack/10000&"%")
end on
on ui_control ($decay)
message ("")
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_DECAY,$decay,$i,8,-1)
inc ($i)
end while
set_text($status,$decay/10000&"%")
end on
on ui_control ($sustain)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_SUSTAIN,$sustain,$i,8,-1)
inc ($i)
end while
set_text($status,$sustain/10000&"%")
end on
on ui_control ($release)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_RELEASE,$release,$i,8,-1)
inc ($i)
end while
set_text($status,$release/10000&"%")
end on
{FILTERS}
on ui_control($LPFilterCutoff)
set_engine_par($ENGINE_PAR_CUTOFF,$LPFilterCutoff,0,0,1)
set_text($status,$LPFilterCutoff/10000&"%")
end on
on ui_control($LPFilterResonance)
set_engine_par($ENGINE_PAR_RESONANCE,$LPFilterResonance,0,0,1)
set_text($status,$LPFilterResonance/10000&"%")
end on
on ui_control($HPFilterCutoff)
set_engine_par($ENGINE_PAR_CUTOFF,$HPFilterCutoff,0,1,1)
set_text($status,$HPFilterCutoff/10000&"%")
end on
on ui_control($HPFilterResonance)
set_engine_par($ENGINE_PAR_RESONANCE,$HPFilterResonance,0,1,1)
set_text($status,$HPFilterResonance/10000&"%")
end on
on ui_control ($Chorus)
select ($Chorus)
case 0
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,-1,2,-1)
case 1 to 1000000
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,0,-1,2,-1)
set_engine_par ($ENGINE_PAR_INSERT_EFFECT_OUTPUT_GAIN,$Chorus,-1,2,1)
end select
set_text($status,$Chorus/3970&"%")
end on
on ui_control ($Phaser)
select ($Phaser)
case 0
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,-1,0,-1)
case 1 to 1000000
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,0,-1,0,-1)
set_engine_par ($ENGINE_PAR_INSERT_EFFECT_OUTPUT_GAIN,$Phaser,-1,0,1)
end select
set_text($status,$Phaser/3970&"%")
end on
on ui_control ($Dist)
select ($Dist)
case 0
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,-1,1,-1)
case 1 to 1000000
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,0,-1,1,-1)
set_engine_par ($ENGINE_PAR_DRIVE,$Dist,-1,1,1)
end select
set_text($status,$Dist/3970&"%")
end on
on ui_control ($Reverb)
select ($Reverb)
case 0
set_engine_par($ENGINE_PAR_SEND_EFFECT_BYPASS,1,-1,0,0)
case 1 to 1000000
set_engine_par($ENGINE_PAR_SEND_EFFECT_BYPASS,0,-1,0,0)
set_engine_par($ENGINE_PAR_SENDLEVEL_0,$Reverb,-1,7,0)
end select
set_text($status,$Reverb/3970&"%")
end on
on ui_control ($Delay)
select ($Delay)
case 0
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,-1,3,-1)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,-1,4,-1)
case 1 to 1000000
select ($DelaySync)
case 0
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,0,-1,3,-1)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,-1,4,-1)
case 1
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,-1,3,-1)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,0,-1,4,-1)
end select
set_engine_par ($ENGINE_PAR_INSERT_EFFECT_OUTPUT_GAIN,$Delay,-1,3,1)
set_engine_par ($ENGINE_PAR_INSERT_EFFECT_OUTPUT_GAIN,$Delay,-1,4,1)
end select
set_text($status,$Delay/3970&"%")
end on
on ui_control ($DelaySync)
select ($DelaySync)
case 0
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,0,-1,3,-1)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,-1,4,-1)
case 1
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,-1,3,-1)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,0,-1,4,-1)
end select
end on
on ui_control ($Tremolo)
set_engine_par($ENGINE_PAR_MOD_TARGET_INTENSITY,$Tremolo,0,4,0)
set_text($status,$Tremolo/10000&"%")
end on
on ui_control ($PitchAttack)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_ATTACK,$PitchAttack,$i,0,0)
inc ($i)
end while
if ($PitchRel = 0)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_SUSTAIN,1000000,$i,0,0)
inc ($i)
end while
else
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_SUSTAIN,0,$i,0,0)
inc ($i)
end while
end if
set_text($status,$PitchAttack/10000&"%")
end on
on ui_control ($PitchRel)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_DECAY,$PitchRel,$i,0,0)
inc ($i)
end while
if ($PitchRel = 0)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_SUSTAIN,1000000,$i,0,0)
inc ($i)
end while
else
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_SUSTAIN,0,$i,0,0)
inc ($i)
end while
end if
set_text($status,$PitchRel/10000&"%")
end on
on ui_control($tfx1)
if ($tfx1 = 1)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_MOD_TARGET_INTENSITY,1000000,$i,1,0)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,0,$i,2,0)
inc ($i)
end while
set_key_color(24,$KEY_COLOR_GREEN)
else
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_MOD_TARGET_INTENSITY,0,$i,1,0)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,$i,2,0)
inc ($i)
end while
set_key_color(24,$KEY_COLOR_RED)
end if
end on
on ui_control($tfx2)
if ($tfx2 = 1)
$PitchSwitch := 1
set_key_color(25,$KEY_COLOR_GREEN)
else
$PitchSwitch := 0
set_key_color(25,$KEY_COLOR_RED)
end if
if ($PitchSwitch = 0)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_MOD_TARGET_INTENSITY,0,$i,0,0)
inc ($i)
end while
else
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_MOD_TARGET_INTENSITY,1000000,$i,0,0)
inc ($i)
end while
end if
end on
on ui_control($tfx3)
if ($tfx3 = 1)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,0,$i,3,0)
inc ($i)
end while
set_key_color(26,$KEY_COLOR_GREEN)
else
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,$i,3,0)
inc ($i)
end while
set_key_color(26,$KEY_COLOR_RED)
end if
end on
on ui_control($tfx4)
if ($tfx4 = 1)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,0,$i,4,0)
inc ($i)
end while
set_key_color(27,$KEY_COLOR_GREEN)
else
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,$i,4,0)
inc ($i)
end while
set_key_color(27,$KEY_COLOR_RED)
end if
end on
on ui_control($tfx5)
if ($tfx5 = 1)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_MOD_TARGET_INTENSITY,1000000,$i,5,0)
inc ($i)
end while
set_key_color(28,$KEY_COLOR_GREEN)
else
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_MOD_TARGET_INTENSITY,0,$i,5,0)
inc ($i)
end while
set_key_color(28,$KEY_COLOR_RED)
end if
end on
on ui_control($tfx6)
if ($tfx6 = 1)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,0,$i,6,0)
inc ($i)
end while
set_key_color(30,$KEY_COLOR_GREEN)
else
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,$i,6,0)
inc ($i)
end while
set_key_color(30,$KEY_COLOR_RED)
end if
end on
on ui_control($tfx7)
if ($tfx7 = 1)
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,0,$i,5,0)
inc ($i)
end while
set_key_color(29,$KEY_COLOR_GREEN)
else
$i := 0
while ($i < $NUM_GROUPS)
set_engine_par($ENGINE_PAR_EFFECT_BYPASS,1,$i,5,0)
inc ($i)
end while
set_key_color(29,$KEY_COLOR_RED)
end if
end on
on pgs_changed
if (pgs_get_key_val(INITa,0) = 1)
pgs_set_key_val(INITa,0,0)
call closetabs
end if
end on
on listener
if ($cicciput < 80)
call ANIM2
else
if ($PLAYED_VOICES_INST = 0)
$ANIMplay := 0
while ($ii >= 0)
wait(25000)
set_control_par(get_ui_id($Anim),$CONTROL_PAR_PICTURE_STATE,$ii)
dec($ii)
end while
else
if ($ANIMplay = 0)
$ANIMplay := 1
call ANIM
end if
end if
end if
end on
{}