Jump to content
Qvartz

New to autoit and Im having problems getting _IsPressed function to work

Recommended Posts

Hello, can someone help me with _IsPressed function? I made simple script that tells me if steam is running, but I want that to happen only when I hold down shift, how can I do that?

#include <MsgBoxConstants.au3>

while 1
    sleep(100)
    If ProcessExists("Steam.exe") Then
        MsgBox($MB_SYSTEMMODAL, "", "Steam is currently running")
        sleep(1000)
    EndIf
WEnd

 

Share this post


Link to post
Share on other sites
#include <MsgBoxConstants.au3>
#include <misc.au3>

While Sleep(100)
    If ProcessExists("Steam.exe") Then
        If _IsPressed("10") Then
            MsgBox($MB_SYSTEMMODAL, "", "Steam is currently running", 1)
        EndIf
    EndIf
WEnd

 


UDF: _SingleScript()                                        If you like my post, just click the like button :)        here -->

Share this post


Link to post
Share on other sites
7 hours ago, Nine said:

@Qvartz Maybe you should read about forum rules above, especially game automation...

Is steam counted as game? And yes I did read rules.

Share this post


Link to post
Share on other sites
7 hours ago, Nine said:

@Qvartz Maybe you should read about forum rules above, especially game automation...

Also as I mentioned Im new to autoit and its just my script Im learning from, basically 2 example scripts from site put together.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...