|
You last visited: Today at 13:05
Advertisement
Bot For Excavation QTE
Discussion on Bot For Excavation QTE within the Lost Ark forum part of the Popular Games category.
03/02/2022, 04:02
|
#1
|
elite*gold: 0
Join Date: Nov 2021
Posts: 4
Received Thanks: 4
|
Bot For Excavation QTE
Hello i'm looking for someone who could make a bot for the QTE from the excavation lvl 20, this look like this
Thanks a lot !
|
|
|
03/03/2022, 00:19
|
#2
|
elite*gold: 0
Join Date: Nov 2011
Posts: 72
Received Thanks: 51
|
Make one yourself. It's not hard.
|
|
|
03/03/2022, 16:40
|
#3
|
elite*gold: 0
Join Date: Nov 2021
Posts: 4
Received Thanks: 4
|
Mh i tried but i'm stuck on something, i have an issue with comparing array, i don't find how to get the "x" position of each array, i don't see better solution than, finding the blue pixel on the bar (cause they are random for each mini game) and finding the pixel of the arrow, and when thos pixel are aligned, press space... That's what i got for now (it don't work of course)
Code:
HotKeySet("²", "space")
HotKeySet("{ESC}","KillSwitch")
while 1
Sleep(50)
Wend
Func space()
while 1
$PIX = PixelSearch(793, 672, 1120, 692, 0x2DA6C7,0)
$ARROW = PixelSearch(794, 690, 1119, 705, 0xE99800,0)
if $PIX[0] == $ARROW[0] Then
Send("{SPACE}")
EndIf
WEnd
EndFunc
Func KillSwitch()
Exit
EndFunc
PS : It's the first time i code something and that's already huge for me x)
|
|
|
03/04/2022, 11:55
|
#4
|
elite*gold: 100
Join Date: Mar 2006
Posts: 1,819
Received Thanks: 425
|
Hmm.
Try Image Search, since those blue things changes location but Im assuming that the image is almost always the same except when they change their widths?
If yes, you can crop an image of the blue like so:
Middle of Blue Bar ^
And look for that image.
Likewise, you can also crop an image of the arrow like so:
Middle of arrow ^
Then look for the arrow image.
How it works is that, the calculation always reports/displays the first coordinate X/Y of where the "BLUE" appeared as first searched.
Then likewise, when you search for the "Arrow" it will also report/display the coordinates from which it appeared first.
If Blue appears in X:100 Y:200 and Arrow Appears in X:100 Y:300 this means that the arrow is in the same Y axis of blue but 100 pixels further below it.
Im bad at explaining I hope you understand that. Im not entirely sure about the calculations but this is what I will do.
What you will do next is compare the X of BLUE and X of Arrow.
Pseudo code:
If Blue.x = Arrow.x then
press Space (or whatever key)
end if
or if you want to press a key before Arrow Aligns where BLUE is:
If Blue.x = Arrow.x - 500
press Space
end if
This will trigger SPACE BAR when Arrow is found 500 pixels before blue.
Now, assuming Arrow is a moving object.
So you'll have to search for it first.
Then add a timer how long you'll wait to press SPACE before it Aligns with Blue.
The timer acts as your delay.
Now, there's no guarantee this will be accurate and will always yield 100% result.
|
|
|
03/04/2022, 17:11
|
#5
|
elite*gold: 0
Join Date: Nov 2021
Posts: 4
Received Thanks: 4
|
That's what i got so far, seems to work, most of the time if you guys want to use it..
Code:
HotKeySet("²", "espace")
HotKeySet("{ESC}","KillSwitch")
while 1
Sleep(50)
Wend
Func espace()
Global $PIX = PixelSearch(796, 682, 1117, 682, 0x0580C2,10,1)
while [MENTION=299637]ErRoR[/MENTION]
Dim $PIX = PixelSearch(796, 682, 1117, 682, 0x0580C2,10,1)
WEnd
while 1
$ARROW = PixelSearch($PIX[0] - 1, 698, $PIX[0] + 1, 698, 0xED9B00,10,1)
if [MENTION=2544426]Error T[/MENTION]hen
ContinueLoop
Endif
if Abs($PIX[0] - $ARROW[0]) <= 3 Then
Send("{SPACE}")
Sleep(500)
Dim $PIX = PixelSearch(796, 682, 1117, 682, 0x0580C2,10,1)
while [MENTION=299637]ErRoR[/MENTION]
Dim $PIX = PixelSearch(796, 682, 1117, 682, 0x0580C2,10,1)
WEnd
EndIf
WEnd
EndFunc
Func KillSwitch()
Exit
EndFunc
|
|
|
03/05/2022, 19:49
|
#6
|
elite*gold: 0
Join Date: Nov 2011
Posts: 72
Received Thanks: 51
|
Now that you have come up with something yourself, I hope you have learned something in the process!
Here is what I use, perhaps you can find things to improve/understand.
Code:
;2560x1440 monitor with Force Widescreen option enabled
Global $g_bPaused = False
Global $Color1 = 0x1675B0 ;Blue
Global $Color2 = 0xEA9305 ;Orange
HotKeySet( "{PAUSE}", "TogglePause") ;Pause the program
HotKeySet( "+!{ESC}", "Terminate") ;Close the program
While 1
FindPixels()
WEnd
Func FindPixels()
$Search1 = Pixelsearch(1064, 901, 1489, 919, $Color1, 100)
if @ error = 0 then
$Search2 = Pixelsearch($Search1[0], 924, $Search1[0], 935, $Color2, 50)
if @ error = 0 then
Sleep(60) ;Delay before the space press. Delay depends on your excavation tool. This works for minigame difficulty decrease 3.
Send("{SPACE}")
Sleep(1000) ; Pause after success to prevent spamming spacebar
ENDIF
ENDIF
EndFunc
Func TogglePause()
$g_bPaused = Not $g_bPaused
While $g_bPaused
Sleep(100)
ToolTip('Script is "Paused"', 0, 0)
WEnd
ToolTip("")
EndFunc ;==>TogglePause
Func Terminate()
Exit
EndFunc ;==>Terminate
This specifically works for a 2K monitor with force widescreen ingame enabled.
If you have different screen dimensions, figure out the correct numbers to substitute.
Things to adjust individually:
- Dimensions for Search1 (search area for blue) and Search2(search line for orange)
- sleep(60) -> works for difficulty decrease 3, needs different number for different excavation tools
As how to use this:
Alt + Shift + ESC: Close the Program
Pause (the button above page up on most keyboards): Pause the script. Always pause when just running around to prevent inputs being sent. Unpause when the minigame starts.
|
|
|
03/05/2022, 20:09
|
#7
|
elite*gold: 0
Join Date: Nov 2021
Posts: 4
Received Thanks: 4
|
Looks great ! I was on the good way as i see of your script , Thanks Mate
|
|
|
03/05/2022, 20:33
|
#8
|
elite*gold: 0
Join Date: Oct 2008
Posts: 89
Received Thanks: 5
|
Would taking a screenshot of the minigame and finding the correct placement of where mine is on my screen the best way of doing it?
|
|
|
03/05/2022, 20:40
|
#9
|
elite*gold: 0
Join Date: Nov 2011
Posts: 72
Received Thanks: 51
|
Quote:
Originally Posted by Millionairez
Would taking a screenshot of the minigame and finding the correct placement of where mine is on my screen the best way of doing it?
|
yes
|
|
|
03/05/2022, 21:45
|
#10
|
elite*gold: 0
Join Date: Oct 2008
Posts: 10
Received Thanks: 2
|
Can someone help me on this please?
|
|
|
03/05/2022, 22:13
|
#11
|
elite*gold: 0
Join Date: Oct 2008
Posts: 89
Received Thanks: 5
|
What is the point of line 16, i know it's for the arrow, but what are the numbers of 924 and 935. Is that the length of the arrow you're looking for?
|
|
|
03/05/2022, 23:54
|
#12
|
elite*gold: 0
Join Date: Nov 2011
Posts: 72
Received Thanks: 51
|
Quote:
Originally Posted by Millionairez
What is the point of line 16, i know it's for the arrow, but what are the numbers of 924 and 935. Is that the length of the arrow you're looking for?
|
Code:
$Search1 = Pixelsearch(1064, 901, 1489, 919, $Color1, 100)
This is to search the box for the color blue
Code:
$Search2 = Pixelsearch($Search1[0], 924, $Search1[0], 935, $Color2, 50)
This is for the arrow. I am looking for an entire line from y = 924 through 935 because colors are sometimes fucky, so this give a bigger (100%) chance of finding the yellow. You can also make this a point instead of a box, but I had more success with these settings
|
|
|
03/06/2022, 04:11
|
#13
|
elite*gold: 0
Join Date: Oct 2008
Posts: 89
Received Thanks: 5
|
I'm getting an error in line 15. Is this a autoit script or ahk?
The problem seems to be
if @ = 0 then
if ^ ERROR
Wow, i figured it out. It has to say @
|
|
|
03/06/2022, 17:56
|
#14
|
elite*gold: 0
Join Date: Mar 2022
Posts: 1
Received Thanks: 0
|
can you show your result pls cause i can't find the right syntaxe
|
|
|
03/06/2022, 21:47
|
#15
|
elite*gold: 0
Join Date: Oct 2008
Posts: 89
Received Thanks: 5
|
Quote:
Originally Posted by darkanzeus
can you show your result pls cause i can't find the right syntaxe
|
Go to the autoit wiki and look at the documentation.
|
|
|
All times are GMT +2. The time now is 13:05.
|
|