Any way to get opponent input from fighting game?
Any way to get opponent input from fighting game?
Hello my question is if there is any way to get the opponent input in a fighting game. I.E. when they press back key
T.i.a
T.i.a
Re: Any way to get opponent input from fighting game?
I am often proven wrong, but my impression is that AHK cannot infiltrate your game program and determine what input has been received there.
Re: Any way to get opponent input from fighting game?
There could be a way if you identify something that could be a an indicator of "opponent input", such as something that changes on the screen. AHK can identify pixel colors and images. You might want to have a peek at the documentation, in case it generates some ideas.
Re: Any way to get opponent input from fighting game?
Okay thanks. On a separate note in the fighting game it self there's one button say x when I press x once it does one hit but when I press it again it does another hit (like a combo) . Is there a way I can make my script do a combo on one button press but then if I press it another time it stops that combo then if I press it again it starts the combo from first hit?mikeyww wrote: ↑22 May 2022, 10:10There could be a way if you identify something that could be a an indicator of "opponent input", such as something that changes on the screen. AHK can identify pixel colors and images. You might want to have a peek at the documentation, in case it generates some ideas.
Any help is appreciated
Re: Any way to get opponent input from fighting game?
Okay thank you, on a new note. Is there a way for me to like for my script to start a combo sequence like punch1 punch2 punch3 on d button press But when i press d second time it stops it completely but then when I pr3ss third time it starts again with punch 1mikeyww wrote: ↑22 May 2022, 10:10There could be a way if you identify something that could be a an indicator of "opponent input", such as something that changes on the screen. AHK can identify pixel colors and images. You might want to have a peek at the documentation, in case it generates some ideas.
Pls any help is appreciated greatly
Re: Any way to get opponent input from fighting game?
Code: Select all
d::SetTimer, d Up, % (punch := !punch) ? 50 : "Off"
d Up::SendInput % punch ? "punch1punch2punch3" : ""
Re: Any way to get opponent input from fighting game?
Punch is just a variable correct? Punch1punch2punch3 are the button inputs correct? So will it work like this?mikeyww wrote: ↑22 May 2022, 12:25Code: Select all
d::SetTimer, d Up, % (punch := !punch) ? 50 : "Off" d Up::SendInput % punch ? "punch1punch2punch3" : ""
d::SetTimer, d Up, % (punch := !punch) ? 50 : "Off"
d Up::SendInput % punch ? "Send {s down}{u down}, {s up}{u up},{d down}{d up}" : ""
Is that how it will work?
Re: Any way to get opponent input from fighting game?
Yes. Try:
Code: Select all
d::SetTimer, d Up, % (punch := !punch) ? 50 : "Off"
d Up::Send % punch ? "{s down}u{s up}d" : ""
Re: Any way to get opponent input from fighting game?
so in notepad its working, but in the game its not doing anythingmikeyww wrote: ↑22 May 2022, 12:37Yes. Try:
Code: Select all
d::SetTimer, d Up, % (punch := !punch) ? 50 : "Off" d Up::Send % punch ? "{s down}u{s up}d" : ""
what im using
Code: Select all
z::SetTimer, z Up, % (punch := !punch) ? 50 : "Off"
z Up::Send % punch ? "{s down}u{s up}d" : ""
Re: Any way to get opponent input from fighting game?
I even tried to put sleep ::cyrexsef wrote: ↑22 May 2022, 19:11so in notepad its working, but in the game its not doing anythingmikeyww wrote: ↑22 May 2022, 12:37Yes. Try:
Code: Select all
d::SetTimer, d Up, % (punch := !punch) ? 50 : "Off" d Up::Send % punch ? "{s down}u{s up}d" : ""
what im using
not sure whyCode: Select all
z::SetTimer, z Up, % (punch := !punch) ? 50 : "Off" z Up::Send % punch ? "{s down}u{s up}d" : ""
JOY5::SetTimer, JOY5 Up, % (punch := !punch) ? 50 : "Off"
JOY5 Up::Send % punch ? "send, {s down}, sleep 50, send {s up}" : ""
Re: Any way to get opponent input from fighting game?
Try running as admin. Also see notes here about key delays & other factors. viewtopic.php?f=7&t=11084
There are no guarantees!
Code: Select all
If !A_IsAdmin && !(DllCall("GetCommandLine", "str") ~= " /restart(?!\S)") {
Try Run *RunAs "%A_AhkPath%" /restart "%A_ScriptFullPath%"
ExitApp
}
d::SetTimer, d Up, % (punch := !punch) ? 50 : "Off"
d Up::
SetKeyDelay,, 25
Send % punch ? "{s down}u{s up}d" : ""
Return
Re: Any way to get opponent input from fighting game?
can you please explain what the extra u d in Send % punch ? "{s down}u{s up}d" : ""mikeyww wrote: ↑22 May 2022, 19:29Try running as admin. Also see notes here about key delays & other factors. viewtopic.php?f=7&t=11084
There are no guarantees!Code: Select all
If !A_IsAdmin && !(DllCall("GetCommandLine", "str") ~= " /restart(?!\S)") { Try Run *RunAs "%A_AhkPath%" /restart "%A_ScriptFullPath%" ExitApp } d::SetTimer, d Up, % (punch := !punch) ? 50 : "Off" d Up:: SetKeyDelay,, 25 Send % punch ? "{s down}u{s up}d" : "" Return
is for?
Re: Any way to get opponent input from fighting game?
It isn't extra. d is (nearly or sometimes) the same as{d down}{d up}.