|
-
Dec 6th, 2004, 07:46 PM
#1
SendKeys using DirectX's DirectInput
Since DirectInput works at the lowest level and obtains input directly from the keyboard, is it possible to invoke a SendKeys type function? It seems as though it would be possible. If not, what can do a better job than SendKeys, the SendInput API, and the Keyb_Event API?
If you don't know what SendKeys is, it mimics keyboard presses without the user having to touch the keyboard.
Note: I'm helping XeonTeam get his Active Shiver bot going so his program can automatically control the controls to another game, which will make himself strafe left and right repeatedly at a certain interval so bullets can miss him. I think the game he wants this done on is CC Renegade or something like that. Not sure if the game runs on DirectX though.
-
Dec 7th, 2004, 05:33 PM
#2
PowerPoster
Re: SendKeys using DirectX's DirectInput
Well that doesn't leave you with to much to work with.
Before you can start sending keys to the game you must first find out what type of level the game recieves its input on.
I highly down CC Renegade is using a WM_COMMAND WM_KEYDOWN system to manage its input. So that should rule out SendKeys because SendKeys is an API so it communicates directly with Windows which when sending a key it sending WM_COMMAND WM_KEYDOWN followed by a param containing which key was pressed.
This is my theory tho, I could be wrong and SendKeys could be on the lowest-level. I doubt it tho, so if I was you I'd research how DirectInput is recieving its input on the lowest level. Maybe it subclass's the keyboard device. If that is possible then it would be easy to write a program to do the same and send keys.
"From what was there, and was meant to be, but not of that was faded away." - - Steve Damm
"The polar opposite of nothingness is existance. When existance calls apon nothingness it shall return to nothingness." - - Steve Damm
"When you do things right, people won't be sure if you did anything at all." - - God from Futurama
-
Dec 7th, 2004, 10:46 PM
#3
Re: SendKeys using DirectX's DirectInput
The game uses DirectInput. I heard that some people got keybd_event to work anyways, but it doesn't work on CC Renegade, or any DirectInput based program for that matter, even when their window is active. Only Notepad, Calculator, and other non DirectX apps right now.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|