Jump to content
Sign in to follow this  
jmoney

autoit script with full screen application

Recommended Posts

jmoney

Hi guys,

I wrote a small script but I cannot seem to get it to work if the program is running in full screen mode. What would I need to change to accomplish this?

TIA

#include <misc.au3>  
Global $Paused
HotKeySet("{PGDN}", "TogglePause")

While 1
    Sleep(50)
    $var = PixelGetColor( 763, 1009 )
    If $var = 0xA17F55 And NOT _IsPressed(10) And NOT _IsPressed(12) Then Send("{2}")
    If $var = 0x8A7944 And NOT _IsPressed(10) And NOT _IsPressed(12) Then Send("{9}")
    If $var = 0x190000 And NOT _IsPressed(10) And NOT _IsPressed(12) Then Send("{d}") 
    If $var = 0x080400 And NOT _IsPressed(10) And NOT _IsPressed(12) Then Send("{5}")
    If $var = 0xAE2502 And NOT _IsPressed(10) And NOT _IsPressed(12) Then Send("{0}") 
    If $var = 0xA21718 And NOT _IsPressed(10) And NOT _IsPressed(12) Then Send("{a}") 
    If $var = 0xECA69A And NOT _IsPressed(10) And NOT _IsPressed(12) Then Send("{3}") 
    If $var = 0xA121A0 And NOT _IsPressed(10) And NOT _IsPressed(12) Then Send("{F3}")
    If $var = 0x110806 And NOT _IsPressed(10) And NOT _IsPressed(12) Then Send("{4}") 
    If $var = 0x2E6C64 And NOT _IsPressed(10) And NOT _IsPressed(12) Then Send("{7}") 
WEnd

Func TogglePause()
    $Paused = NOT $Paused
    While $Paused
        sleep(100)
        ToolTip('P',900,500)
    WEnd
    ToolTip("")
EndFunc

Share this post


Link to post
Share on other sites
jmoney

the script works fine if i run the application in window mode maximized, forgot to add that.

Share this post


Link to post
Share on other sites
AdmiralAlkex

Most fullscreen apps force themselves to the front, so you simply have to make it without fullscreen.

I mean, sure you could do it by hooking whatever it renders with (direct3d, opengl?), but good luck with that. No one has done that so far on this forum.

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
Sign in to follow this  

×