Jump to content

Recommended Posts

Posted

Ive tried Playing with SDL.dll and don't think it will work for what you want, its more for creating an environment and then manipulating the mouse within THAT environment, as opposed to handling the mouse in an environment that has already been created. ... .. . or thats my take on it anyways.

There is always a butthead in the crowd, no matter how hard one tries to keep them out.......Volly

Posted (edited)

Here, try making your game windowed, then make a script that simply moves the mouse across the screen 20 pixels at a time, and see if it moves across the game window good, if it DOESNT, then it could simply be game protection, probably something in the game the makes it only take actual interaction,

if it DOES, then either:

a ) the bot isin't finding the right pixel color

b ) the bot isint finding ANY color, because of game protection... for example, games protected by GB have "no" pixel color, its all black.

I don't know if it wil help your cause but for some other games I used to bot for, I made a bot that took screen shots, found the color on THAT , and simply found where that pixel would be in relation to your screen

Edited by MethodZero

[center]"When you look at old, classic games like Snake, you often put it off because it's such a simple game, but it's only when you actually try and create your own unique game from scratch, do you finally appreciate those games."[/center][center]Don't ask for answers if you haven't TRIED yet![/center][center]Most answers can be answered in the help file! Use it![/center]

Posted

ok so ive tested it.

the game has a seperat mouse -.-"

when the normal windows mouse moves over the game window, the gamemouse stays at the same position and the windows mouse is over the game window.

this just passes when the game is in the background.

when the game is in the foreground nothing happens.

could it be that the game disabes the windows mouse when it is in the foreground and the games mouse is the now active mouse?

Posted

*bump*

Thou Shalt NOT Bump so fast.........

Your post may not be on the first page any more, but the "Wise Ones" DO indeed read posts back several pages

Everseeker

Posted

but the "Wise Ones" DO indeed read posts back several pages

Hmm... never knew that..

ANYWAY, That might help, I'm not sure what Direct Input does thought, However, check 1 more thing, Open PAINT and open the window AND the canvas as big as you can get it, then colour it green or something, a solid color, then Open AutoIt Window Info, and place the mouseover the windowed GAME, does the AutoIt Window Info thing change when your on different colors? or does it just read the color you put in paint? If it reads what's in paint, then I don't think you can bot this game, because its not reading the game's colors

[center]"When you look at old, classic games like Snake, you often put it off because it's such a simple game, but it's only when you actually try and create your own unique game from scratch, do you finally appreciate those games."[/center][center]Don't ask for answers if you haven't TRIED yet![/center][center]Most answers can be answered in the help file! Use it![/center]

Posted

If it reads what's in paint, then I don't think you can bot this game, because its not reading the game's colors

I tested this part, it is reading pixelcolors just fine. the1venom is right, it has to do with the way DirectInput rePositions the mouse to the Center and then just reads the input directly. I have been successfull in botting games like this by useing the "user32.dll" mouse_event in relative Mode, that way the mouse trys to move "from" its current position.

There is always a butthead in the crowd, no matter how hard one tries to keep them out.......Volly

Posted

firstly thanks for answering :)

I tested this part, it is reading pixelcolors just fine. the1venom is right, it has to do with the way DirectInput rePositions the mouse to the Center and then just reads the input directly. I have been successfull in botting games like this by useing the "user32.dll" mouse_event in relative Mode, that way the mouse trys to move "from" its current position.

ofLight can you explain it more?

how can i use mouse_event in relative mode?

Posted (edited)

depending on the setting of MOUSEEVENTF_ABSOLUTE. Absolute data is specified as the mouse's actual x-coordinate; relative data is specified as the amount that a mouse has to move for it to report that it has moved.

This is from MSDN Website

I think someone actually made a UDF for this awile back that might make it easyer than calling the DLL yourself.

EDIT: Ya, i found it, look up MouseMovePlus, I havent actually used his code but it looks like what you want.

Edited by ofLight

There is always a butthead in the crowd, no matter how hard one tries to keep them out.......Volly

  • 2 weeks later...
Posted (edited)

I think I can solve this right-away.

Either

a ) compile the script and run it as an administrator

b ) add the line #requireadmin at the top of your script.

Vista does not like mouse movements without the authority to do so, I created a GUI that sent mouse movements, but it would only send them while the GUI was activated. Worked fine for me.

Let me know how you got on.

David

Edited by civilcalc

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