Hello Everybody,
I hope this is the proper way to do this. I'm new so please bear with me. I'm trying to write a script in autoit for runescape. If anyone is familiar with both or at least has better autoit skills than my noob self please reply. Again sense I don't know if this is the proper way to respond to this thread on this website I'm just going to attach the file and give a brief description of the request. I have a loop that mines coal from the barbarian village and banks it in Edgeville. The specific part I need tweaking on is how the script waits between mining the coal. I have it set up to pixelsearch for the coal, mouseclick the coal, and wait until there is a change using pixelchecksum somewhere in my Backpack. The request is how do I make it so that it does what I previously described plus research for the coal if there is no change in my backpack for a set amount of time. This is needed because sometimes the character takes forever to get the ore and it gets stolen by other players. If and when this happens my player just stands there waiting for the change to happen in my backpack which never does because someone else got the ore first.
Thank you in advance to anyone who can help me solve this.
HotKeySet("!{SPACE}", "TogglePause")
HotKeySet("{ESC}", "exitthescript")
HotKeySet("!a", "CoalRun")
Global $Paused
While (1)
Sleep(Random(1000, 2000, 1))
;remove semi colon to get it to start but beware it starts right away and you have to open the runescape window and be standing at the bank in edgevilleCoalRun()
WEnd
While ($StillMining)
Sleep(Random(1000, 5000, 1))
SearchForCoal()
Wait()
$InvFull = PixelSearch(1315, 596, 1350, 625, 0x2D2D1C, 5)
If Not (@error) Then
$StillMining = False
EndIf
WEnd
LC4(1315, 72)
Med_Sleep()
LC4(1315, 72)
Med_Sleep()
LC4(1262, 133)
Med_Sleep()
$Banker = PixelSearch(480, 230, 964, 638, 0x876B90, 5);Change this to the color of the mob and the search area
If Not (@error) Then
LC2($Banker[0], $Banker[1])
Small_Sleep()
EndIf
LC3(753, 628)
VSmall_Sleep()
EndFunc ;==>CoalRun
Func SearchForCoal()
$Searching = True
While ($Searching)
$Coal = PixelSearch(565, 226, 831, 471, 0x272B28, 1)
If Not (@error) Then
LC($Coal[0], $Coal[1])
$Searching = False
EndIf
WEnd
EndFunc ;==>SearchForCoal
Func Wait()
$Waiting = True
Local $Gotone = PixelChecksum(1165, 377, 1352, 629)
While ($Gotone) = PixelChecksum(1165, 377, 1352, 629)
If Not (@error) Then
$Waiting = False
EndIf
WEnd
EndFunc ;==>Wait
Func TogglePause()
$Paused = Not $Paused
While $Paused
Sleep(100)
ToolTip('Script is "Paused = SCRIPT IS NOT RUNNING = press Space to unpause."', 0, 0)
WEnd
ToolTip("")
EndFunc ;==>TogglePause
Thanks,
I've been watching tutorials and reading the help file for about a week or two now and I just can't understand it well enough to get my code to work. I need someone to hold my hand and walk me through it. Either way thanks.
Er soll einmal TAB drücken und danach die Taste 1 drücken und dann jede Sekunde für 20 Sekunden die Taste 2 drücken. Pause für 30 Sekunden und das selbe von vorne.
Hey zusammen.
Vor einiger Zeit war ich mal im Besitz eines Scripts, welches ich via einen Hotkey (num_1) starten und num_0 stoppen konnte. Es hat 3 Tasten gleichzeitig jede Sekunde gedrückt, bis ich es manuell disabled habe. Diese Tasten waren: "F1", "Space" und "^".
Besteht die Chance, ein solches hier erneut zu bekommen?
Danke im Vorraus!
PS: Würde es so funktionieren:
HotKeySet ( "{num_1}" , "Start" )
HotKeySet("{num_5}", "Pause")
HotKeySet ( "{num_0}" , "Ende" )
I'm looking for a script when I hold down ''e'' I want the script to hold down ''s'' and ''f'' without the keys releasing all the time and when i release ''e'' I want ''s'' and ''f'' to be released at the same time.
I have been working on a script in autoit that will test promo codes for me in an automated web browser.
I have gotten so far as to automating opening the browser (IE) to the check out screen, inputting a set value (ie 125) into the text box and submitting the form.
However, I need to create a loop that will test the set number and test the next numbers in the sequence (ie 125, 126, 127 and so on)
Ideally, I would love if it reported back which ones actually worked based on the error message the browser generates, but that is not necessary at this point and doesnt need a gui at this point either.
U mean when the window / client is minimalized?
If you think like that, then it wont work in AutoIT as far as i know. There is a UDF for it, but the image what you are looking for on the screen, have to be able to see. I ment the window have to be on screen, can not cover it with other window. You can search in a part of the screen with it as well to speed up the process. If you want better imagesearch stuffs, i recomended to use python openCV lib.
for pause ur script i recomended the standerd way insted of (sleep(99999999) in a while loop):
Func _PAUSE()
$paused = Not $paused
While $paused
Sleep(100)
ToolTip('Script is "Paused"', 0, 0)
WEnd
ToolTip("", 0, 0)
EndFunc
If you repress the hotkey for Pause, it will continue running your script where it was paused.
Hello comunity, i hope all are fine.
i need to create a simple Battle bot of this game:
i tried Recorde mause and others Programs but nothing work inside game.
i only need a bot attack, and use potions for hp/mp, i think is easy because the game have an autoSelect tarjet."TAB Buttom" and Number 1,2,3,4,5.. is for Skill. Please help me to do that i will be gratefull.
PD: Look this Tutorial how to do. i tried it but i don't know nothing about Programing lang.
hi i have a request, Im playing a certain game that needs a lot of farming.. i already have a code that finds the monster and kill it but my code is not yet complete. If someone could write me a code that will determine if the monster im killing is still alive and wait until my character kills it before switching to other monster.. I could post my code here if someone will be willing to add some revisions of it.. btw im playing Flyff private server..
#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_UseX64=y
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
#Include <FastFind.au3>
AutoIt Script Requests 07/31/2008 - Dekaron - 10 Replies Meh...bored with my scripts atm (releasing another tomorrow...), so I'm gonna ask you all what you want in a script. Post your ideas here.