Log in

View Full Version : Looking for a program that will...



mikedoggy
12-19-2007, 09:22 PM
i tried searching for this but just not that good at it and not really sure how to search for it.

im looking for a program that will allow a minimized or background program to recieve input when it has code that checks to make sure it is focused before it allows input.

more detail: daoc wont allow input unless it is the focused application. im told it has multiple checks in the game.dll that checks before allowing. you can hack the game.dll and set all these checks to true. but every patch id have to do the same thing and id have to figure a way to make it not patch each time i play, which shouldnt be hard but just one more thing to do.

ideally i could have a program that would trick all my daoc clients into thinking they were focused, when they werent.

even if this is something you are unfamiliar with if you have any ideas on a way or where to search for it id appreciate any help i could get.

thanks.

thinus
12-19-2007, 11:26 PM
Hi,

Don't know if it is feasible to do but here are some keywords all dealing with focus:
SetCapture
WM_SETFOCUS
WM_KILLFOCUS
WM_ACTIVATE

Running multiple checks everytime it recieves keyboard input seems like it would incur a performance overhead assuming all checks involve API calls. Although, I am not familiar with DirectInput, might do things slightly differently.

Anyway, preventing an application from knowing whether it has focus or not could be problematic. If the window actually sets the caret position on key presses you could end up with pretty wierd behaviour.

Might be easier if your key cloning software actually activated the window before sending the keys but then it will probably have to implement some kind of buffer to queue keystrokes while it is busy swapping between windows to send keys.

mikedoggy
12-20-2007, 03:46 AM
thanks for the key words. ill try searching those tommorrow.

im not sure what you mean on setting caret postion on key presses.

as for the software actuallya ctivating i dont think that would work. daoc my damage casters cast about ocne per second so thatd be way too much switching back andforward, would kill my cast speed.

thinus
12-20-2007, 06:47 PM
thanks for the key words. ill try searching those tommorrow.

im not sure what you mean on setting caret postion on key presses.

as for the software actuallya ctivating i dont think that would work. daoc my damage casters cast about ocne per second so thatd be way too much switching back andforward, would kill my cast speed.

From MS:



Because only one window at a time can have the keyboard focus or be active, there is only one caret in the system. Generally, each window that accepts keyboard input must create the caret when it receives the keyboard focus and destroy the caret when it loses the keyboard focus.

Not sure if it would cause a problem or not.

Another plan of attack could be virtual desktops, not sure how MS implemented virtual desktops and whether it bothers to tell the applications in it when it is hidden, unfocused etc.

Thing with Virtual Desktops though is it might break your key cloning software. I think there is a setting to control whether you can hook into an application inside a virtual desktop from outside the desktop that is specified when the desktop is created.

mikedoggy
12-20-2007, 09:37 PM
looks like ms solution to virtual desktop isnt that great, but thats just from a quick wiki search. they did mention other shells allow for more functionality.

thanks for the info so far. looks like there wont be an easy solution.

mikedoggy
12-28-2007, 02:51 PM
the full version of wineq2 works for this somewhat. possibly all.

in conjunction with octopus im getting single keys to pass but not input like ctrl+1. just the 1 will pass.

this is good enough for me as most my ctrl+ or alt+ keys are for buffing and i found a nice program called hotkeynet.com that allows macros across a network with commands that will switch windows.