andrew01 Posted September 14, 2006 Share Posted September 14, 2006 Ok, I was the "UP" key to be held down for a certain amount time, in this case 30 seconds. At the moment, I have this: Opt("SendKeyDownDelay", 30000) Send( "{UP}") But when I do that, it also has to wait 30 seconds before holding down the key, so that command really takes 60 seconds in total. Are there any other commands that are instant? Link to comment Share on other sites More sharing options...
Paulie Posted September 14, 2006 Share Posted September 14, 2006 Ok, I was the "UP" key to be held down for a certain amount time, in this case 30 seconds. At the moment, I have this: Opt("SendKeyDownDelay", 30000) Send( "{UP}") But when I do that, it also has to wait 30 seconds before holding down the key, so that command really takes 60 seconds in total. Are there any other commands that are instant?Send( "{UP down}") Sleep(30000) Send( "{UP Up}") Link to comment Share on other sites More sharing options...
jpm Posted September 15, 2006 Share Posted September 15, 2006 Ok, I was the "UP" key to be held down for a certain amount time, in this case 30 seconds. At the moment, I have this: Opt("SendKeyDownDelay", 30000) Send( "{UP}") oÝ÷ ا!Ú-«bµ©l¢¬¶Ýô±ç(Ûyú+z%v)àv'¶¤{+(¶r¦jwky©eÊÖ¤zδ±ç(Û"Ú-jP+zØ^æ§Êaz·(f§vËajÖ«z)쵩íþ«¨µâ¢}ý¶ÇÊ«rÜz¹Ú²Ø^~e£§Ç+]Êek+a{},yÊ'vÆ®¶sd÷BgV÷Cµ6VæD¶WF÷väFVÆgV÷C²Â3¢b33c·7F'CÕFÖW$æB¢6VæBgV÷C·µUÒgV÷C²¦×6v&÷ÂgV÷C´VÆ6RFÖRgV÷C²ÂFÖW$Ffbb33c·7F'B Link to comment Share on other sites More sharing options...
andrew01 Posted September 15, 2006 Author Share Posted September 15, 2006 (edited) That's really weird....I just ran that script that you posted and the time came up as 60 seconds. Could it be something wrong with my computer? edit:spelling edit2: Paulie, I just tested out using Sleep() and it worked great. Thank you. Edited September 15, 2006 by andrew01 Link to comment Share on other sites More sharing options...
MHz Posted September 15, 2006 Share Posted September 15, 2006 ---------------------------Elapse time---------------------------30006.4434463035---------------------------OK ---------------------------JPM's code approx. 30 seconds as tested on XP Pro SP2. Link to comment Share on other sites More sharing options...
andrew01 Posted September 15, 2006 Author Share Posted September 15, 2006 This is what comes up for me Link to comment Share on other sites More sharing options...
jpm Posted September 15, 2006 Share Posted September 15, 2006 This is what comes up for me Which keyboard are you using? Link to comment Share on other sites More sharing options...
andrew01 Posted September 16, 2006 Author Share Posted September 16, 2006 Logitech G15 Link to comment Share on other sites More sharing options...
jpm Posted September 16, 2006 Share Posted September 16, 2006 Logitech G15Sorry, I mean the keyboard language as installed under windows?The logical not the physical name.Thanks for the cooperation Link to comment Share on other sites More sharing options...
andrew01 Posted September 16, 2006 Author Share Posted September 16, 2006 I am not really sure what you are asking for. Could you explain it a little better or how I can find the answer out on my computer? Thank you. Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted September 16, 2006 Moderators Share Posted September 16, 2006 (edited) I am not really sure what you are asking for. Could you explain it a little better or how I can find the answer out on my computer? Thank you.Newest Beta... Run this.. and post the results here for jpm: MsgBox(64, 'Key Board Layout', @KBLayout) ClipPut(@KBLayout);Now you can paste it here Edited September 16, 2006 by SmOke_N 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 More sharing options...
andrew01 Posted September 17, 2006 Author Share Posted September 17, 2006 OK the number I got is: 00000409 Now im starting to think my timers are messed up, because alot of other operations seem to be off too (in autoit). Link to comment Share on other sites More sharing options...
andrew01 Posted September 17, 2006 Author Share Posted September 17, 2006 (edited) Sorry for the double post but: Is there anyway to change this to the default (if this is wrong, but I really think it is). For example, if I give the command: Send( "{RIGHT Down}") Sleep(500) Send( "{RIGHT Up}") It used to be a 90 degree turn to the right for me (in a game), but lately, if I give that command, it spins around for a long time, like its holding down the right arrow key. EDIT: Ok I just looked into the beta help file to find out what @kblayout actually did, and I saw that my keyboard layout is correct (English, United States) but that still doesnt explain why my script is messing up so much, or why Opt(SetKeyDelayDown) lags, alot more then yours. Problems I am having: 1. Opt(SetKeyDownDelay) waits for the amount of time put in the parameter before pressing the key (ie if I put 30000 in the parameter it would wait for 30 secs and then push down) 2. Similar to what I quoted above, if I tell the left, right, a, d key to move in the script, wanting it to turn in game, my charater just goes in circles forever, like the key is stuck. EDIT 2: Possible Cause?!?! I have an adlibfunction running, that executes every 2 seconds. I thought that the entire script paused for a brief moment while it did its thing? Maybe it could be pausing right at the Send("{RIGHT Down}") key is being pressed... Edited September 17, 2006 by andrew01 Link to comment Share on other sites More sharing options...
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