• Log in or sign up for an account here: https://www.sythe.org/login

Can scar specify a window by itself?

  • Thread starter Thread starter Kishi
  • Start date Start date
K

Kishi

Guest
Sorry if this question is answered somewhere but I have searched with the search function and came out with nothing.

Back to the question. Can SCAR by means of a script specify a new window?
An example may clarify my problem:

I have a script running on a game-client (not RS) and need to close it. The window is specified at the client. When I close it the window will be gone and scar does not know what to do. Can I make scar automatically specify a new window (e.g. my desktop)? So it can do stuff on my desktop like restarting the game-client.

Thanks in advance.

~Kishi
 
procedure FindWindow(Title: string);
Finds Client window with specified title. Character case of Title must match that in window title exactly.

function FindWindowTitlePart(Title: string; CaseSensitive: Boolean): Boolean;
Finds window that contains text specified by Title parameter in window caption.

function FindWindowBySize(Width, Height: Integer): Boolean;
Finds window with specified size.

procedure ActivateClient;
Activate client window.

function GetClientWindowHandle: Integer;
Get Windows handle value of active client window.

procedure SetClientWindowHandle(H: Integer);
Set active client window to handle H.
Example:
H:= GetClientWindowHandle;
//specify another client window
FindWindow('Debug Image');
...
//return to previous client
SetClientWindowHandle(H);

procedure SetTargetBitmap(bitmap: Integer);
Sets bitmap as target for all color/bitmap searching functions. After calling SetTargetBitmap all functions won't be working with client but with specified bitmap.
Example:
SetTargetBitmap(flagstaff);
if(FindColor(x, y, $000066, 0, 0, 3, 2))then
...
The sample above will not search on client screen but in bitmap "flagstaff" instead.

procedure GetClientDimensions(var Width, Height: Integer);
Get client width and height.

Press F1 for the Scar manual.
 
Runescape Gamblingrunescape gambling
Back
Top