Search found 62 matches

by Nod1234
19 Sep 2023, 06:45
Forum: Ask for Help (v2)
Topic: SetTime + Func()
Replies: 3
Views: 311

Re: SetTime + Func()

Thank you for your answer. I guess the keypoint was

Code: Select all

.Bind
for the function call.
by Nod1234
19 Sep 2023, 04:50
Forum: Ask for Help (v2)
Topic: SetTime + Func()
Replies: 3
Views: 311

SetTime + Func()

Hi, can somebody explain me why SetTimer is not working with a function that should receive and send back a value? Numpad1::{ Static x:=5 Func1(x) ToolTip Func1(x) } Func1(x){ Static y:=x+2 Return y } Numpad2::{ Static x:=6 SetTimer Func2(x), 1000 ;Why is SetTimer in this case not working? ToolTip F...
by Nod1234
30 Aug 2023, 14:01
Forum: Ask for Help (v2)
Topic: Keywait with boolean status?
Replies: 6
Views: 466

Re: Keywait with boolean status?

Hi, yes a while loop could be used. But I don't use such loops in my script regarding performance. Thanks
by Nod1234
30 Aug 2023, 02:52
Forum: Ask for Help (v2)
Topic: Keywait with boolean status?
Replies: 6
Views: 466

Re: Keywait with boolean status?

Hey,
if you hold Numpad2/2, the Hotkey Numpad1/1 should wait at line

Code: Select all

KeyWait (variable1==False) ; KeyWait "Numpad2"
until Numpad2/2 is released.
But the "KeyWait" should not base on the Key itself (KeyWait "Numpad2"), it should instead use the variable1.

Is it clear now?
by Nod1234
30 Aug 2023, 00:02
Forum: Ask for Help (v2)
Topic: Keywait with boolean status?
Replies: 6
Views: 466

Keywait with boolean status?

Hey, i want to usw a Global Variable1 to set a Hotkey in wait like this: ; ### Variable Initialization Global variable1 := False, variable2 := False ; ### Testarea ### Numpad1::{ ToolTip variable1 KeyWait (variable1==False) ; KeyWait "Numpad2" Global variable2 := True SendEvent "{g}" KeyWait "Numpad...
by Nod1234
12 Feb 2023, 03:09
Forum: Ask for Help (v2)
Topic: ternary operator: variable+key
Replies: 1
Views: 328

ternary operator: variable+key

Hey, how is the syntax for the ternary operator to send a variable aktSlot and a key NumpadAdd like that:

Code: Select all

SendEvent (On ? "" : %aktSlot%"{NumpadAdd}")
Thank you
by Nod1234
02 Feb 2023, 10:16
Forum: Ask for Help (v2)
Topic: KeyWait former:ErrorLevel now:?
Replies: 5
Views: 813

Re: KeyWait former:ErrorLevel now:?

Thank you! The response is great, i removed BS, so that it sends now ccr (on double tap) and cccrr (on tripple tab), its not exactly that what i want but it should work in game also. I can live with that!
by Nod1234
02 Feb 2023, 09:42
Forum: Ask for Help (v2)
Topic: KeyWait former:ErrorLevel now:?
Replies: 5
Views: 813

Re: KeyWait former:ErrorLevel now:?

the difference to your 2.0-code is defenitly the response.
by Nod1234
02 Feb 2023, 09:42
Forum: Ask for Help (v2)
Topic: KeyWait former:ErrorLevel now:?
Replies: 5
Views: 813

Re: KeyWait former:ErrorLevel now:?

Thank you for your answer, but i feel a delay when i hit c once quick and i also feel a delay by spamming c if c-key is hold down... May it helps for understanding if i give you the original 1.1 code? cKeyCount := 0 #If (!GetKeyState("LButton", "P")) ;&& editStateOn = False) c:: if (cKeyCount > 0) c...
by Nod1234
02 Feb 2023, 05:15
Forum: Ask for Help (v2)
Topic: KeyWait former:ErrorLevel now:?
Replies: 5
Views: 813

KeyWait former:ErrorLevel now:?

Hey, i'm struggling with the 2.0 syntax espacally with the Error handling from KeyWait: KeyWait "c", "T.5" if KeyWait==0 ;former: ErrorLevel The task of the code should be: press c --> immedatly send c hold c --> normal behaviour of c-button (means: ccccccc, each f.e. 0.5s) double tab c --> send cr ...
by Nod1234
18 Jan 2023, 10:10
Forum: Gaming Help (v1)
Topic: Leftclick in Win10 is not working after Gaming with script
Replies: 5
Views: 395

Re: Leftclick in Win10 is not working after Gaming with script

Implementation right?

Code: Select all

^ESC::
	ExitApp	
	
	OnExit("KeysReset")
	KeysReset()
	{
	Loop, 0xFF ;this will release of all pressed keys
		IF GetKeyState(Key:=Format("VK{:X}",A_Index))
			SendInput, {%Key% up}
	ExitApp
	}
return
by Nod1234
18 Jan 2023, 09:21
Forum: Gaming Help (v1)
Topic: Leftclick in Win10 is not working after Gaming with script
Replies: 5
Views: 395

Re: Leftclick in Win10 is not working after Gaming with script

How can i force AHK to release all modifier keys after f.e. exiting the script?
by Nod1234
18 Jan 2023, 06:53
Forum: Gaming Help (v1)
Topic: Leftclick in Win10 is not working after Gaming with script
Replies: 5
Views: 395

Leftclick in Win10 is not working after Gaming with script

Hey, i have a problem from time to time, after i was using my AHK script in games. If i go back to win10, close the game and stop the AHK script by the command ^ESC::ExitApp Return the left mouse button is not working in win10 anymore/or it's beeing healed after couple of minutes, means i can't clic...
by Nod1234
26 Nov 2022, 09:56
Forum: Gaming Help (v1)
Topic: SendEvent and variable
Replies: 4
Views: 593

Re: SendEvent and variable

:thumbup:
by Nod1234
26 Nov 2022, 08:06
Forum: Gaming Help (v1)
Topic: SendEvent and variable
Replies: 4
Views: 593

Re: SendEvent and variable

Thank you mikeyww,
that works perfect!
One more question: How can i implement:

Code: Select all

% SubStr(variable, 2)
in this routine:

Code: Select all

SendEvent % on ? "%SubStr(variable, 2)" : ""
like that?
by Nod1234
26 Nov 2022, 06:24
Forum: Gaming Help (v1)
Topic: SendEvent and variable
Replies: 4
Views: 593

SendEvent and variable

Hey,
I'm trying to send a variable like this:

Code: Select all

#Persistent
#NoEnv
SendMode Input
SetKeyDelay, 5

a::
variable := A_ThisHotkey
tooltip % variable
SendEvent {%variable%}
Return

^ESC::ExitApp		
Return
But it doesn't work. Has anyone a idea why?
Thanks
by Nod1234
24 Nov 2022, 06:32
Forum: Gaming Help (v1)
Topic: Two buttons and toggling/control them
Replies: 2
Views: 248

Re: Two buttons and toggling/control them

Works perfect! Thank you!
by Nod1234
24 Nov 2022, 05:30
Forum: Gaming Help (v1)
Topic: Two buttons and toggling/control them
Replies: 2
Views: 248

Two buttons and toggling/control them

Hey, I am using two bottons from the mouse which are close to each other and has to be pushed sometimes fast in row... But i realised that i need some delay between the buttons to prevent toggling by pressing them in trouble. XButton1 , should be a kind of "master", if it is pressed&hold, XButton2 s...
by Nod1234
05 Jun 2022, 05:48
Forum: Gaming Help (v1)
Topic: CMD activation and command input
Replies: 2
Views: 345

CMD activation and command input

Hey, i wan't AHK to read out my ping to a special Url for each second. I startet with this, which is working fine: RunWait, %comspec% /c ping %Url% -n 1 | clip,, hide But i don't want to run (&close) cmd each second. Is there a syntax which i can use for e.g. activite the started cmd and put in the ...
by Nod1234
25 Mar 2022, 17:31
Forum: Gaming Help (v1)
Topic: Improving script speed with "SendMode Input" Topic is solved
Replies: 8
Views: 2411

Re: Improving script speed with "SendMode Input" Topic is solved

I found out empirical that "SetKeyDelay, 5" affects SendEvent command for shure, but not the Send command, isn't it? Therefore I was replacing all the Send to SendEvent... I am right?

Go to advanced search