Playing notes from more than one slot

Lovechld2000
Lovechld2000 Member Posts: 29 Member
edited November 2022 in Scripting Workshop

I have some notes playing from script slot 0 using disallow_group($ALL_GROUPS) and allowing groups, and some arpeggiator notes using ignore_event(EVENT_ID) set up like in the code below.

It all works ! ... until I try to run the non arped notes to script slot 1. It seems like there may be different rules about which slot's "on note" disallowing($ALL_GROUPS) and ignore_event(EVENT_ID) must be for them both to work. Is there any documentation about writing for multiple slots with different note systems around ? or is there a known way to handle it? I am aware the slots execute from order 0 to 4


on note 
	ignore_event(EVENT_ID)
	disallow_group($ALL_GROUPS)

	{non arp notes }
	allow_group(<group>)
 		id := play_note(EVENT_NOTE, EVENT_VELOCITY, 0, 1)
	disallow_group(<group>)


	{arp notes}
		arpid  := play_note(played_note,played_velocity,0,%played_duration)
		set_event_par_arr(arpid, $EVENT_PAR_ALLOW_GROUP, 0, $ALL_GROUPS) 
		set_event_par_arr(arpid, $EVENT_PAR_ALLOW_GROUP, 1, <group>)


Comments

  • Lovechld2000
    Lovechld2000 Member Posts: 29 Member

    after further research i'm going to try to deal with this a different way. I didn't realise what a dumpster fire the NCBs are with the slot system 😅

  • EvilDragon
    EvilDragon Moderator Posts: 1,022 mod

    You do know you can get the group allow state for each event, in any script slot? So if you're generating a new play_note() in a subsequent script slot, that was triggered from play_note() in any of the previous script slots, you can loop through all the groups and repeat the allow state on your newly generated play_note() too...

Back To Top