Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Multiple scan instructions, only first one works.
#2
scan overwrites q. Set q before each scan call. Create a function, then will be less code.

Macro Macro2759
Code:
Copy      Help
;...
int w=win("Board editor • lichess.org - Mozilla Firefox")
sub.Scan(w "Pawn_White" WP) ;;Scan for the postions of the white pawns.
sub.Scan(w "Pawn_Black6" BP) ;;Scan for the postions of the black pawns.
;...


#sub Scan
function hwnd $image ARRAY(RECT)&a

RECT q ;;This rectengular will equal the dimensions and position of the chess board.
SetRect &q 500 225 1012 737
scan(F"$desktop$\lichess\{image}.bmp" hwnd q 1 20 a)


Messages In This Thread

Forum Jump:


Users browsing this thread: 2 Guest(s)