2010-06-15, 00:10:44
By request from 3imi, this is the script I use. Quite sure you dont need the full text but here it is:
Last 9 lines are the ones you should look at, the other things should be auto-generated by WarKey.
Code:
#SingleInstance force ;force a single instance
#HotkeyInterval 0 ;disable the warning dialog if a key is held down
#InstallKeybdHook ;Forces the unconditional installation of the keyboard hook
#UseHook On ;might increase responsiveness of hotkeys
#MaxThreads 20 ;use 20 (the max) instead of 10 threads
SetBatchLines, -1 ;makes the script run at max speed
SetKeyDelay , -1, -1 ;faster response (might be better with -1, 0)
;Thread, Interrupt , -1, -1 ;not sure what this does, could be bad for timers
SetTitleMatchMode, 3 ;title Warcraft III must match exactly
SetDefaultMouseSpeed, 0 ;Move the mouse faster for mouse moving commands
IfExist, Warcraft III.ico
menu, tray, Icon, Warcraft III.ico, 1, 1
;;;;; Variables ;;;;;
bInChatRoom := False
bHealthBarOn := False
Return ; End Auto-Execute Section
; AutoCast Function
AutoCast(iSpellQWERHotkey)
{
MouseGetPos, iMousePosX, IMousePosY
if (iSpellQWERHotkey == 1)
{
iMouseGotoX := A_ScreenWidth*4//5
iMouseGotoY := A_ScreenHeight*4//5
}
else if (iSpellQWERHotkey == 2)
{
iMouseGotoX := A_ScreenWidth*4//5
iMouseGotoY := A_ScreenHeight*22//25
}
else if (iSpellQWERHotkey == 3)
{ iMouseGotoX := A_ScreenWidth*4//5
iMouseGotoY := A_ScreenHeight*19//20
}
else if (iSpellQWERHotkey == 4)
{
iMouseGotoX := A_ScreenWidth*17//20
iMouseGotoY := A_ScreenHeight*4//5
}
else if (iSpellQWERHotkey == 5)
{
iMouseGotoX := A_ScreenWidth*17//20
iMouseGotoY := A_ScreenHeight*22//25
}
else if (iSpellQWERHotkey == 6)
{
iMouseGotoX := A_ScreenWidth*17//20
iMouseGotoY := A_ScreenHeight*19//20
}
else if (iSpellQWERHotkey == 7)
{
iMouseGotoX := A_ScreenWidth*9//10
iMouseGotoY := A_ScreenHeight*4//5
}
else if (iSpellQWERHotkey == 8)
{
iMouseGotoX := A_ScreenWidth*9//10
iMouseGotoY := A_ScreenHeight*22//25
}
else if (iSpellQWERHotkey == 9)
{
iMouseGotoX := A_ScreenWidth*9//10
iMouseGotoY := A_ScreenHeight*19//20
}
else if (iSpellQWERHotkey == 10)
{
iMouseGotoX := A_ScreenWidth*19//20
iMouseGotoY := A_ScreenHeight*4//5
}
else if (iSpellQWERHotkey == 11)
{
iMouseGotoX := A_ScreenWidth*19//20
iMouseGotoY := A_ScreenHeight*22//25
}
else if (iSpellQWERHotkey == 12)
{
iMouseGotoX := A_ScreenWidth*19//20
iMouseGotoY := A_ScreenHeight*19//20
}
Click, Right, %iMouseGotoX%, %iMouseGotoY%
MouseMove, %iMousePosX%, %iMousePosY%
}
#ifWinActive, Warcraft III ahk_class Warcraft III
;;;;; Enable/disable all hotkeys ;;;;;
~*Enter::
~*NumpadEnter::
Suspend, Permit
if (bInChatRoom == True)
return
Suspend
if (A_IsSuspended == true)
SetScrollLockState, Off
else
SetScrollLockState, On
return
;; Escape will cancel chatting, so turn the hotkeys back on
~*Esc::
Suspend, Permit
if (bInChatRoom == True)
return
Suspend, Off
SetScrollLockState, On
return
*ScrollLock::
Suspend, Permit
bInChatRoom := not bInChatRoom
if (bInChatRoom == True)
{
Suspend, On
SetScrollLockState, Off
}
else
{
Suspend, Off
SetScrollLockState, On
}
return
; Disable Left Alt-Q GG
<!q::return
; Inventory Keys:
f::Numpad4
g::Numpad5
s::Numpad1
d::Numpad2
; Hotkeys Remapper:
k::SendPlay, {Enter}-rc{Enter}{Enter}-anglez 65{Enter}{Enter}-zoom 5000{Enter}
l::SendPlay, +{Enter}-team No Skill, Just Luck{Enter}
Last 9 lines are the ones you should look at, the other things should be auto-generated by WarKey.
SC2: Equiem (Charcode 990), whisper me if you wish to practise some 1vs1 or grab some achievements
Repeat while playing: "There is no such thing as luck in Btanks" - Now watch yourself improve tenfold
Repeat while playing: "There is no such thing as luck in Btanks" - Now watch yourself improve tenfold