Jump to content

Popeye1

Active Members
  • Posts

    29
  • Joined

  • Last visited

Popeye1's Achievements

Seeker

Seeker (1/7)

0

Reputation

  1. While 1 ;start master loop MouseClick("left") Sleep(1000) WEnd ; end master loop This is the test script i'm using because weird things are happening in my main script, such as clicks not going through sometimes. The click is just clicking a game client window and is supposed to select a new location every 1 second, wherever the mouse cursor is pointed at. The strange problem here is that it only clicks about once every 3-5 seconds, instead of once a second. Can anyone think of a reason as to why every click isn't being registered? I'm pretty sure this is not some kind of anti-macro thing related to this game because i've never came across such a problem in any game i've played.
  2. HotKeySet("{PAUSE}", "EndScript") HotKeySet("{END}", "SetPause0") ; [x] variabile [x] ; CHANGES --------------------------------------------- Options Opt("PixelCoordMode", 0) ; pixelsearch function relative to active window not the whole screen! ; ------------- end Opt() While 1 ;start master loop MouseClick("left") Sleep(7000) WEnd ; end master loop This is all the script is, the first section is irrevelant because it's not used in this script but I have it there anyway, for some reason this does nothing when ran.
  3. I'm trying to run a simple mouseclick script in a game window I have but nothing happens. The machine is windows 7 64 bit. The script works fine on my other non windows 7 machines. Does anyone know what the problem is?
  4. Thanks but i found the issue, the endif for bugcheck was incorrectly placed.
  5. $bugcheck = 0 While 1 $mdone = PixelSearch (8, 752, 31, 768, 0xFFE345, 10 ) If UBound($mdone)>1 Then $pausetime = 3 $pausename = " Waiting " PauseTime() ToolTip("") ExitLoop Else While 1 $mdone = PixelSearch (8, 752, 31, 768, 0xFFE345, 10 ) If UBound($mdone)>1 Then $pausetime = 3 $pausename = " Waiting " PauseTime() ToolTip("") ExitLoop Else $bugcheck +=1 If $bugcheck >=6 Then ToolTip(" became bugged ", 400, 3) Sleep(100) Alarm1() $pausetime = 23 $pausename = " Waiting longer "&$bugcheck PauseTime() ToolTip("") MouseClick("right", 115, 105 ) ; clicking again Sleep(500) MouseClick("left", 154, 145 ) ; Sleep(500) EndIf EndIf WEnd EndIf WEnd $bugcheck = 0 What the script is supposed to do is play the last part of the script, where it waits 23 seconds, up to 6 times, if it's stuck in this loop 6 times over then bugcheck becomes greater than 6 and function alarm1 begins. If the script doesn't get stuck in the loop it's supposed to set bugcheck back to 0. From what i've seen the script does everything the way I want it to, except even when it doesn't get stuck in the loop the alarm function is activated anyway? What am I doing wrong?
  6. I'm using a tooltip instead of a messagebox ToolTip(" check xxx", 400, 3) Can this be used to display the number %count is at?
  7. Great, that works, thanks. Can I use the message box to display what number $count is currently at?
  8. I'm looking to solve an issue in my script, but am not sure where to even look. The script checks an if statement using pixelsearch, if for example 0x000000 is found, then the script needs to store that information and add +1. The script would then continue on and eventually start at the beginning of the master while loop again, and come back round to this pixelsearch if statement and if the colour is still 0x000000 then it needs to add another +1, so if the original value was 0, it would now be 2, and every time the script repeats this cycle and finds 0x000000, it would add another +1. A different section in the script would be checking to see if this number has became 30 or greater (for example) and executing some code if so, aswell as resetting the number back to 0 again. I don't even know where to look in the help file for this, can anyone help?
  9. Is there something under help about how to play a sound file?
  10. Nobody knows this one?
  11. I started using a script that normally works fine on a xp or vista machine, now on a windows 7 pc and the beep doesn't make any sound. Tried it on another windows 7 pc, same thing, does anyone know if it's not possible or how to make it work on win 7? The beep sound is an extremely important part of my script and to be unable to use it on updated machines is a bit poor.
  12. Is there a way to get the version that doesn't load frozen? I hate having to set up window info every time I load it,
  13. OK I found it, it makes no diff, it still loads frozen and from the original start settings every time.
  14. Where is the 64x located? It's not in the autoit folder.
  15. If UBound($ucheck)>1 Then ToolTip(" blah blah ", 400, 3) Sleep(1000) ExitLoop Else ToolTip(" blah blah ", 400, 3) $coord = PixelSearch( 783, 175, 1003, 611, 0x733C9E, 10 ) If Not @error Then ; pixel found - do ur thing ;MsgBox(0, "X and Y are:", $coord[0] & "," & $coord[1]) MouseClick("right", $coord[0] , $coord[1]) Sleep(1000) MouseClick("left", $coord[0] , $coord[1] +23) Sleep(1000) MouseClick("right", $coord[0] , $coord[1]) Sleep(1000) MouseMove("right", $coord[0] , $coord[1] +100) ; <-- problem is here, this worked as MouseClick but stopped working as MouseMove Sleep(1000) MouseClick("right", $coord[0] -100 , $coord[1] +100) EndIf Sleep(300) EndIf I have a problem with this code, it all worked fine until I changed MouseMove("right", $coord[0] , $coord[1] +100). This used to be a MouseClick, but I don't want it to click, I just want it to move the mouse there. My issue is the mouse is not moved to the correct position when using the mousemove function, instead it just moves to the botton left of the screen, every time. I tried adding MouseCoordMode 0 and that didn't fix the problem either. Can someone help?
×
×
  • Create New...