Page 1 of 2

hey,,,how can i make a repeat?

Posted: 05 Jul 2015 21:37
by digitalson
a simple button or pad repeat when holding it down like a keyboard? and release when let go of it,not a timed repeat,just it keep going? like if i had a nudge command on a keyboard u press it once or if u hold it down it keeps on going,,,,thanks!!!

Re: hey,,,how can i make a repeat?

Posted: 06 Jul 2015 16:48
by ndivuyo
depends on the interval you want to repeat, but you'd have a script run 'on frame' or 'on expression' of an expression that's constantly changing value as you hold down your pad. Then that script will constantly execute as you hold down your pad.

then you will add the noteout() or whatever script to send the desired repeated trigger and surround that with a condition that only sends out the note when the pad is pressed.

There's actually a ton of ways to do it, just see which one works best for you. Look up in the user manual/wherever how to use noteout(), I know I walked you through it before on another post. So with that knowledge, learn how to make a codition with an "if" statement, and how to make a script that executes "on frame" unless you find a more CPU friendly way to have an expression trigger the script (I like to make a slider with physics slowly move, and then trigger scripts on it's 'x' or something') The point is, if it repeats it must have something that is constantly triggering the script to send out the note value

Re: hey,,,how can i make a repeat?

Posted: 08 Jul 2015 21:37
by digitalson
I need it to act like a keyboard,not like the delay function its to slow

Re: hey,,,how can i make a repeat?

Posted: 09 Jul 2015 18:24
by digitalson
Anyone?

Re: hey,,,how can i make a repeat?

Posted: 10 Jul 2015 10:41
by MrCorba
I've put an example below. It has a delay time scripted in, so it's possible to just press once, without the script keeps repeating. You can change the delay in the repeat script.

Re: hey,,,how can i make a repeat?

Posted: 12 Jul 2015 18:56
by digitalson
hey thanks ,i tried it and its a little confusing i need a pad or button to act like a key on a computer keyboard ,press it once or hold it down to repeat it fast ,van u make or show me how to do that that repeats faster ,but after a single press,,,thanks

Re: hey,,,how can i make a repeat?

Posted: 12 Jul 2015 21:18
by MrCorba
Read the comments in the act script of the pad, you can delete the fader and monitor, I just put them there to show how it works. I have no experience with keycombout, but you could you paste the appropriate code in the act script.

Re: hey,,,how can i make a repeat?

Posted: 13 Jul 2015 03:48
by digitalson
ok i figured out a way for it to work, using ur delay pad i put the value in the x and want to put the ctlout in place of the fader and it works nice but i dont know how or where it should go,

if(x==1){
if(delay != 24){ //Change this to adjust delay time
delay++;
} else
cltout(1,23,127,10) //Paste here your own expression you want to execute
}
}

if u can help me with the syntax it would work great!!!its not right

Re: hey,,,how can i make a repeat?

Posted: 13 Jul 2015 07:42
by MrCorba
I see a few errors in syntax but that could be typo's. Here is how the syntax should be:

Code: Select all

if(x==1){
if(delay != 24){ //Change this to adjust delay time
delay++;
} else {
ctlout(1,23,127,10); //Paste here your own expression you want to execute
}
}
I'm pretty sure this should now work. I'm not in a place to test right now, but if you still have some trouble I'll try to look in to it this afternoon.

Re: hey,,,how can i make a repeat?

Posted: 13 Jul 2015 20:04
by digitalson
What I did that worked was put the control in the x and put a button underneath it for the repeat ,this way u can press it once and hold it done to repeat,,it works great ,and it faster than the keyboard,,,,but i will try ur script ,,,,,so i just used x as the output and the second pad as the repeat,,,but if 1 pad can do it even better,,,thanks,good job