Quick Sign In:  

Forum: General Discussion

Topic: Script School - Page: 45.70
locoDogPRO InfinityModeratorMember since 2013
DECK ALL
A useful deck specifier for when you want all decks to do something but there are logical implications.

Check the var_list after pressing this button
deck all set result1 `get_deck` & set $result1 +1 & deck 1 set result2 +1

result2's value may come as a surprise, what's happened under the hood the script actually performed is this

( deck 1 set result1 `get_deck` & set $result1 +1 & deck 1 set result2 +1 ) & 
( deck 2 set result1 `get_deck` & set $result1 +1 & deck 1 set result2 +1 ) &
( deck 3 set result1 `get_deck` & set $result1 +1 & deck 1 set result2 +1 ) &
( deck 4 set result1 `get_deck` & set $result1 +1 & deck 1 set result2 +1 )


It repeated the script for each deck so result2 is incremented 4 times

Playing with the logic, you can do something like this
make every other deck [other than the calling deck] play
set $deckvar `get_deck` & deck all param_equal `get_var $deckvar` `get_deck` ? : play_pause


Short and sweet,
If you need to use deck all for simple scripts there's no problem.
If you need deck all in more complicated scripts it's probably best to contain it in ( ) [deck specified in brackets only stay true inside the brackets]
There's probably some shortcuts here for complicated multideck scripts, just be wary, things can get confusing fast.
 

Posted Mon 18 Mar 24 @ 12:51 am
mg_1978PRO InfinityMember since 2008
locodog wrote :
I've asked you to stop quoting when it's clear whom you're replying to in this thread. Now I'm telling you, I will stop replying to you if I have to edit your posts again.

What's wrong with just?
deck all beatlock
It will sync from that


ok, i have understand, but i rewrite correct script for all users that have same request, ok? in all these pages (supreme blog for me!) i have read many and many script that have illuminated me for my personal mapper modifiers…and i think other members could make some thing…but if you don’t want these anymore, i stop post correct script, ok!
Thanks for all support Locodog 👍

 

Posted Wed 20 Mar 24 @ 9:00 am
mg_1978PRO InfinityMember since 2008
locodog wrote :
I've asked you to stop quoting when it's clear whom you're replying to in this thread. Now I'm telling you, I will stop replying to you if I have to edit your posts again.

What's wrong with just?
deck all beatlock
It will sync from that


…mmm not that i would…because ‘deck all beatlock’ sync other deck to the focused deck and not to the masterdeck..i wont masterdeck 👍 but i solved..thanks a lot

 

Posted Wed 20 Mar 24 @ 7:27 pm
locoDogPRO InfinityModeratorMember since 2013
@mg_1978
You're wrong on several levels, but if you're not going to respect my request, I don't see why I should bother replying to correct you.
 

Posted Thu 21 Mar 24 @ 1:25 am
mg_1978PRO InfinityMember since 2008
Hi!
virtualfolder_add ‘Sampler/Recordings’
why don’t work? Recordings is not a folder? 🤔 thanks a lot
 

Posted Fri 22 Mar 24 @ 5:46 pm
locoDogPRO InfinityModeratorMember since 2013
A user requested this [make beatjump wrap round an existing loop]

Senky Dragon wrote :
Is there a way to make beatjump wrap round a loop?

If I set a 32 beat loop, am currently 28 beats through the loop, and jump forward 8 beats, I would expect to be on beat 4 of the existing loop.


I thought it kind of interesting

for jumping forward in the loop things to consider;
are we in a loop ? [if not nothing special needed]
is our jump bigger than the whole loop ? [idiot check, if true do nothing],
is our current position in the loop added to the beatjump, smaller than the loop size? [if so nothing special needed] [we get our position in the loop in beats by param_multiply get_loop loop_position]
if false do some math, our loop size * -1, added to beatjump gives us the amount we need to jump back. [wrap around]

a forward button it would be like this

loop 0 ? beatjump +1 : param_bigger get_loop beatjump ? nothing : param_bigger `param_add 'param_multiply get_loop loop_position' beatjump` get_loop ? beatjump +1 : param_add 'param_multiply get_loop -1' 'beatjump' & param_cast relative & goto


Backwards is a little different
mainly our wrap check, is beatjump value smaller than current loop position.
[if it is nothing special needed]
if false, our beatjump value * -1, added to our loop size is the amount we need to jump forward [wrap around]

a backwards button like this

loop 0 ? beatjump -1 : param_bigger get_loop beatjump ? nothing : param_smaller `param_multiply get_loop loop_position` beatjump ? beatjump -1 : param_add get_loop 'param_multiply beatjump -1' & param_cast relative & goto


Case of encoders it would be something like this.
[same as above combined, but also need to deal with the implicit of the encoder]

param_bigger 0 ? loop 0 ? beatjump +1 : param_bigger get_loop beatjump ? nothing : param_bigger `param_add 'param_multiply get_loop loop_position' beatjump` get_loop ? beatjump +1 : param_multiply 0 & param_add "param_add 'param_multiply get_loop -1' 'beatjump'" & param_cast relative & goto : loop 0 ? beatjump -1 : param_bigger get_loop beatjump ? nothing : param_smaller `param_multiply get_loop loop_position` beatjump ? beatjump -1 : param_multiply 0 & param_add "param_add get_loop 'param_multiply beatjump -1'" & param_cast relative & goto
 

Posted Thu 11 Apr 24 @ 6:55 pm
Hi, I can't use JOG_WHEEL to smoothly change the position of the end of the loop section. Is there any option? Thanks
 

Posted Sat 20 Apr 24 @ 11:19 pm
locoDogPRO InfinityModeratorMember since 2013
see the wheel_mode script
 

Posted Sat 20 Apr 24 @ 11:24 pm
wheel_mode 'loop_out' ? wheel_mode 'loop_out,jog' : loop ? wheel_mode 'loop_out,jog' : loop_out
Already solved. Bye.
 

Posted Sat 20 Apr 24 @ 11:27 pm
I'm trying to modify Touchdan's Title (Video Skin) to work for my needs.

I'd noticed that the title didn't always appear, or seemed to favour one deck over the other, so I investigated...

The original code looks like it checks the crossfader position to determine whether to show or not:
visibility="pulse 25000ms '`param_equal get_crossfader_result 0 ? deck left load_pulse : param_equal get_crossfader_result 1 ? deck right load_pulse : fadeout 1000ms 750ms`'"


I don't use the crossfader (so it sits centrally) which I guess is why the titles are inconsistent.

I found is_audible being used in another videoskin so borrowed the code:
visibility="is_audible 'or scratch' & fadeout 1000ms 500ms"


That works, but I've been trying to add a delay so that the text appears after 5 seconds of play rather than immediately, but so far have failed in all attempts.

(no idea what the 'or scratch' is doing)
 

Posted Sun 21 Apr 24 @ 9:43 am
locoDogPRO InfinityModeratorMember since 2013
Try load_pulse_active

visibility="load_pulse_active 2000ms 5000ms & fadeout 1000ms 500ms"
 

Posted Sun 21 Apr 24 @ 12:03 pm
Thank you locodog. I just did a quick mod to make it stay on screen a little longer, and we're away!
 

Posted Sun 21 Apr 24 @ 1:11 pm