Hello again, how can i write this in codes?
Simba Code:ClickBank;
wait until bankscreen;
Hello again, how can i write this in codes?
Simba Code:ClickBank;
wait until bankscreen;
I codes it like this:
Simba Code:t := GetSystemTime;
while ( not BankScreen ) do
begin
if GetSystemTime - t > 35000 then
begin
Writeln('Unable to click the bank!');
//Logout;
Exit;
end;
ClickBank;
t2 := GetSystemTime;
while GetSystemTime - t2 < 6500 do
if BankScreen then
Break
else
Wait(50 + Random(100));
end;
you can remove the inner while loop, if that is already done in your "ClickBank" function
Simba Code:ClickBank;
repeat
wait(10);
until bankscreen
but if bankscreen doesn't apear ,it will wait in infinite ,so it's wrong. So you should add max waiting time:
Simba Code:var
t ,maxtime: integer;
begin
maxtime := 6000;
ClickBank;
t := GetTimeRunning;
repeat
wait(10);
until (bankscreen)or( (GetTimeRunning-t) > maxtime)
end;
Or you can make it all in one line:
Simba Code:ClickBank;
Waitfunc( @bankscreen ,10 ,6000 );
Last edited by bg5; 03-18-2012 at 02:20 AM.
kk thanks
There are currently 1 users browsing this thread. (0 members and 1 guests)