SRL Archive - Reflection Help

Hmmmm.


Wyn

2010-09-11 19:29:08

I am working on a churner and was wondering….

How could I make a script click the object then wait till the interface was up?

I am planning on just doing a repeat and until and loop them; but I am not sure how to implement.


Please show has a example.

Dynamite

2010-09-11 19:40:46

Repeat
Wait(100)
Until InterfaceUp(ID)
Or something like that.
The logic is correct in that ^

Wyn

2010-09-11 20:49:48

From: The Man
Repeat
Wait(100)
Until InterfaceUp(ID)
Or something like that.
The logic is correct in that ^


Would GetInterface be sufficient?

Sex

2010-09-11 22:38:34

I'd use a while or some shit..
Also, please use more descriptive titles.

Wyn

2010-09-12 00:36:46

From: Sex
I'd use a while or some shit..
Also, please use more descriptive titles.


Must be descriptive for you to come and tell me to use a while and shit >.>


Can anyone answer my above question?

Wanted

2010-09-12 01:50:00

Why use reflection to wait for an interface to pop up? Just use a simple getcolor check or something.

Wyn

2010-09-12 02:06:02

From: IceFire908
Why use reflection to wait for an interface to pop up? Just use a simple getcolor check or something.


I would rather use interfaces such it's much easier. I just add a wait and use the interface as a check.

[offtopic]Jeez haven't talked to you in a while XD[/offtopic]

Wanted

2010-09-12 02:21:29

From: wyn10
I would rather use interfaces such it's much easier.


Lol I checking one pixel on the screen is much easier then trying to figure out how to use reflection interfaces.

Look its much better to use a color check, just find a static color that never moves on the interface

procedure WaitForInterface;
var
T: Integer;
begin
T := GetSystemTime;
while ((GetColor(101, 202) <> 12345678) and ((GetSystemTime - T) < 10000)) do
Wait(100);
end;

just plugin the color on the interface and its coordinates

101 = X
202 = Y
12345678 = Decimal color

Hint: use the color picker ;)

Wyn

2010-09-12 02:55:35

From: IceFire908
Lol I checking one pixel on the screen is much easier then trying to figure out how to use reflection interfaces.

Look its much better to use a color check, just find a static color that never moves on the interface

procedure WaitForInterface;
var
T: Integer;
begin
T := GetSystemTime;
while ((GetColor(101, 202) <> 12345678) and ((GetSystemTime - T) < 10000)) do
Wait(100);
end;

just plugin the color on the interface and its coordinates

101 = X
202 = Y
12345678 = Decimal color

Hint: use the color picker ;)


Ah gotcha. (I also know how to find interfaces :tongue:)