Quick Sign In:  

Forum: General Discussion

Topic: Cycle 'my_var' On Key Press
How can I cycle my_var on the same button.

Hi to you'all.

By this question I also want to share a creativity transition I implement while mixing and hoping someone can grab it and take it to the next level; That is what Djíng is all about. In a controller enviroment this is almost useless, but mixing with a bascic mixer and two turntables with TCV it comes handy.


I have the following script on the keyboard 'Shift+F5' key.

cycle 'BG' 3

So I can cycle between the first 3 beatGrid effect arrangement; we can go to eight you know!



Then to activate the effect I have the following script on the 'F5' key on the Keyboard.

var_equal 'BG' 0 ? deck 1 effect_active 'beat grid' & effect_slider 'beat grid' 1 0 & deck 2 effect_active 'beat grid' & effect_slider 'beat grid' 1 0 :
var_equal 'BG' 1 ? deck 1 effect_active 'beat grid' & effect_slider 'beat grid' 1 0.143 & deck 2 effect_active 'beat grid' & effect_slider 'beat grid' 1 0.143 :
var_equal 'BG' 2 ? deck 1 effect_active 'beat grid' & effect_slider 'beat grid' 1 0.286 & deck 2 effect_active 'beat grid' & effect_slider 'beat grid' 1 0.286 :


This let's me change the BeatGrid Slot on both deck and activate them at the same time.

I use this 1 bar before the Outro kicks in on Deck A at the same time it activates 1 bar before the Mix in on Deck B; there are other variation ofcourse..!

The Question in hand is:

How can I cycle between the beatgrid slots in the same Keyboard press; example pres F5 activates slot 1 press F5 again and it goes the second slot, and again for the third and cycles back to slot 1?

 

Posted Wed 24 May 23 @ 7:37 pm
locoDogPRO InfinityModeratorMember since 2013
cycle varName X
x being the number it cycles back to zero
example
set a 5 & cycle a 6

this case it increments var a by one, because six has been specified then it rolls back to zero, the result is var_equal a 0 ? true

you can use negative numbers with the cycle verb to de-increment
example
set a 0 & cycle a -6

the result from this case is
var_equal a 5 ? true
 

Posted Wed 24 May 23 @ 9:22 pm
Hi Locodog,

I've been reading it a couple of times, I think I understand a little. Will try, thank you for the heads up. If I get it, I'll post it.
Once again Thank You.
 

Posted Thu 25 May 23 @ 2:00 pm