Results 1 to 2 of 2

Thread: help!convirting

  1. #1
    Join Date
    Jul 2007
    Posts
    61
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default help!convirting

    this is a old script that i found....... can someone fix it up for scar 11 and srl 4.0

    SCAR Code:
    program CosmicCrafter;
    {.include SRL\SRL.scar}

    // Wear tiera and start at bank

    const
    Banker = 4737101;         //Banker fairy type thing shirt color
    Altar = 4735048;          //Grey Altar color on the runescape screen
    Portal = 10405063;        //Portal color

    Banksymbol = 123456;      //Bank symbol color on the round small map
    Floor = 4804952;          //Floor color in the altar on the round small map
    WaterSymbol = 14498311;   //Water symbol color on the round small map

    Tripp = 5;                // how many trips to do
    Rundirection = 'N';       //direction to run away in

    var
    Trips:integer;
    Area:String;

    Procedure PrintProgressReport;
    Begin
      SRLRandomsReport;
    End;

    Procedure MMouse2(x,y: Integer);    //stolen from osi and modified :)
    begin
    if(x<=789)and(x>=0)and(y<= 592)and(y>=0)then
    begin
    wait(10);
    MoveMouseSmoothEx(x,y,1,6,15,20,10);
    getmousepos(x,y);
    end;
    end;

    Procedure Findrandoms;
    begin
    findnormalrandoms;
    if(FindFight)then
      begin
        RunAwayDirection(RunDirection);
        Wait(5000+random(1000));
        RunBack;
      end;
    end;

    Procedure TalkIfNeeded;
    Var C:integer;
    Begin
    If(Findcolorspiral(x,y,16711680,212,426,400,463))then
      Begin
      Mouse(x+7,y,18,1,true);
      wait(700 + random(900));
      Mouse(148,390,20,2,true);
      C:=0;
      repeat
      wait(100);
      C:=C+1;
      until(Bankscreen)or(C>19)
      end;
    end;

    Procedure Openbank4;
    Var C:Integer;
    Begin
    If(Findobj(x,y,'Talk',Banker,3))then
      Begin
      Mouse(x,y,1,1,false);
      if(ChooseOption(x,y,'Bank'))then
      begin
        Flag;
        C:=0;
        repeat
        Wait(100);
        c:=c+1;
        TalkIfNeeded;
        until(BankScreen)or(c>=50)
      end;
    end;
    end;

    Procedure CloseBank2;
    Var CloseBankScreen,C:Integer;
    begin
      CloseBankScreen := BitmapFromString(73, 15, 'z78DAE598E10E82300' +
           'C845F89B8C5E07F7DFF57320A3FB61C576EEBA8A8982C66162CFD' +
           '766DD33CA7474A19D75B9E520E5D9927D7744F979D95DDEB59E32' +
           '3E08952BCCF1E5EFF468D452CFE84FC04B5797A7DCE406DF184F9' +
           'D3E0E711A480DAEA8FF97CC5C6436DB942A911228B27C8A8C1CF8' +
           '3799544567F4C6AB64D1FBB506AA682D08772671835372F0FB51D' +
           'F57D1535E5DF99659557CDE85596C085FEEAD011B3418E7675C03' +
           '795A2215799D62AE9A146F32A569677FC27B84A5EA54DC5CEA1A3' +
           '561BBB3AE09B4AD1904FBEAE5C3F35BA53E4435D6548B095DAE09' +
           'DBE7717764AA67DF9D63E5D9D7E029D0D1D15D4369428740EA576' +
           '366242F2E11938B2EFADBD25E664A51BC1BA86D98FEAC8569CDC2' +
           'DB07B917E1F35560195BA66DBD8967ABF579D76B0B7F76D95D936' +
           'D4523E7BBA5AEDFE84ED607CA468E8DE8E9D63B43E61506FFF81F' +
           '94CDF44257E3EE69FF9F87921B5E3E69C9134CF40CD3E5DA35416' +
           '339DFE2A764F2F25481A');
      If Findbitmapin(CloseBankScreen,x,y,411,27,500,55)then
      Begin
      Mouse(x+5,y+3,2,0,true);
      C:=0;
      repeat
      wait(100);
      C:=C+1;
      Until not(IsTextAt2(185,36,'The Bank of RuneScape',100))or(c>19)
      end;
    Freebitmap(CloseBankScreen);
    end;

    Function ColorFromBottom(Color:Integer):Boolean;
    Var A:integer;
    begin  A:= 162;
    Repeat
         If(Findcolorspiral(x,y,Color,570,A,725,162))then begin
            Result:=true; end
            else A:= A-5;
    until(Result=true)or(A<=5)
      If(A<=5)then
       Result:=false;
    end;

    Function CircleMouse(StartAngle,EndAngle,Color:integer;WantColor:Boolean):Boolean;
    var StopPoint,Counter:integer;
    Begin
      Counter:=0;
      If(StartAngle=360)then
        Startangle:=0;
      StopPoint:= (EndAngle-StartAngle);
      StartAngle:=StartAngle-90;
      Repeat
           Mmouse2(Round(60*cos(Startangle * (pi/180)))+646,Round(60*sin(Startangle * (pi/180)))+81);
           GetmousePos(x,y);
       If((Not(Getcolor(x,y)=Color))and(WantColor=False))or
         ((Getcolor(x,y)=Color)and(WantColor=true))then
            begin
            result:=true; Mouse(x,y,1,1,true); Exit;
            end;
       StartAngle:=Startangle+1;
       Counter:=counter+1;
      Until(Startangle>270)or(Counter=StopPoint)
    end;


    Procedure WalktoAltar;  //sometimes walking dont work
    begin
    Status('Walking to Altar');
    Findrandoms;
    Mouse(708,109,4,2,true);
    Setrun(true);
    wait(1200);
    flag;
    Mouse(672,101,5,5,true);
    flag;
    If(ColorfromBottom(WaterSymbol))then
      Begin
      Mouse(x+3,y-3,1,1,true);
      flag;
      If(ColorfromBottom(WaterSymbol))then
        Begin
        Mouse(x+31,y+38,1,1,true);
        flag;
        If(CircleMouse(163,195,0,false))then flag;
        If(CircleMouse(185,270,0,false))then flag;
        If(CircleMouse(265,275,0,false))then flag;
        If(CircleMouse(160,270,0,false))then
          Begin
          Repeat wait(100); until not(Flagpresent)
          Repeat Wait(100); until(flagpresent);
          wait(2000); flag;
          If(CircleMouse(170,270,0,false))then flag;
          If(Findobj(x,y,'Enter',Altar,3))then
            Begin
            Mouse(x,y,2,2,true);
            repeat
            wait(100);
            until (Findcolorspiral(x,y,floor,570,5,725,162))
            end;
          end;
        end;
      end;
    end;

    Procedure DetectArea;
    Begin
    Status('Finding Where We Are');
    Area:='';
    Repeat
    If not(Getcolor(646, 151)=0)and(area='')then
      Begin
      Area:='N'; Mouse(646,153,3,3,true); wait(2000); flag; exit;
      end;
    If not(Getcolor(584,84)=0)and(area='')then
      Begin
      Area:='E'; Mouse(584, 84,3,3,true); wait(2000); flag; exit;
      end;
    If not(Getcolor(713, 80)=0)and(area='')then
      Begin
      Area:='W'; Mouse(713,80,3,3,true); wait(2000); flag; exit;
      end;
    If not(Getcolor(653, 18)=0)and(area='')then
      Begin
      Area:='S'; Mouse(653,18,3,3,true); wait(2000); flag; exit;
      end;
    Until not(area='')
    end;

    Procedure CraftandBack;
    begin
    Status('Crafting');
    Findrandoms;
    If(Findobj(x,y,'Craft',Altar,5))then
      Begin
      Mouse(x,y,2,2,true);
      repeat
      wait(100);
      until(inventorycount=1)
      wait(1700 + random(600));
      RunAwayDirection(Area);
      gametab(4);
      If(Findcolorspiral(x,y,floor,614,40,689,112))then
        Begin
        Mouse(x,y,2,2,true);
        flag;
        wait(1300 + random(400));
        end;
      end;
    end;

    Procedure PortalOut;
    begin
    Status('Finding Portal');
    repeat
    Findrandoms;
    until(Findcolorspiraltolerance(x,y,portal,1,1,512,336,5));
    If(Findobj(x,y,'Use',Portal,5))then
      Begin
      Mouse(x,y,1,1,true);
      flag;
      repeat
            wait(100);
            Findrandoms;
      until not(Findcolorspiral(x,y,floor,570,5,725,162))
      end;
    end;

    Procedure AltartoBank;  //sometimes walking dont work
    begin
    wait(random(500));
    If(CircleMouse(270,360,0,false))then wait(2000); flag;
    If(CircleMouse(30,45,0,false))then
      Begin
        wait(1600);
        Repeat wait(100); until not(Flagpresent)
        Repeat Wait(100); until(flagpresent);
        wait(3000 + random(1000)); flag;
        If(CircleMouse(30,90,0,false))then flag;
        If(CircleMouse(0,0,0,false))then wait(8000); flag;
        Mouse(635,49,5,5,true);
        flag;
        If(ColorfromBottom(WaterSymbol))then
          Begin
          Mouse(x-5,y-9,1,1,true);
          flag;
          repeat
          Mouse(594,57,10,10,true);
          flag;
          until(Findcolorspiral(x,y,Banksymbol,570,5,725,162))
          If(Findcolorspiral(x,y,Banksymbol,570,5,725,162))then
            Begin
            Mouse(x,y,2,2,true);
            wait(1400);
            flag;
            Findrandoms;
            end;
          end;
      end;
    end;

    begin
    Activateclient;
    SetupSRL;
    ChatsOff;
    Repeat
    Openbank4;
    Deposit(1,28,2);
    wait(random(500));
    withdraw(1,1,0);
    wait(500 + random(200));
    Closebank2;
    GameTab(4);
    WalktoAltar;
    DetectArea;
    CraftandBack;
    PortalOut;
    AltartoBank;
    Trips:=trips+1;
    PrintProgressReport;
    Until(Trips>=Tripp)
    Logout;
    end.

  2. #2
    Join Date
    Sep 2006
    Posts
    6,089
    Mentioned
    77 Post(s)
    Quoted
    43 Post(s)

    Default

    This is not a request section.
    I don't think it should be too hard to do it yourself.

    And scar 11? I only have 3.13?
    Hup Holland Hup!

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. help with convirting
    By qcrist in forum OSR Help
    Replies: 2
    Last Post: 10-26-2007, 11: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
  •