Stoney Posted March 30, 2009 Posted March 30, 2009 (edited) Hi there, I've been trying to make a script that uses blockinput() for about 5 seconds every minute. What I want to know, is if there is a way to record what the user has tried to press, then send it afterwards? I have tried using the _IsPressed, but it only seems to be active for a spit second. Any Ideas? Edited March 30, 2009 by Stoney
PsaltyDS Posted March 30, 2009 Posted March 30, 2009 Hi there, I've been trying to make a script that uses blockinput() for about 5 seconds every minute. What I want to know, is if there is a way to record what the user has tried to press, then send it afterwards? I have tried using the _IsPressed, but it only seems to be active for a spit second. Any Ideas?Key loggers are not an acceptable topic on this forum, especially when combined with probably malicious behavior like this. Take it up somewhere else. Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
Yashied Posted March 30, 2009 Posted March 30, 2009 Hi there, I've been trying to make a script that uses blockinput() for about 5 seconds every minute. What I want to know, is if there is a way to record what the user has tried to press, then send it afterwards? I have tried using the _IsPressed, but it only seems to be active for a spit second. Any Ideas?No ideas! My UDFs: iKey | FTP Uploader | Battery Checker | Boot Manager | Font Viewer | UDF Keyword Manager | Run Dialog Replacement | USBProtect | 3D Axis | Calculator | Sleep | iSwitcher | TM | NetHelper | File Types Manager | Control Viewer | SynFolders | DLL Helper Animated Tray Icons UDF Library | Hotkeys UDF Library | Hotkeys Input Control UDF Library | Caret Shape UDF Library | Context Help UDF Library | Most Recently Used List UDF Library | Icons UDF Library | FTP UDF Library | Script Communications UDF Library | Color Chooser UDF Library | Color Picker Control UDF Library | IPHelper (Vista/7) UDF Library | WinAPI Extended UDF Library | WinAPIVhd UDF Library | Icon Chooser UDF Library | Copy UDF Library | Restart UDF Library | Event Log UDF Library | NotifyBox UDF Library | Pop-up Windows UDF Library | TVExplorer UDF Library | GuiHotKey UDF Library | GuiSysLink UDF Library | Package UDF Library | Skin UDF Library | AITray UDF Library | RDC UDF Library Appropriate path | Button text color | Gaussian random numbers | Header's styles (Vista/7) | ICON resource enumeration | Menu & INI | Tabbed string size | Tab's skin | Pop-up circular menu | Progress Bar without animation (Vista/7) | Registry export | Registry path jumping | Unique hardware ID | Windows alignment More...
Stoney Posted March 30, 2009 Author Posted March 30, 2009 It's not a key logger. I'm using it to send keys to a game while in a different application, controlsend won't work. Because of this I'm using WinActive/WinActivate to swtich to it, send the keys, then send back. However, I need to block the input while it does that or the prosess might mess up. This is why I wanted to (for lack of a better word) buffer the keys being sent. Don't know if this will change your mind, but here is the code. expandcollapse popupglobal $tab global $title global $mouse opt("SendKeyDelay", 30) opt("MouseClickDownDelay", 30) func SendMin($key) BlockInput(1) If WinActive("Testwindow.txt - Notepad") = 1 Then $tab = 0 Else $title = WinGetTitle("[active]") $mouse = MouseGetPos() BlockInput(1) WinActivate("Testwindow.txt - Notepad") $tab = 1 EndIf sleep(10) send($key) sleep(10) if $tab = 1 then WinActivate($title) MouseMove($mouse[0], $mouse[1], 0) EndIf BlockInput(0) sleep(10) EndFunc sleep(5000) while 1=1 $temp = MsgBox(3,"Repeater","How many loops until next alert? Yes=3, No=2, Cancel=1") Select Case $temp=6 $alert=3 Case $temp=7 $alert=2 Case $temp=2 $alert=1 Case Else $alert=1 EndSelect For $loop = 0 to $alert for $action = 1 to 45 TrayTip("Repearter","Action #" & $action, 5) SendMin("\") sleep(11000) Next SendMin("r") Sleep(2500) SendMin("^!0") sleep(1000) SendMin("\") sleep(115000) SendMin("s") sleep(3500) SendMin("r") sleep(2500) SendMin("{DOWN 45}") sleep(1000) Next Wend
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now