Page 1 of 1

Handy Autokeys script for mouseless DJing (PC)

Posted: Sat Feb 18, 2006 12:32 pm
by MrTiddles
Hi guys

I've been on this site for a while, stealing all your ideas which you've all worked so hard on. So I thought I'd give something back!

This is a little script I put together last night which allows you to load in data from the browser into the session view. So by hitting Alt+F1 it will load whatever you've highlighted into track 1. This only works for 6 tracks (Alt+f1.....f6) as I've only got 6 tracks in my DJ setup. This works best with Djsynchro's browser script (thanks!) and is what this is originally based on.

This based on arrow key commands rather than mouse movements so it should work with any PC Live setup

I hope this is as useful to some of you as it is to me. :wink:

!F1:: ; Load Sample into Track1 Cell1
IfWinActive, ahk_class Afx:00400000:0:00000000:01900015:00000000
{

Send, {CTRLDOWN}c{CTRLUP}{ALTDOWN}{RIGHT}{ALTUP}{UP}{UP}{UP}{UP}{UP}{UP}{UP}{LEFT}{LEFT}{LEFT}{LEFT}{LEFT}{LEFT}{LEFT}{CTRLDOWN}v{CTRLUP}{EXIT}
Return

}

!F2:: ; Load Sample into Track2 Cell1
IfWinActive, ahk_class Afx:00400000:0:00000000:01900015:00000000
{
Send, {CTRLDOWN}c{CTRLUP}{ALTDOWN}{RIGHT}{ALTUP}{UP}{UP}{UP}{UP}{UP}{UP}{UP}{LEFT}{LEFT}{LEFT}{LEFT}{LEFT}{LEFT}{LEFT}{RIGHT}{CTRLDOWN}v{CTRLUP}
Return
}


!F3:: ; Load Sample into Track3 Cell1
IfWinActive, ahk_class Afx:00400000:0:00000000:01900015:00000000
{
Send, {CTRLDOWN}c{CTRLUP}{ALTDOWN}{RIGHT}{ALTUP}{UP}{UP}{UP}{UP}{UP}{UP}{UP}{LEFT}{LEFT}{LEFT}{LEFT}{LEFT}{LEFT}{LEFT}{RIGHT}{RIGHT}{CTRLDOWN}v{CTRLUP}
Return
}

!F4:: ; Load Sample into Track4 Cell1
IfWinActive, ahk_class Afx:00400000:0:00000000:01900015:00000000
{
Send, {CTRLDOWN}c{CTRLUP}{ALTDOWN}{RIGHT}{ALTUP}{UP}{UP}{UP}{UP}{UP}{UP}{UP}{LEFT}{LEFT}{LEFT}{LEFT}{LEFT}{LEFT}{LEFT}{RIGHT}{RIGHT}{RIGHT}{CTRLDOWN}v{CTRLUP}
Return
}

!F5:: ; Load Sample into Track5 Cell1
IfWinActive, ahk_class Afx:00400000:0:00000000:01900015:00000000
{
Send, {CTRLDOWN}c{CTRLUP}{ALTDOWN}{RIGHT}{ALTUP}{UP}{UP}{UP}{UP}{UP}{UP}{UP}{LEFT}{LEFT}{LEFT}{LEFT}{LEFT}{LEFT}{LEFT}{RIGHT}{RIGHT}{RIGHT}{RIGHT}{CTRLDOWN}v{CTRLUP}
Return
}

!F6:: ; Load Sample into Track6 Cell1
IfWinActive, ahk_class Afx:00400000:0:00000000:01900015:00000000
{
Send, {CTRLDOWN}c{CTRLUP}{ALTDOWN}{RIGHT}{ALTUP}{UP}{UP}{UP}{UP}{UP}{UP}{UP}{LEFT}{LEFT}{LEFT}{LEFT}{LEFT}{LEFT}{LEFT}{RIGHT}{RIGHT}{RIGHT}{RIGHT}{RIGHT}{CTRLDOWN}v{CTRLUP}
Return
}

Posted: Sun Feb 19, 2006 11:20 am
by CopyRightJustice
MrTiddles nice one sorry to jump in on your post here's a differnt angle

This version loads to the top clipslot of four tracks this one works with mouse moves so depending on what you have in view the vetical position may be incorrect also the hotkeys will clash with Djsynchro's browser script.Using alt sometimes messes up the script I just use plain keys, any one know why this is?

