Jump to content

Read from a maximized window?


Recommended Posts

Edit: Figured IT out, TY GUYS! REALLY APPRECIATE IT!

Well i'm trying to get autoit to read from a window that it maximized on the screen and uses direct X.

I was simply using PixelGetColor(X,Y) at the required X and Y values for me, but the problem I noticed, was that it just kept reading straight through the game that was open and went to the main desktop//any windows open on screen while game was minimized.

Any way to get it to read from the game itself?

Edited by jpres
Link to comment
Share on other sites

Func GetColor()
    While WinActive ("World of Warcraft")
$color = PixelGetColor(260,80)
WEnd
    sleep(100)
    MsgBox(0,"Color","The hex color is" & $color)
EndFunc

That's what i'm using to try any get it, but I don't think it's working.

Link to comment
Share on other sites

Func GetColor()
    While WinActive ("World of Warcraft")
$color = PixelGetColor(260,80)
WEnd
    sleep(100)
    MsgBox(0,"Color","The hex color is" & $color)
EndFunc

That's what i'm using to try any get it, but I don't think it's working.

You have created a function but you have never actually called it. Above everything you need to call GetColor().

GetColor()

Func GetColor()
    While WinActive ("World of Warcraft")
        $color = PixelGetColor(260,80)
    WEnd
    sleep(100)
    MsgBox(0,"Color","The hex color is" & $color)
EndFunc
Other People's Stuff:Andy Flesner's AutoIt v3: Your Quick Guide[topic="34302"]Locodarwin's ExcelCom_UDF[/topic][topic="61090"]MrCreatorR's Opera Library[/topic]
Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...