Results 1 to 4 of 4

Thread: No FindColor Response

  1. #1
    Join Date
    Jan 2009
    Posts
    12
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default No FindColor Response

    Errm, on line 35, when i run this script, it never saves the furnace minimap icon color... to x,y, thus not allowing me to click the x,y, any ideas?

    program AlKharidDefultSmither;

    var x, y: Integer;

    const
    IronOreColour= 1515834;
    CoalOreColour= 1780523;
    FurnaceMiniMap= 1245183;
    FurnaceColor= 1572863;

    procedure ClickOre;
    begin
    if (IronOreColour=1515834) then
    begin
    ClickMouse (724+random(2), 331-random(2), False);
    Wait(200+random(200))
    ClickMouse (730, 384, True);
    end;
    end;

    procedure ClickCoal;
    begin
    if (CoalOreColour= 1780523) then
    begin
    ClickMouse (771+random(3), 331-random(2), False);
    Wait(200+random(200))
    ClickMouse (764+random(3), 436-random(2), True);
    end;
    end;

    procedure MoveToFurnace;
    begin
    ClickMouse (1815,43, True);
    Wait(9000+random(500))
    if (FindColor(x,y,FurnaceMiniMap,0,0,1800,760)) then <<<-------HERE
    begin
    Wait(500)
    ClickMouse(x,y,True);
    end;
    end;

    Procedure Smelt;
    Begin
    ClickMouse(260, 707, False);
    ClickMouse(262, 756, True);
    End;

    begin
    ClickOre;
    Wait(600+random(300))
    ClickCoal;
    Wait(300+random(300))
    MoveToFurnace;
    Smelt;
    end.

  2. #2
    Join Date
    Dec 2007
    Location
    Wizzup?'s boat
    Posts
    1,013
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    wait editiing...

    SCAR Code:
    program AlKharidDefultSmither;
    {.include SRL/SRL.scar}

    var
      x, y: Integer;

    const
      IronOreColour= 1515834;
      CoalOreColour= 1780523;
      FurnaceMiniMap= 1245183;
      FurnaceColor= 1572863;

    procedure ClickOre;
    begin
      if (FindColorTolerance(IronOreColour, x, y, MSX1, MSY1, MSX2, MSY2) then
      begin
        Mouse(724, 331, 4, 4, False); //if you're trying to CLICK the ore, change 724 > 'x', and 331 > 'y'
        Wait(200+random(200))
        Mouse(730, 384, 4, 4, True); //no idea what this is
      end;
    end;

    procedure ClickCoal;
    begin
    if (FindColorTolerance(CoalOreColour, x, y, MSX1, MSY1, MSX2, MSY2) then
    begin
    Mouse(771, 331, 4, 4, False);
    Wait(200+random(200))
    Mouse(764, 436, 3, 2, True);
    end;
    end;

    procedure MoveToFurnace;
    begin
    Mouse(1815,43, x, y, True);
    Wait(9000+random(500))
    if (FindColor(FurnaceMiniMap, x,y, MSX1, MSY1, MSX2, MSY2) then <<<-------HERE
    begin
    Wait(500)
    Mouse(x,y,4, 4,True);
    end;
    end;

    Procedure Smelt;
    Begin
    Mouse(260, 707, 4, 4, False);
    Mouse(262, 756, 4, 4, True);
    End;

    begin
      SetupSRL;
      ActivateClient;
    ClickOre;
    Wait(600+random(300))
    ClickCoal;
    Wait(300+random(300))
    MoveToFurnace;
    Smelt;
    end.

    that all should clean it up, though i dont have scar on this pc to compile

    btw, you really need to read some tuts

    i suggest:
    - learning what includes are
    - DTM's
    - logins
    - how to use failsafes
    Project: Welcome To Rainbow

  3. #3
    Join Date
    Jan 2009
    Posts
    12
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Lol, Sorry it was a copyy error, yeah its cleaned pretty but what do I do with the

    (FindColor(FurnaceMiniMap, x,y, MSX1, MSY1, MSX2, MSY2))
    MSX1, MSY1, MSX2, MSY2's?

  4. #4
    Join Date
    Dec 2007
    Location
    Wizzup?'s boat
    Posts
    1,013
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    MSX1 == Main screen x1 (the top left corner of the client x value)
    and so on

    others include:
    - MMX1, MMY1, MMX2, MMY2 == Minimap co-ords
    - MiX1, MiY1, MiX2, MiY2 == inventory co-ords


    use this though: FindSymbol('furnace', x, y); (or it might be FindSymbol('furnace', x, y) cant remember)
    Project: Welcome To Rainbow

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Response library
    By Championship in forum RS3 Outdated / Broken Scripts
    Replies: 12
    Last Post: 06-11-2008, 02:36 PM
  2. Why does the response keep on looping?
    By Psychor in forum OSR Help
    Replies: 0
    Last Post: 11-12-2007, 05:10 PM
  3. auto response... HELP!!!
    By wade11 in forum OSR Help
    Replies: 2
    Last Post: 12-20-2006, 05:36 PM

Posting Permissions

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