Code:
Gui,Show,x40 y20 w450 h130,TargetID+StandbyTrigger(160229)
Gui,Font,'MS PGothic'l s14 bold,
Gui,Add,Text,x14 y10,[CSGO -TargetID+StandbyTrigger-]
Gui,Font,'MS PGothic'l s10 normal,
Gui,Add,Text,x14 y30,(※ TargetID Trigger required default dynamic crosshair+hud_showtargetid 1)
Gui,Add,Text,x14 y50,■[TargetID Trigger]
Gui,Add,Text,x130 y50,:: MXB2(bind MXB1(mouse4) as +attack)
Gui,Add,Text,x14 y65,■[Standby Trigger]
Gui,Add,Text,x130 y65,:: Shift+MXB2/MXB2+MB2(Shift/MB2 can be released.)
Gui,Add,Text,x14 y80,■[Suspend]
Gui,Add,Text,x130 y80,:: F10
Gui,Font,'MS PGothic'l s8 normal,
Gui,Add,Text,x14 y100,㊞ 4714 江南製造局. U:1:319913330/QQ9609001
Gui,Add,Text,x28 y110,https://www.mpgh.net/forum/showthread.php?t=1086893
key_Suspend:="F10"
key_Trigger:="vk06"
key_StandbyTrigger:="Shift & vk06"
key_StandbyTrigger2:="vk06 & vk02"
key_Attack:="vk05"
key_StandbyAttack:="vk01"
Threshold = 20
hotkey,*~$%key_Suspend%,a0
hotkey,*~$%key_Trigger%,a1
hotkey,%key_StandbyTrigger%,a2
hotkey,%key_StandbyTrigger2%,a2
return
a0:
suspend
return
a1:
while (GetKeyState(key_Trigger, "P")) {
MouseGetPos, MouseX, MouseY
PixelGetColor, color, MouseX, MouseY, RGB
PixelGetColor, colorz, MouseX, (MouseY+24), RGB
;MsgBox The color at the current cursor position is %color%.
StringSplit, x, color
StringSplit, z, colorz
R = 0x%x3%%x4%
G = 0x%x5%%x6%
B = 0x%x7%%x8%
Rz = 0x%z3%%z4%
Gz = 0x%z5%%z6%
Bz = 0x%z7%%z8%
if (R - 50 > G) or (Rz - 50 > Gz) {
send {blind}{%key_Attack% down}
sleep 135
send {blind}{%key_Attack% up}
sleep 15
}
}
return
a2:
BlockInput, MouseMove
sleep 1
MouseGetPos, MouseX, MouseY
PixelGetColor, Color2, (MouseX+3), (MouseY-9)
StringSplit, y, Color2
Color2B = 0x%y3%%y4%
Color2G = 0x%y5%%y6%
Color2R = 0x%y7%%y8%
Color2B += 0
Color2G += 0
Color2R += 0
sleep 5
while (GetKeyState(key_Trigger, "P")) {
MouseGetPos, MouseX, MouseY
PixelGetColor, Color1, (MouseX+3), (MouseY-9)
StringSplit, y, Color1
Color1B = 0x%y3%%y4%
Color1G = 0x%y5%%y6%
Color1R = 0x%y7%%y8%
Color1B += 0
Color1G += 0
Color1R += 0
if (Color1R > (Color2R + Threshold)) or (Color1R < (Color2R - Threshold)) or (Color1G > (Color2G + Threshold)) or (Color1G < (Color2G - Threshold)) or (Color1B > (Color2B + Threshold)) or (Color1B < (Color2B - Threshold)) {
send {blind}{%key_StandbyAttack% down}
sleep 135
send {blind}{%key_StandbyAttack% up}
sleep 15
sleep 145
}
}
BlockInput, MouseMoveOff
return
I tried replacing shift & vk06 to "CapsLock" directly, which works normally, but didnt work in this script.Is there something different about it?How can i change the shortcut to CapsLock?