Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <ScreenCapture.au3>
- Global $exit = False
- Func Main ()
- HotKeySet("{ESC}", "DoExit")
- HotKeySet("{F3}", "TakeScreenshot")
- While $exit == False
- WEnd
- EndFunc
- Func DoExit ()
- $exit = True
- EndFunc
- Func TakeScreenshot ()
- Send("`go = function (inX, inY) game.player.teleport{x = inX,y = inY}; game.player.clearconsole(); end",1)
- Send("{ENTER}")
- Local $i = 0
- For $y = -700 To 500 Step 97.5
- For $x = -900 To 1500 Step 97.5
- If $exit Then ExitLoop
- Send("`go("&$x&","&$y&")",1)
- ; Get initial checksum
- Local $iCheckSum = PixelChecksum(0, 0, 100, 100)
- Send("{ENTER}")
- Sleep(100)
- ; Wait for the region to change, the region is checked every 100ms to reduce CPU load
- While $iCheckSum = PixelChecksum(0, 0, 100, 100)
- Sleep(100)
- WEnd
- _ScreenCapture_Capture(@MyDocumentsDir & "\Image" & $i & ".jpg", 0, 0, 900, 900)
- $i = $i + 1
- Next
- Next
- EndFunc
- Main()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement