03-12-2024, 01:49 PM
Hello.
Im having problem with image recognition. If i use flag 128 it works with no problem. But if i want specify region it works only in first run. Once it repeats it wont detect object. Any sugestions? If i rerun script it will detect again in first run.
Im having problem with image recognition. If i use flag 128 it works with no problem. But if i want specify region it works only in first run. Once it repeats it wont detect object. Any sugestions? If i rerun script it will detect again in first run.
SetEndThreadHotkey "F12"
opt save; opt slowkeys 1;opt slowmouse 0; spe 50
int+ w1=act(win("game" "D3D Window"))
str+ dash="1"
str+ key_retarget="y"
str+ attack1="3"
str+ attack2="4"
str+ attack3="5"
int+ center_pos_x=520
int+ center_pos_y=50
RECT scan_target
SetRect &scan_target 330 5 420 60
//START
rep
if scan("resource:fight.png" w1 scan_target 4|16|0x1100 60)
key (attack1)(attack2)(attack3)
else
mou center_pos_x center_pos_y
key (dash)(key_retarget)(key_retarget)