Results 1 to 5 of 5

Thread: Stupid Question¿

  1. #1
    Join Date
    Jan 2007
    Location
    the middle of know-where
    Posts
    1,308
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default Stupid Question¿

    Alright, I am having a blank.... I got very little sleep last night... and cannot remember how to do something.... this is what I would like help with... (embarrassing to say...)

    1. it would be an "if () then"
    2. it would click once when it saw a color
    3. the color would be in a xxyy box
    4. it would have to find the color in less than a second and click

    ..... thanks ... Maybe I will remember before => help get....
    On vacation in NeverLand,
    Code:
    typedef int bool;
    enum { false, true };

  2. #2
    Join Date
    Jan 2009
    Location
    Somewhere
    Posts
    240
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    SCAR Code:
    If FindColorSpiralTolerance(xx, yy, TheColor, MSx1, MSy1, MSx2, MSy2, 10) then
      begin
      GetMousePos(xx,yy);
      Mouse(xx,yy, 0, 0, false);
      wait(500+random(500);
      end;
    end;

    Just wrote this..Dunno if you want that... You should use TPA's anyways.

    I suppose its in the mainscreen

  3. #3
    Join Date
    Dec 2008
    Posts
    2,813
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    you could use MouseBox if you want it in a box..

  4. #4
    Join Date
    Jan 2007
    Location
    the middle of know-where
    Posts
    1,308
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    Quote Originally Posted by Colluci View Post
    SCAR Code:
    If FindColorSpiralTolerance(xx, yy, TheColor, MSx1, MSy1, MSx2, MSy2, 10) then
      begin
      GetMousePos(xx,yy);
      Mouse(xx,yy, 0, 0, false);
      wait(500+random(500);
      end;
    end;

    Just wrote this..Dunno if you want that... You should use TPA's anyways.

    I suppose its in the mainscreen
    Yea... I felt dumb for asking... I figured it out a few hours later (I had to leave home....)... this was the basic code that I was looking for.
    SCAR Code:
    begin
      if(findcolortolerance(x,y,{color},{x1},{y1},{x2},{y2},{tolerance})) then
      begin
        clickmouse(x,y,true);
        releasemouse(x,y,true);
        integer := integer + 1;
        wait(150+random(100));
      end;
    end;

    It didn't have to be really safe... so I just used clickmouse... it was quicker than the good 'ol mouse.

    Thanks.
    On vacation in NeverLand,
    Code:
    typedef int bool;
    enum { false, true };

  5. #5
    Join Date
    Jan 2009
    Location
    Somewhere
    Posts
    240
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Instead of using integer:= integer +1 use Inc(Integer);

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Stupid question
    By FagetHax0r in forum RuneScape News and General
    Replies: 5
    Last Post: 02-13-2008, 04:37 PM
  2. REALLY stupid question
    By lolpie in forum OSR Help
    Replies: 6
    Last Post: 01-27-2007, 12:16 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
  •