Quick Sign In:  

Forum: VirtualDJ Technical Support

Topic: Can't "while_pressed" a function
Does anybody know why this won't work?

effect_active 3 & effect_stems Instru while_pressed
It toggles but doesn't work as a temporary hold on my pad

When I use:
effect_active 3 while_pressed

It works as expected.

Am I missing something out?
 

geposted Wed 04 Jan 23 @ 8:33 pm
locoDogPRO InfinityModeratorMember since 2013
down ? effect_stems instru 1 : effect_stems instru 0

do that, I don't know why you method doesn't work [it should, in theory], I guess you're more interested in "how to" than "why not"
 

geposted Wed 04 Jan 23 @ 8:38 pm
Thank you for your help.

Actually, I would like to know"Why?" as much as "How?"

For example, I have know idea why this didn't work?
select ? effect_stems instru 1: effect_stems vocal 1

I would've assumed they would be swapped.
 

geposted Wed 04 Jan 23 @ 10:39 pm
locoDogPRO InfinityModeratorMember since 2013
missing a space, also not turning effect stems off
 

geposted Thu 05 Jan 23 @ 4:12 am
This still did not work.

Are you able to tell me how to actually; set a effect_stems state to default that is changed to another effect_stems when; a button is A) toggled B) Temporary

I know very little of VDJ Script and I'm not very clever, even though I have used your DJ product for years.

I apologize if this is very simple for you to help with, and don't mean to trouble you. I am willing to learn, but I do need a little help with the things I'm an not any good at.

 

geposted Thu 05 Jan 23 @ 8:06 pm
locoDogPRO InfinityModeratorMember since 2013
select ? effect_stems instru 1 & effect_stems vocal 0 : effect_stems vocal 1 & effect_stems instru 0
 

geposted Thu 05 Jan 23 @ 8:14 pm
Thank for your help, really appreciate you giving me a direct solution.
 

geposted Thu 05 Jan 23 @ 8:53 pm
Update - Unfortunately after inputting, it does not seem to work.
Only the first part works - select ? effect_stems instru 1 & effect_stems vocal 0

When I hover across the script, the 2nd part shows red highlight? - I think it's telling me that I can't do it like that, is that right?

But some good news:
When I used down instead of select, it appears to nearly do it but in reverse; FX Vocal is on but when I release the button, FX Instru is swapped (though the GUI pad color state is off).
 

geposted Thu 05 Jan 23 @ 10:12 pm
djdadPRO InfinityDevelopment ManagerMember since 2005
Then use down ? and the actions in opposite side.
down ? effect_stems vocal 1 & effect_stems instru 0 : effect_stems instru 1 & effect_stems vocal 0

For the color, you need to provide further info.
Are you using the Pads Editor, editing a Pads page ?
Are you trying to map this to a Controller (which ?) button (which ?)
 

geposted Fri 06 Jan 23 @ 12:22 am
nicethings wrote :
When I hover across the script, the 2nd part shows red highlight? - I think it's telling me that I can't do it like that, is that right?


That is one of the cool, and so helpful parts of VDJ scripting:
The Green is the action when select is TRUE

and RED is the action, when select is FALSE.
 

geposted Fri 06 Jan 23 @ 5:56 am
Is there any way to add: Double-click switches Stem FX off?
 

geposted Sun 08 Jan 23 @ 2:10 pm
locoDogPRO InfinityModeratorMember since 2013
read the script description for
doubleclick
 

geposted Sun 08 Jan 23 @ 2:30 pm
Thanks for your advice.

I read the example and tried to follow, but the doubleclick doesn't seems to deactivate?

down ? effect_stems instru 1 & effect_stems vocal 0 : effect_stems vocal 1 & effect_stems instru 0 ? doubleclick : effect_stems 0

I still have to use down as using select in the code stops the stems from switching between Vocal and Instru states

 

geposted Mon 09 Jan 23 @ 1:43 am
locoDogPRO InfinityModeratorMember since 2013
I'd use a separate button,
doubleclick, holding, down, up queries don't work well together [they all monitor the same thing under the hood]

this is probably the best you can have and there's an unavoidable jitter for the first press of the double click, you're asking too much of 1 button

( doubleclick ? wait 30ms & effect_stems instru 0 & effect_stems vocal 0 : ) & down ? repeat_start tooMuch ? : effect_stems instru 1 & effect_stems vocal 0 & repeat_start tooMuch 300ms 1 & nothing : repeat_start tooMuch ? : effect_stems vocal 1 & effect_stems instru 0 & repeat_start tooMuch 300ms 1 & nothing


effect_stems 0 isn't valid script, it needs a stem type to be specified

select is a script related to deck selection, not a button press
 

geposted Mon 09 Jan 23 @ 3:43 am
I guess you're right, it's asking quite a bit for one button.

Thanks for your trying to help, as always :)
 

geposted Mon 09 Jan 23 @ 5:06 pm