Search found 7737 matches
- 12 May 2024, 11:44
- Forum: Ask for Help (v2)
- Topic: ByRef - Default value - is it possible at the same time?
- Replies: 1
- Views: 210
Re: ByRef - Default value - is it possible at the same time?
Hallo, try: #Requires AutoHotkey v2.0 #SingleInstance Force A := 1, B:= 2, Yes := "No" tstDef(&A, &B) MsgBox A "," B "," Yes ; A,100,Yes tstDef(&val1, &val2, val3:="Yes") { Global val1 := "A" val2 := 100 %val3% := val3 } Regarding %val3% := val3 see https://www.autohotkey.com/docs/v2/Variables.htm#...
- 12 May 2024, 10:57
- Forum: Ask for Help (v2)
- Topic: How to wait for the key "AltGr" to be pressed down or released ?
- Replies: 2
- Views: 197
Re: How to wait for the key "AltGr" to be pressed down or released ?
Hallo,
try:
try:
Code: Select all
#Requires AutoHotkey v2.0
F12:: {
if KeyWait("RAlt", "d")
MsgBox("AltGr or RAlt")
}
- 12 May 2024, 05:42
- Forum: Gaming Help (v1)
- Topic: How do i run on keydown
- Replies: 3
- Views: 313
Re: How do i run on keydown
Then:
Code: Select all
LAlt::SoundBeep ; left Alt Key: triggered on keydown input
RAlt::SoundBeep ; right Alt Key: triggered on keydown input
- 12 May 2024, 02:22
- Forum: Ask for Help (v2)
- Topic: About using PixelSearch for a single pixel Topic is solved
- Replies: 2
- Views: 255
Re: About using PixelSearch for a single pixel Topic is solved
Hallo, I compared it with a PixelMatchColor2() based on ImageSearch. Result: No relevant difference in speed! Try: #Requires AutoHotkey v2.0 CoordMode "Pixel", "Screen" q:: { x:=100, y:=100 , Color := 0x2D7D9B, Variance := 10 T := A_TickCount Loop 100 PixelMatchColor(x, y, Color, Variance) T1 := A_T...
- 12 May 2024, 00:24
- Forum: Ask for Help (v2)
- Topic: How to Send text as one string?
- Replies: 6
- Views: 525
- 11 May 2024, 10:56
- Forum: Ask for Help (v2)
- Topic: Subscripts
- Replies: 8
- Views: 373
Re: Subscripts
Hallo, try: #Requires AutoHotkey v2.0 #SingleInstance char := Map( 'a', Chr(8336) , 'e', Chr(8337) , 'h', Chr(8341) , 'i', Chr(7522) , 'j', Chr(11388) , 'k', Chr(8342) , 'l', Chr(8343) , 'm', Chr(8344) , 'n', Chr(8345) , 'o', Chr(8338) , 'p', Chr(8346) , 'r', Chr(7523) , 's', Chr(8347) , 't', Chr(83...
- 11 May 2024, 10:42
- Forum: Gaming Help (v1)
- Topic: ControlClick
- Replies: 1
- Views: 342
Re: ControlClick
Hallo,
try:
try:
Code: Select all
F8::
IF Down := !Down { ; toggles Left and Right mouse button down/up
ControlClick,, ahk_exe java.exe,, Left,, D
ControlClick,, ahk_exe java.exe,, Right,, D
} Else {
ControlClick,, ahk_exe java.exe,, Left,, U
ControlClick,, ahk_exe java.exe,, Right,, U
} Return
- 11 May 2024, 10:18
- Forum: Gaming Help (v1)
- Topic: How do i run on keydown
- Replies: 3
- Views: 313
Re: How do i run on keydown
Hallo,
apart from Control::, Alt:: and Shift:: all simple Hotkeys are triggered on keydown input.
I.e. what you want is the default.
Does "ULTRAKILL" also help against real-life mosquitoes?
apart from Control::, Alt:: and Shift:: all simple Hotkeys are triggered on keydown input.
I.e. what you want is the default.
Code: Select all
q::SoundBeep ; triggered on keydown input
Control::SoundBeep ; triggered on keyup input
- 11 May 2024, 04:04
- Forum: Ask for Help (v1)
- Topic: Trying to press keys based on color.
- Replies: 1
- Views: 317
Re: Trying to press keys based on color.
Hallo, try: key := {0x161015: 12, 0x0000FF: 3, 0x00FF00: 1, 0xFF0000: 2} [:: SetTimer, Spam, % (on := !on) ? 1000 : "Off" SoundBeep, 1000 + 500 * on Return Spam: PixelGetColor, bgr, 184, 711 ; Blue-green-red; coordinates relative to the active window Loop, Parse,% key[bgr] Send, {%A_LoopField%} Retu...
- 11 May 2024, 02:51
- Forum: Ask for Help (v1)
- Topic: Can't make key be held down Topic is solved
- Replies: 2
- Views: 483
Re: Can't make key be held down Topic is solved
Hallo, see: https://www.autohotkey.com/docs/v1/misc/RemapController.htm#auto-repeating-controller-buttons Some programs or games might require a key to be sent repeatedly (as though you are holding it down on the keyboard) Try: \::Repeat("o", 30) ; a Timer sends {Blind}{o Down} every 30 ms q::Repeat...
- 10 May 2024, 06:28
- Forum: Ask for Help (v1)
- Topic: Hotkeys heriarcal priority
- Replies: 2
- Views: 423
Re: Hotkeys heriarcal priority
Hallo, or: !^f10:: Hotkey, IfWinActive, ahk_exe notepad.exe Hotkey, f10, f10, Off Hotkey, *f10, myLabel return myLabel: msgbox, I’d like this to take precedence while random.exe is active return #IFwinactive, ahk_exe notepad.exe f10:: msgbox, this will be triggered instead return #IF
- 10 May 2024, 03:10
- Forum: Gaming Help (v1)
- Topic: WoW with AHK PixelGetColor
- Replies: 3
- Views: 442
Re: WoW with AHK PixelGetColor
Hallo,
you could replace all If Color!=000000 with If Color
and all if exiter = 1 with if exiter, but I don't think that would help much.
Maybe it helps to split the big loop into several scripts which are switched on and off by the main script.
@joedf this is an Autohotkey v1.1 script.
you could replace all If Color!=000000 with If Color
and all if exiter = 1 with if exiter, but I don't think that would help much.
Maybe it helps to split the big loop into several scripts which are switched on and off by the main script.
@joedf this is an Autohotkey v1.1 script.
- 10 May 2024, 02:34
- Forum: Gaming
- Topic: search AHK V2 for EMCol
- Replies: 1
- Views: 156
- 10 May 2024, 00:32
- Forum: Ask for Help (v2)
- Topic: script that makes it so when a key is pressed, it remains activated until I press it again Topic is solved
- Replies: 2
- Views: 149
Re: script that makes it so when a key is pressed, it remains activated until I press it again Topic is solved
Hallo, try: #Requires AutoHotkey v2.0 *a:: { Static A := False Send (A:=!A)?"{Blind}{a down}":"{Blind}{a up}" KeyWait "a" } or with AutoRepeat: #Requires AutoHotkey v2.0 *a:: { Static A := False, T:=()=>Send("{Blind}{a downR}") SetTimer(T, 30*A:=!A), A?T():Send("{Blind}{a up}") KeyWait "a" } Other k...
- 09 May 2024, 09:07
- Forum: Ask for Help (v1)
- Topic: AutoHotkeyH vs AutoHotkeyL vs AutoHotkey2
- Replies: 21
- Views: 4980
Re: AutoHotkeyH vs AutoHotkeyL vs AutoHotkey2
Hallo,
no! There is no such thing as q & w & e:: in any Autohotkey.
no! There is no such thing as q & w & e:: in any Autohotkey.
- 09 May 2024, 01:38
- Forum: Gaming
- Topic: Clicking a position without releasing rightclick
- Replies: 5
- Views: 375
Re: Clicking a position without releasing rightclick
Hallo,
instead of using PostMessage, I would have tried clicking with ControlClick first!
instead of using PostMessage, I would have tried clicking with ControlClick first!
- 08 May 2024, 11:15
- Forum: Ask for Help (v1)
- Topic: Simple remap script consultation
- Replies: 1
- Views: 358
Re: Simple remap script consultation
Hallo,
according to your requirement, it should work like this:
according to your requirement, it should work like this:
Code: Select all
Space::
Send, {Ctrl down}{Shift down}{w down}
sleep 30
Send, {Blind}{x down}
sleep 30
Send, {Ctrl up}{Shift up} ; hold w and x only, releasing Shift and Ctrl
KeyWait, Space
Send, {w up}{x up}
return
- 08 May 2024, 02:51
- Forum: Ask for Help (v1)
- Topic: Hook for window
- Replies: 2
- Views: 410
Re: Hook for window
Hallo, try: DllCall("RegisterShellHookWindow", "UInt", A_ScriptHwnd) OnMessage(DllCall("RegisterWindowMessage", "Str", "SHELLHOOK"), "act") Return act(wParam, lParam) { If (wParam = WINDOWCREATED := 1) SoundBeep } but when "an existing Window is moving" could be a problem for a WinHook. https://www....
- 06 May 2024, 05:05
- Forum: Ask for Help (v1)
- Topic: How to disable enable a portion of ahk scrip on pressing hotkey? Topic is solved
- Replies: 2
- Views: 306
Re: How to disable enable a portion of ahk scrip on pressing hotkey? Topic is solved
Hallo, F4 toggles all Hotkeys between #IF SpecialHotkeys and #IF on/off: F4::SpecialHotkeys:=!SpecialHotkeys Numpad1::SoundBeep, 4000, 20 Numpad2::SoundBeep, 2000, 20 Numpad3::SoundBeep, 1000, 20 #IF SpecialHotkeys Numpad4::SoundBeep, 4000, 20 Numpad5::SoundBeep, 2000, 20 Numpad6::SoundBeep, 1000, 2...
- 06 May 2024, 02:30
- Forum: Ask for Help (v1)
- Topic: sub script no working
- Replies: 2
- Views: 397
Re: sub script no working
Hallo,
try:
try:
Code: Select all
#s up::
send,% (ClipBoard:="") "^c"
ClipWait, 0
run, http://www.google.com/search?q=%clipboard%
return