Hi, i'm beginner too, so this code maybe help you.
2. If Windows window window window window window is "A
(If window not active, then wait, then End Function1)
3. Check the duty of image A
4. When recognizes image A. Click Image A
5. If you don't have image A, wait until the image A
2. If Windows window window window window window is "A
(If window not active, then wait, then End Function1)
int w
w = win("The_name")
rep 1
ifa w
out "Function1 - Window_activated"
break
wait(4.5 WA w)
err
out "Function1 - No_Window"
ret
out "Function1 - Window_active"
1
break
OnScreenDisplay "QA[]Window_game_actived" 5 1920 1080 0 18 0 8|0x100
4. When recognizes image A. Click Image A
5. If you don't have image A, wait until the image A
RECT r
SetRect &r 1112 639 1139 669 ;; Area picture "Image_A"
if(scan("image:Image_A" w r 1))
out "Function1 - Image_A_1"
lef
OnScreenDisplay "Image_A_1" 1 0 0 0 24 0 2|0x100
goto g2
out "Function1 - Fail - Image_A_1"
out "Function1 - Wait Image instead"
wait 3 S "image:Image_A" w r 1|2
err
out "Function1 - Fail - Image_A_2 and End"
end
out "Function1 - Image_A_2"
OnScreenDisplay "Image_A_2" 1 0 0 0 24 0 2|0x100
;g2
Do next