Results 1 to 3 of 3

Thread: couple of functions

  1. #1
    Join Date
    Feb 2006
    Location
    With mooncow on the moon
    Posts
    292
    Mentioned
    1 Post(s)
    Quoted
    0 Post(s)

    Default couple of functions

    hey,

    well the findclosest function finds the closest color to you on the minimap and clicks it, works very well for monster killing/item picking up and the runfrom function will run from a specified color, may be useful for lvl 3's who arew picking stuff up in dangerouse places or something

    Code:
    function findclosest(color :integer):boolean;
    var x1, y1, x2, y2 : integer;
        xd, yd : integer;
    begin
         x1:=648;
         y1:=84;
         x2:=4;
         y2:=4;
         xd:=x1;
         yd:=y1;
           begin
            repeat
                x1:= x1 - x2;
                y1:= y1 - y2;
                xd:= xd + x2;
                yd:= yd + y2
                  if(findcolorspiral(x,y,color,x1,y1,xd,yd))then
                  begin
                   Mouse(x,y,1,1,true)
                   flag;
                   result:=true;
                 end;
               wait(25+random(20))
            until(result)or(y1=4)
           end;
        end;
    Code:
    function runfrom(maxXdis, maxYdis, color : integer):boolean;
    var  x1, y1, x2, y2 : integer;
         runx, runy : integer;
    begin
       x1:=648;
       y1:=84;
       x2:=x1;
       y2:=y1;
         begin
           repeat
             x1:= x1 - 1;
             y1:= y1 - 1;
             x2:= x2 + 1;
             y2:= y2 + 1;
              if(findcolor(x,y,color,x1,y1,x2,y2))then
               begin
                result:=true;
               end;
             until(result)or(x1=maxXdis)
           begin
         runx:=0;
         runy:=-35;
       Mouse(runx + 648, runy + 83,1,1,true);
        flag;
          Mouse(648 - runx,83 - runy,1,1,true);
           end;
       end;
    end;

  2. #2
    Join Date
    Feb 2006
    Posts
    582
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    FindColorSpiral? Wouldn't that be finding the closest color to begin with?
    Free File Hosting
    No download timers!

    Rifkwtf.com

  3. #3
    Join Date
    Feb 2006
    Location
    Amsterdam
    Posts
    6,136
    Mentioned
    28 Post(s)
    Quoted
    17 Post(s)

    Default

    Yes, you are Right Pwnd. It is FindColorSpiral...
    SRL is a Library of routines made by the SRL community written for the Program Simba.
    We produce Scripts for the game Runescape.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Couple Functions I've made [IsMultiple, ReverseString, FormatNumber]
    By deathbyvirus in forum Research & Development Lounge
    Replies: 4
    Last Post: 08-06-2008, 10:56 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
  •