Results 1 to 5 of 5

Thread: anyone know how to do this? if wait is longer than...

  1. #1
    Join Date
    Mar 2006
    Posts
    201
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default anyone know how to do this? if wait is longer than...

    I'm building my first scar script, and i was wondering if there is a way to do something along the lines of

    if "until (FindMMColor(x,y,bankcolour)" takes longer than 2 seconds, logout. will something like that work or is there a better way to make that work?

  2. #2
    Join Date
    Feb 2006
    Location
    Australia, NSW.
    Posts
    1,461
    Mentioned
    1 Post(s)
    Quoted
    0 Post(s)

    Default

    Code:
    var
      a: integer;
    begin
     a:= GetSystemTime;
      FindMMColor(x, y, bankcolor);
     if(GetSystemTime-a >= 2000)then
       Logout;
    end.

  3. #3
    Join Date
    Mar 2006
    Posts
    201
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    thanks =) very much.

  4. #4
    Join Date
    Feb 2006
    Posts
    406
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    wait, did you want it to search multiple times or just once?
    because people cover symbols, you might want it to search more than once
    that would be something like:
    Code:
    var
      a:integer;
    begin
      marktime(a);
      repeat
        wait(100+random(10))
        if(timefrommark(a)>2000)then
          logout;
      until(FindMMColor(x, y, bankcolor));
    end.

  5. #5
    Join Date
    Mar 2006
    Posts
    201
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    hmm lol thats a good idea. thank you

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Starblaster100 is no longer an Admin.
    By WT-Fakawi in forum News and General
    Replies: 0
    Last Post: 09-01-2008, 04:51 PM
  2. .jagex_cache_32 no longer used?
    By Harry in forum RS has been updated.
    Replies: 3
    Last Post: 07-13-2008, 03:11 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •