Jump to content

PixelGetColor(x,y) always returns 0


 Share

Recommended Posts

Hi!

I'm trying to write a bot for a game using AutoIt. For that I need to know colors of pixels on screen. However, when I try to use PixelGetColor on the game's window, it always returns 0.

Also Au3Info shows only 0 for the colors on the game's window.

On the other hand, screen capturing programs can grab the contents of the window normally.

Is there a way to make PixelGetColor work?

thx

Edited by grlscz
Link to comment
Share on other sites

  • Moderators

Is the game protetected by anything (gameguard/ntprotect)? (For a non-gamer I sure do know what those are :P ... I spend way too much time on here!!) If they are, you'll need to figure a hack for them before you'll be able to use anything in AutoIt to automate your play.

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

  • Moderators

It is protected, but AutoIt do work. I made some "blind" scripts, and they work. But now I want to read the screen.

No, autoit "do" not work with pixel options if it is protected :P

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

You wrote "before you'll be able to use anything in AutoIt" - therefore my reply.

OK.

So you saying, that there is no way to make PixelGetColor work until gameguard be disabled somehow, did I understand you right?

Edited by grlscz
Link to comment
Share on other sites

  • Moderators

You wrote "before you'll be able to use anything in AutoIt" - therefore my reply.

OK.

So you saying, that there is no way to make PixelGetColor work until gameguard be disabled somehow, did I understand you right?

Yes

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

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...