!8::
IfWinActive, ahk_class Afx:00400000:0:00000000:01900015:00000000
{
send,^c
MouseGetPos, xpos, ypos
MouseClick, left, 21, 92, 1 , 0
MouseClick, left, 67, 118, , 0
send,^v
MouseClick, left, 21, 92, 1 , 0
MouseMove, xpos, ypos
Return
}
!9::
IfWinActive, ahk_class Afx:00400000:0:00000000:01900015:00000000
{
send,^c
MouseGetPos, xpos, ypos
MouseClick, left, 21, 92, 1 , 0
MouseClick, left, 135, 118, , 0
send,^v
MouseClick, left, 21, 92, 1 , 0
MouseMove, xpos, ypos
Return
}
!0::
IfWinActive, ahk_class Afx:00400000:0:00000000:01900015:00000000
{
send,^c
MouseGetPos, xpos, ypos
MouseClick, left, 21, 92, 1 , 0
MouseClick, left, 217, 118, , 0
send,^v
MouseClick, left, 21, 92, 1 , 0
MouseMove, xpos, ypos
Return
}
!-::
IfWinActive, ahk_class Afx:00400000:0:00000000:01900015:00000000
{
send,^c
MouseGetPos, xpos, ypos
MouseClick, left, 21, 92, 1 , 0
MouseClick, left, 294, 118, , 0
send,^v
MouseClick, left, 21, 92, 1 , 0
MouseMove, xpos, ypos
Return
}

Posted: Sun Feb 19, 2006 12:53 pm
by CopyRightJustice
After using your script I think that it's better mine has to many pitfalls;

1.Dependant on what is in view the vertical position maybe wrong.
2.Using alt makes it paste the clip on previously selected slot,it seemes to paste before the mouse has moved?
3.Scrolling of the window to a position other than all the way left srews it.

Mouseless

1.have to add more arrows for bigger sets, not so bad

Well done MrTiddles I will use yours now ,anyone know how to solve the problems with my script

Posted: Sun Feb 19, 2006 9:50 pm
by djsynchro
Hey! That seems to work really good, nice one. (I didn't know about that ALT-arrow key stuff where did you find that out?)

Posted: Mon Mar 13, 2006 9:53 am
by creepjoint
this may seem dumb, but what the hell is all that....

how does a clueless wonder put the above to work...where does all that scripting go ??

thanks in advance :D

Posted: Mon Mar 13, 2006 1:28 pm
by djsynchro
You need to put it in a text file with notepad and save it with the extension .ahk and you need to get autohotkeys free at www.autohotkeys.com

Do a search on the forum for "hotkeys"there are some handy scripts around.

Posted: Tue Mar 14, 2006 11:21 am
by creepjoint
djsynchro wrote:You need to put it in a text file with notepad and save it with the extension .ahk and you need to get autohotkeys free at www.autohotkeys.com

Do a search on the forum for "hotkeys"there are some handy scripts around.
Cheers :D

Posted: Sun Apr 23, 2006 7:50 am
by LOFA
would this sort of thing work with one of bigbadotis's apps?

Posted: Wed May 31, 2006 11:27 am
by Patch
This looks ace. Will it work if you want to copy the contents of a folder into a tracK?

I have a folder for each tune (withh each tune broken into smaller clips), and would like to be able to load all the clips from that folder into a track at once.

Can this be done?

Also - I see that this script just loads to the top slot of a track. Is there a way to have the clip(s) loaded into the NEXT slot down? Or, even better, if you can load the clip(s) to the active (ie - highlighted) slot on a track?

Posted: Sun Sep 10, 2006 10:48 pm
by Patch
:oops: BUMP :oops:

Never did get an answer to that...^^^

Anybody?

Posted: Tue Sep 12, 2006 3:56 pm
by vip32
Patch wrote:This looks ace. .... Or, even better, if you can load the clip(s) to the active (ie - highlighted) slot on a track?
add this to the script, use alt-enter from the browser to put the clip in the current track/cell. live's default behaviour is creating a new track.

Code: Select all

!ENTER:: ; Load Sample into CURRENT Track CURRENT Cell
IfWinActive, ahk_class Afx:00400000:0:00000000:01900015:00000000
{
Send, {CTRLDOWN}c{CTRLUP}{ALTDOWN}{DOWN}{UP}{ALTUP}{CTRLDOWN}v{CTRLUP}{EXIT}
Return
}

Posted: Tue Sep 12, 2006 4:05 pm
by vip32
combine all this scripting with http://www.xkeys.com/xkeys/xkcontrol.php and i makes much more sense :)

Posted: Tue Sep 12, 2006 4:06 pm
by Patch
:D

Do I just add the above text onto the end of the original script?

Posted: Wed Sep 13, 2006 6:35 am
by vip32
Patch wrote::D

Do I just add the above text onto the end of the original script?
yup

Posted: Mon Sep 18, 2006 12:37 pm
by MrTiddles
Loading into different cells (other than the top row) is pretty straight foward. If you look at the script for for loading into cells 2, 3, 4 etc you'll notice a (RIGHT) command. After the last (RIGHT), put in a (DOWN) to specify how many Cells down you want to copy the audio.

Copying Multiple audio tracks is something I haven't figured out yet, at this script I put together has a couple of bugs in it. As it operates in an 8x8 cells grid, if you are in another window or frame, the script won't work. I've created panic button and tempo change scripts if there any interest for them.

I'm currently working on a setup called the 'V-BOX' which basically consists of a 17' iMAC, an X-Session and BCR2000 and can be used as a Live perfomance tool as well as for DJing. Cos it's MAC based, making it mouseless is proving to be a pain in the a$$, but once I crack it, I'll post some images, scripts etc.

Cheers