Page 1 of 2 12 LastLast
Results 1 to 25 of 30

Thread: RS Update: Bank Screen

  1. #1
    Join Date
    Feb 2006
    Location
    Amsterdam
    Posts
    13,692
    Mentioned
    146 Post(s)
    Quoted
    130 Post(s)

    Default RS Update: Bank Screen

    There is a new RuneScape bank screen. We are going to fix it right now.

    New Bank.scar:

    SCAR Code:
    //-----------------------------------------------------------------//
    //--               Scar Standard Resource Library                --//
    //--               » Bank Routines                               --//
    //-----------------------------------------------------------------//

    // * function  BankScreen:Boolean;                                             // * by RSN
    // * function  PinScreen:Boolean;                                              // * by Starblaster100
    // * function  InPin(pin: string): Boolean;                                    // * by ZephyrsFury
    // * function BankIndexToBankPoint(Ind: Integer): TPoint;                      // * by Wizzup
    // * function BankPointToIndex(P: TPoint): Integer;                            // * by Wizzup
    // * function BankIndexToMSBox(Ind: Integer): TBox;                            // * by Wizzup
    // * function MSTPointToBankIndex(P: TPoint): Integer;                         // * by Wizzup
    // * Procedure Fixbank                                                         // * by WT-Fakawi/RsN
    // * Function FixBankTab: Boolean;                                             // * by Wizzup?
    // * procedure SearchBank(Item: string);                                       // * by ZephyrsFury
    // * procedure Deposit(slot, toslot, thetype:integer);                         // * by PPLSUQBAWLZ / Stupid3ooo
    // * procedure Withdraw(Col,Row,Amount:integer);                               // * by Odie3355/Stupid3ooo/Starblaster100 fixed by Town
    // * procedure DepositAll;                                                     // * by Mutant Squirrle
    // * Function OpenBankQuiet(WhichBank:string):Boolean;                         // * by WT-Fakawi
    // * Function  FindBank(TheBank:string): Boolean;                              // * by WT-Fakawi
    // * Procedure CloseBank;                                                      // * by Starblaster100
    // * Function OpenBankGlass(WhichBank:String; ChangeCompass:Boolean): Boolean; // * By Wizzup?
    // * function OpenBankFast(Location: String): Boolean;                         // * by Wizzup? and Nielsie95
    // * function OpenBank;                                                        // * by SRL

    function ClickToContinue: Boolean; forward;

    {*******************************************************************************
    function BankScreen: Boolean;
    by: SRL Dev Team
    Description: Finds Bankscreen. Returns true if Found.
    *******************************************************************************}


    function BankScreen: Boolean;

    begin
      Result := FindTextTPA(4106994, 20, 20, 22, 400, 45, 'Bank', upchars, Nothing);
    end;

    {*******************************************************************************
    function PinScreen: Boolean;
    by: Starblaster100
    Description: Finds Pin Screen. Returns true if Found.
    *******************************************************************************}


    function PinScreen: Boolean;
    Var
       x, y: Integer;
    begin
      Result := FindText(x, y, 'First', upchars, 175, 80, 212, 100);
    end;

    {*******************************************************************************
    function InPin(Pin: String): Boolean;
    by: ZephyrsFury
    Description: Enters bank pin. Will try 3 times, returns true if bank is opened.
    *******************************************************************************}


    function InPin(Pin: string): Boolean;
    var
      TMouseSpeed, iNumber, Tx, Ty, Counter: Integer;
    begin
      if (not(PinScreen)) then Exit;
      if (GetNumbers(Pin) <> Pin) then
      begin
        srl_Warn('InPin', '''' + Pin + ''' is not a valid Pin', warn_AllVersions);
        Exit;
      end;
      if (Length(Pin) <> 4) then
      begin
        srl_Warn('InPin', 'Pin must be 4 digits long', warn_AllVersions);
        Exit;
      end;
      TMouseSpeed := MouseSpeed;
      MouseSpeed := 25;
      Wait(1000 + Random(1000));
      repeat
        if (PinScreen) then
        begin
          for iNumber := 1 to Length(Pin) do
          begin
            if (Random(4) = 0) then
            begin
              repeat
                Tx := Random(765);
                Ty := Random(504);
              until (not(IntInBox(Tx, Ty, IntToBox(30, 100, 383, 319))));
              MMouse(Tx, Ty, 0, 0);
              Wait(500 + Random(500));
            end;
            if (not(FindText(Tx, Ty, Pin[iNumber], UpChars, 30, 100, 383, 319))) then
              GetMousePos(Tx, Ty);
            Mouse(Tx, Ty, 10, 10, True);
            Wait(1000 + Random(500));
          end;
        end;
        Wait(1000 + Random(500));
        if (BankScreen) then
        begin
          Result := True;
          MouseSpeed := TMouseSpeed;
          Exit;
        end;
        ClickToContinue;
        while (not(FindColor(Tx, Ty, 0, 7, 460, 69, 474))) do
        begin
          if (not(LoggedIn)) then
          begin
            MouseSpeed := TMouseSpeed;
            Exit;
          end;
          Wait(1000 + Random(500));
        end;
        Inc(Counter);
      until(Counter > 2);
    end;

    {*******************************************************************************
    Function MSTPointToBankPoint(P: TPoint): TPoint;
    by: Wizzup
    Description: Converts a point on the Mainscreen to the point in the Bank.
    First Row and Col are (0,0).
    *******************************************************************************}

    Function MSTPointToBankPoint(MSP: TPoint): TPoint;

    Begin
      Result.X := (MSP.X - 38) / 44;
      Result.Y := (MSP.Y - 90) / 45;
    End;

    {*******************************************************************************
    function BankPointToBankIndex(P: TPoint): Integer;
    by: Wizzup?
    Description: Converts a Bank Point (Row,Col) to Bank Index (spot in bank).
    (0, 0) = 1
    *******************************************************************************}


    Function BankPointToBankIndex(P: TPoint): Integer;

    Begin
      Result := P.Y * 10 + P.X + 1;
    End;

    {*******************************************************************************
    function BankIndexToBankPoint(ind: Integer): TPoint;
    by: Wizzup
    Description: Converts the Bank Index (spot in bank) to a Bank Point (Row,Col).
    1 = (0, 0)
    *******************************************************************************}

    Function BankIndexToBankPoint(Index: Integer): TPoint;

    Begin
      Index := Index - 1;
      Result := Point((Index Mod 10), Floor(Index Div 10));
    End;

    {*******************************************************************************
    Function BankIndexToMSPoint(Index: Integer): TPoint;
    by: Wizzup?
    Description: Converts the Bank Index (spot in bank) to a Mainscreen TPoint of
    the Index. (Top Left)
    *******************************************************************************}


    Function BankIndexToMSPoint(Index: Integer): TPoint;

    Begin
      Index := Index - 1;
      Result := Point(38 + (Index Mod 10) * 44, 90 + Floor(Index Div 10) * 45);
    End;

    {*******************************************************************************
    function BankIndexToMSBox(ind:Integer): TBox;
    by: Wizzup
    Description: Converts the Bank Index (spot in bank) to a Mainscreen TBox of
    the Index.
    *******************************************************************************}


    Function BankIndexToMSBox(Index: Integer): TBox;

    Var
       P: TPoint;
    Begin
      P := BankIndexToMSPoint(Index);
      Result.X1 := P.X;
      Result.Y1 := P.Y;
      Result.X2 := Result.X1 + 31;
      Result.Y2 := Result.Y1 + 32;
    End;

    {*******************************************************************************
    procedure FixBank;
    by: WT-Fakawi/RsN
    Description: Scrolls the bank screen up.
    *******************************************************************************}


    procedure FixBank;
    var
      x, y, t: Integer;
    begin
      if (GetColor(486, 103) = 1975337) and (BankScreen) then
      begin
        MMouse(486, 105, 3, 3);
        GetMousePos(x, y);
        HoldMouse(x + Random(1), y + Random(1), True);
        t := getsystemtime;
        while (GetColor(486, 103) = 1975337) do
        begin
          Wait(100);
          if getsystemtime - t > 10000 Then
          begin
            releasemouse(x, y, true);
            exit;
          end;
        end;
        Wait(300 + Random(300));
        GetMousePos(x, y);
        ReleaseMouse(x, y, True);
      end;
    end;

    {*******************************************************************************
    Function FixBankTab: Boolean;
    by: Wizzup?
    Description: Fixes the BankTab to 'View All'
    *******************************************************************************}


    Function FixBankTab: Boolean;

    Var
       activeTPA, notactiveTPA: TPointArray;
       T: Integer;
    Begin
      Result := False;
      FindColorsTolerance(activeTPA, 2896954, 25, 45, 70, 80, 5);
      FindColorsTolerance(notactiveTPA, 2437688, 25, 45, 70, 80, 5);

      If Length(activeTPA) > Length(notactiveTPA) Then
      Begin
        Result := True;
        Exit;
      End;

      Mouse(40, 60, 10, 10, True);
      T := GetSystemTime;
      While Length(activeTPA) <= Length(notactiveTPA) Do
      Begin
        FindColorsTolerance(activeTPA, 2896954, 25, 45, 70, 80, 5);
        FindColorsTolerance(notactiveTPA, 2437688, 25, 45, 70, 80, 5);
        Wait(500);
        If ((GetSystemTime - T) / 1500) Mod 2 = 0 Then
          Mouse(40, 60, 10, 10, True);
        If GetSystemTime - T > 10000 Then
          Exit;
      End;
    End;

    {*******************************************************************************
    procedure SearchBank(Item: string);
    by: ZephyrsFury
    Description: Searches for Item in your bank.
    *******************************************************************************}


    procedure SearchBank(Item: string);
    var
      T, Tx, Ty: Integer;
    begin
      if (not(BankScreen)) then Exit;
      FixBankTab;
      MarkTime(T);
      while (BankScreen) and (not(FindTextTPA(4106994, 20, 20, 22, 400, 45, 'search', UpChars, Nothing))) do
      begin
        MouseBox(307, 300, 326, 316, 1);
        Wait(1000 + Random(500));
        if (TimeFromMark(T) > 30000) then Exit;
      end;
      if (not(FindColor(Tx, Ty, 0, 7, 457, 137, 475))) then
        TypeSend(Item);
    end;

    {*******************************************************************************
    procedure Deposit(slot, toslot, thetype: Integer);
    by: WT-Fakawi/PPLSUQBAWLZ/Stupid3ooo/Town
    Description: Deposits from Slot to ToSlot.
      vType True = Deposit All. vType False = Deposit one by one.
      Any integer is deposit with Deposit X. (except for 5 and 10)
    *******************************************************************************}


    Procedure Deposit(SlotFrom, SlotTo: Integer; vType: Variant);

    Var
       DepositX: Boolean;
       All: Variant;
       I, T, x, y: Integer;

    Begin
      If Not BankScreen Then
        Exit;
      If vType = 2 Then
        srl_Warn('Deposit', '2 now means store per 2, not ''All''', 15);
      DepositX := False;
      Case VarType(vType) Of
        3: Begin
             DepositX := Not InIntArray([1, 5, 10], vType);
             If vType = 1 Then
               All := False
             Else
               All := True;
           End;
        11: All := vType;
      End;
      For I := SlotFrom To SlotTo Do
      Begin
        If Not ExistsItem(I) Then
          Continue;
        MouseItem(I, Not All);
        If DepositX Then
        Begin
          ChooseOption('Deposit-X');
          T := GetSystemTime;
          While (Not FindColor(x, y, 8388608, MCX1, MCY1, MCX2, MCY2)) And (GetSystemTime - T < 3000) Do
            Wait(100);
          TypeSend(vType);
        End Else If VarType(vType) = 3 Then
          ChooseOption('Deposit-' + vType)
        Else
          ChooseOption('Deposit-All');
        T := GetSystemTime;
        Wait(RandomRange(200, 300));
        While ExistsItem(I) And (GetSystemTime - T < 2000) Do
          Wait(50);
      End;
    End;

    {*******************************************************************************
    procedure Withdraw(Col, Row, Amount: Integer);
    by: Starblaster100, Town and Wizzup?
    Description: Withdraws Amount at Column/Row.
    *******************************************************************************}


    procedure Withdraw(col, row, Amount: Integer);

    Var
      BBox: TBox;
     
    begin
      FixBank;
      FixBankTab;
      BBox := BankIndexToMSBox(BankPointToBankIndex(Point(Col - 1, Row - 1)));
      If Amount = 1 Then
      Begin
        MouseBox(BBox.X1 + 5, BBox.Y1 + 5, BBox.X2 - 5, BBox.Y2 - 5, 1);
        Wait(RandomRange(50, 150));
      End
      Else
      Begin
        MouseBox(BBox.X1 + 5, BBox.Y1 + 5, BBox.X2 - 5, BBox.Y2 - 5, 2);
        if (Amount = 5) or (Amount = 10) then
          ChooseOption('Withdraw-' +IntToStr(Amount))
        else if Amount = 0 then
          ChooseOption('Withdraw-All')
        else
        if (ChooseOption('Withdraw-X')) then
        begin
          Wait(1000 + Random(100));
          TypeSend(IntToStr(Amount));
        end;
      End;
    end;


    {*******************************************************************************
    procedure DepositAll;
    by:
    Description: Deposits all items in your inventory
    *******************************************************************************}


    procedure DepositAll;
    begin
      if (BankScreen) then
        Deposit(1, 28, True);
    end;

    {*******************************************************************************
    function OpenBankQuiet(WhichBank: string): Boolean;
    By: WT-Fakawi and modified by Ron
    Description: Opens any given bank in the free world using
    FindDeformedBitmapToleranceIn. Avoids strange mouse movements. Will cause
    significant lag (approx. 1 second), but finds the bank with one click.

    Valid arguments are:
    'feb' (Falador East Bank)
    'fwb' (Falador West Bank)
    'veb' (Varrock East Bank)
    'vwb' (Varrock West Bank)
    'db'  (Draynor Bank)
    'eb'  (Edgeville Bank)
    'akb' (Al-Kharid Bank)
    *******************************************************************************}


    function OpenBankQuiet(WhichBank: string): Boolean;
    var
      TheCounter, dx, dy, tol, Mark2, Mark3: Integer;
      acc, accthres: Extended;
    begin
      case WhichBank of
        'feb', 'fwb': TheCounter := BitmapFromString(1, 10, '6C583296897A948779948779736' +
            'C63A59E968C7F6F9686749B8A7685663E');
        // varrock west
        'vwb': TheCounter:= BitmapFromString(10, 1, 'A0997F504A49504A49504A495E4' +
           'F215E4F215E4F215E4F212C250EA0997F');
        // varrock east
        'veb': TheCounter := BitmapFromString(1, 10, '5E4D1589826D88806D88806D867' +
           'F6C9996907C7664847D648C836891876B');
        // draynor and this works too for alkharid
        'akb', 'db', 'eb': TheCounter:= BitmapFromString(12, 1, '584209735C29735C29735C29605' +
           '85558504D60504D58504D58504D58504D58504D605855');
      end;

      MarkTime(Mark3);
      tol := 1;
      accthres := 0.6;
      repeat
        if (Length(Players) > 0) then
          if (Players[CurrentPlayer].Pin <> '') then
            InPin(Players[CurrentPlayer].Pin);
        if BankScreen or PinScreen then
        begin
          Result := True;
          FreeBitmap(TheCounter);
          Exit;
        end;
        if IsUpTextMultiCustom(['ank', 'Bo', 'ot']) then
        begin
          GetMousePos(dx, dy);
          Mouse(dx, dy, 0, 0, False);
          if ChooseOption('uickly') then
          begin
            MarkTime(Mark2);
            repeat
              Wait(10);
              if TimeFromMark(Mark2) > 20000 then
              begin
                WriteLn('Couldn''t find the bank. Exiting');
                FreeBitmap(TheCounter);
                Exit;
              end;
            until BankScreen or PinScreen;
            if (Length(Players) > 0) then
              if (Players[CurrentPlayer].Pin <> '') then
                InPin(Players[CurrentPlayer].Pin);
            Result := True;
            FreeBitmap(TheCounter);
            Exit;
          end;
        end;

        FindDeformedBitmapToleranceIn(TheCounter, dx, dy, MSX1 + 50, MSY1 + 50, MSX2
          - 50, MSY2 - 50, tol, 4, True, acc);
        if (acc >= accthres) then
        begin
          if (Length(Players) > 0) then
            if (Players[CurrentPlayer].Pin <> '') then
              InPin(Players[CurrentPlayer].Pin);
          if BankScreen or PinScreen then
          begin
            Result := True;
            FreeBitmap(TheCounter);
            Exit;
          end;
          MMouse(dx, dy, 0, 0);
          if IsUpTextMultiCustom(['ank', 'Bo', 'ot']) then
          begin
            GetMousePos(dx, dy);
            Mouse(dx, dy, 0, 0, False);
            if ChooseOption('uickly') then
            begin
              MarkTime(Mark2);
              repeat
                Wait(10);
                if TimeFromMark(Mark2) > 20000 then
                begin
                  WriteLn('Couldn''t find the bank. Exiting');
                  FreeBitmap(TheCounter);
                  Exit;
                end;
              until BankScreen or PinScreen;
            end;
            if (Length(Players) > 0) then
              if (Players[CurrentPlayer].Pin <> '') then
                InPin(Players[CurrentPlayer].Pin);
            Result := True;
            FreeBitmap(TheCounter);
            Exit;
          end;
        end;
        Wait(100);
        tol := tol + 4;
        if tol >= 20 then
        begin
          tol := 1;
          accthres := accthres - 0.1;
          if accthres < 0.2 then
          begin
            WriteLn('Couldn''t find the bank. Exiting');
            FreeBitmap(TheCounter);
            Exit;
          end;
        end;
      until TimeFromMark(Mark3) > 60000;
      FreeBitmap(TheCounter);
    end;

    {*******************************************************************************
    function FindBank(TheBank: String): Boolean;
    By: WT-Fakawi and modified by Ron
    Description: Finds and opens any given bank in the free world.
    If the MM DTM is found it will find and open the bank.
    Valid arguments are:
    'feb' (Falador East Bank)
    'fwb' (Falador West Bank)
    'veb' (Varrock East Bank)
    'vwb' (Varrock West Bank)
    'db'  (Draynor Bank)
    'akb' (Al-Kharid Bank)
    *******************************************************************************}


    function FindBank(TheBank: string): Boolean;
    var
      bx, by, TheDTM: Integer;
      WhichAngle: Extended;
    begin
      TheBank := LowerCase(TheBank);
      case TheBank of
        'feb': TheDTM := DTMFromString('78DA63AC67626088634001FFFFFD63F80FA41' +
            '9416C2060AC01AA4987C83141D5FCF9C3C4C0055503028CAD44A8' +
            'E924AC0600131E11B5');
        'fwb': TheDTM := DTMFromString('78DA636C676260086540038C0CFFC12403C37' +
            'F206004A98986C8304155FCF9C3C4C0055503D6D14C849A6EC26A' +
            '009F5A0EA1');
        'db': TheDTM := DTMFromString('78DA636C67626008644001FFFFFD63F80FA41' +
            '9416C2060AC01AAF182C8B140D5FCF9C304A619A17CB09A204C35' +
            '22E86AC2F09B0300F8811153');
        'veb': TheDTM := DTMFromString('78DA63EC61626008624001FFFFFD63F80FA41' +
            '9416C2060EC00AA8982C83141D5FCF9C3C4C0055503028C138850' +
            'D343580D00122211A9');
        'vwb': TheDTM := DTMFromString('78DA63EC606260B066C000FF819811440301E' +
            '354A01A3B88381354FECF1F260611A81A1000AB3125428D2E7E35' +
            '0087F80E5E');
        'akb': TheDTM := DTMFromString('78DA636C606260F06140019D9D710CFF81342' +
            '310FF0702C652A01A37881C1354CD9F3F4C0C5C5035200056E345' +
            '841A3FFC6A002A3B0F97');
        else
        begin
          srl_Warn('FindBank', 'Invalid bank name', warn_Warning);
          Exit;
        end;
      end;

      if FindDtmRotated(TheDTM, bx, by, MMX1, MMY1, MMX2, MMY2, Radians(-30), Radians(30), 0.05,
            WhichAngle) then
          begin
            Mouse(bx, by, 0, 0, True);
    //        FTWait(8);
            FFlag(0);
            if OpenBankQuiet(TheBank) then
            begin
              FixBank;
              Result := True;
              FreeDTM(TheDTM);
              Exit;
            end
            else Result := False;
          end
          else Result := False;
      FreeDTM(TheDTM);
    end;
    {*******************************************************************************
    function CloseBank: Boolean;
    By: Starblaster100
    Description: Closes the bank window - Tries twice before exiting
    *******************************************************************************}


    function CloseBank: Boolean;
    var
      i, Timer, Points: Integer;
    begin
      if BankScreen then
      begin
        MarkTime(Timer);
        repeat
          Mouse(483, 28, 10, 12, True);
          for i := 0 to 30 do
          begin
            if not bankscreen then
              break;
            Wait(100);
          end;
        until(Points < 170)or(TimeFromMark(Timer) > 8000)
      end;
    end;

    {*******************************************************************************
    function OpenBankGlass(WhichBank: String; ChangeCompass, ChangeAngle: Boolean): Boolean;
    By: Wizzup? and modified by Ron
    Description: Opens the bank.
    Valid arguments are:
    'feb' (Falador East Bank)
    'fwb' (Falador West Bank)
    'veb' (Varrock East Bank)
    'vwb' (Varrock West Bank)
    'db'  (Draynor Bank)
    'akb' (Al-Kharid Bank)
    *******************************************************************************}


    function OpenBankGlass(WhichBank: string; ChangeCompass, ChangeAngle: Boolean): Boolean;
    var
      OBC: TPoint;
      c, Speed: Integer;
    begin
      Speed := GetColorToleranceSpeed;
      ColorToleranceSpeed(2);
      if ChangeAngle then SetAngle(True);
      if ChangeCompass then
      begin
        c := Random(2);
        case WhichBank of
          'feb', 'fwb', 'veb': if c = 0 then MakeCompass('N') else MakeCompass('S');
          'akb', 'db', 'eb', 'vwb': if c = 0 then MakeCompass('E') else MakeCompass('W');
        end;
      end;
      if FindColorTolerance(OBC.x, OBC.y, 10070458, MSX1, MSY1, MSX2, MSY2, 10) then
      begin
        MMouse(OBC.x, OBC.y, 4, 4);
        if IsUpTextMultiCustom(['nk', 'bo', 'ot']) then
        begin
          Mouse(OBC.x, OBC.y, 0, 0, False);
          Wait(100);
          ChooseOption('uickly');
          FFlag(0);
          Wait(2000 + Random(500));
          if (Length(Players) > 0) then
            if (Players[CurrentPlayer].Pin <> '') then
              InPin(Players[CurrentPlayer].Pin);
          Result := (BankScreen) or (PinScreen);
        end;
      end else
        if FindObj(OBC.x, OBC.y, 'ank', 10070458, 20) then
        begin
          Mouse(OBC.x, OBC.y, 0, 0, False);
          Wait(50);
          ChooseOption('uickly');
          FFlag(0);
          Wait(2000 + Random(500));
          if (Length(Players) > 0) then
            if (Players[CurrentPlayer].Pin <> '') then
              InPin(Players[CurrentPlayer].Pin);
          Result := (BankScreen) or (PinScreen);
        end;
      ColorToleranceSpeed(Speed);
    end;

    {*******************************************************************************
    function OpenBankFast(Location: String): Boolean;
    By: Wizzup? and Nielsie95
    Description: Opens the bank.
    Valid arguments are:
        'akb', 'al kharid', 'lb', 'lumbridge', 'veb', 'varrock east', 'vwb',
        'varrock west', 'feb', 'falador east', 'fwb', 'falador west', 'db', 'draynor',
        'eb', 'edgeville bank'
    *******************************************************************************}


    function OpenBankFast(Location: String): Boolean;
    var
      x, y, i, l, c, z: Integer;
      Info: TIntegerArray;
      Booths, t: TPointArray;
    begin
      Wait(400);
      case LowerCase(Location) of
        'akb', 'al kharid': Info := [MSCX, MSCY, 7969203, 25, 1];
        'lb', 'lumbridge': Info := [MSCX, MSCY, 4807788, 10, 1];
        'veb', 'varrock east': Info := [MSCX, MSCY, 2971236, 10, 1];
        'vwb', 'varrock west': Info := [270, 270, 5689318, 25, 1];
        'feb', 'falador east': Info := [MSCX, MSCY + 50, 4612728, 14, 1];
        'fwb', 'falador west': Info := [MSCY, MSCY, 4612728, 14, 1];
        'db', 'draynor': Info := [MSCX, MSCY, 605006, 4, 1];
        'eb', 'edgeville bank': Info := [MSCX + 50, MSCY, 3230295, 9, 2];
        else
        begin
          srl_Warn('OpenBankFast', 'Unknown bank: '+Location, warn_AllVersions);
          Exit;
        end;
      end;

      MakeCompass('n');
      z := GetColorToleranceSpeed;
      ColorToleranceSpeed(Info[4]);
      FindColorsSpiralTolerance(Info[0], Info[1], Booths, Info[2], MSX1, MSY1, MSX2, MSY2, Info[3]);
      ColorToleranceSpeed(z);
      SetArrayLength(t, 0);
      t := Booths;
      SetArrayLength(Booths, 0);
      Booths := ReArrangeAndShortenArray(t, 14);
      l := GetArrayLength(Booths) -1;
      for i := 0 to l do
      begin
        if (not LoggedIn) or BankScreen or PinScreen then
          Break;
        if (LowerCase(Location) = 'vwb') or (LowerCase(Location) = 'varrock west') then
        begin
          Booths[i].X := Booths[i].X + 5;
          Booths[i].Y := Booths[i].Y - 20;
        end;
        MMouse(Booths[i].X, Booths[i].Y, 3, 3);
        Wait(75 + Random(75));
        if IsUpText('ooth') Then
        begin
          GetMousePos(x, y);
          Mouse(x, y, 0, 0, False);
          Wait(70 + Random(75));
          if ChooseOption('uickly') then
          begin
            FFLag(0);
            MarkTime(c);
            repeat
              Wait(100);
            until (BankScreen) or (PinScreen) or (TimeFromMark(c) > 3000);
            if (Length(Players) > 0) then
              if (Players[CurrentPlayer].Pin <> '') then
                InPin(Players[CurrentPlayer].Pin);
          end;
        end;
      end;
      Result := (BankScreen) or (PinScreen);
    end;

    {*******************************************************************************
    function OpenBank(WhichBank: String, ChangeCompass, ChangeAngle: Boolean): Boolean;
    by: SRL Development Team
    Description: Opens the bank if possible.
    Valid arguments are:
    'feb' (Falador East Bank)
    'fwb' (Falador West Bank)
    'veb' (Varrock East Bank)
    'vwb' (Varrock West Bank)
    'db'  (Draynor Bank)
    'akb' (Al-Kharid Bank)
    'lb'  (Lumbridge Bank)
    *******************************************************************************}


    function OpenBank(WhichBank: String; ChangeCompass, ChangeAngle: Boolean): Boolean;
    begin
      if not BankScreen then
      begin
        Result := True;
        if LowerCase(WhichBank) <> 'eb' then
          if OpenBankFast(WhichBank) then Exit;
        if LowerCase(WhichBank) <> 'lb' then
        begin
          if (Random(11) > 5) then
          begin
            if not OpenBankGlass(WhichBank, ChangeCompass, ChangeAngle) then
              if not OpenBankQuiet(WhichBank) then
                Result := False;
          end else
          begin
            if not OpenBankQuiet(WhichBank) then
              if not OpenBankGlass(WhichBank, ChangeCompass, ChangeAngle) then
                Result := False;
          end;
          if not Result then
            if FindBank(WhichBank) then
              Result := True;
        end;
      end else
        Result := True;
    end;

    Fixed FixBank, BankScreen, Withdraw, Deposit, FixBankTab, SearchBank and all the BankIndex stuff.
    EDIT: Fixed CloseBank; and a bug in Withdraw.



    The best way to contact me is by email, which you can find on my website: http://wizzup.org
    I also get email notifications of private messages, though.

    Simba (on Twitter | Group on Villavu | Website | Stable/Unstable releases
    Documentation | Source | Simba Bug Tracker on Github and Villavu )


    My (Blog | Website)

  2. #2
    Join Date
    Oct 2007
    Location
    If (Online) then Loc := ('On comp') else Loc := ('Somewhere else!');
    Posts
    2,020
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    kwl guys

  3. #3
    Join Date
    Jan 2008
    Location
    NC, USA.
    Posts
    4,429
    Mentioned
    0 Post(s)
    Quoted
    4 Post(s)

    Default

    Do we have to get a new worlds list because of the update? My SCSS wont load any more
    Quote Originally Posted by irc
    [00:55:29] < Guest3097> I lol at how BenLand100 has become noidea
    [01:07:40] <@BenLand100> i'm not noidea i'm
    [01:07:44] -!- BenLand100 is now known as BenLand42-
    [01:07:46] <@BenLand42-> shit
    [01:07:49] -!- BenLand42- is now known as BenLand420
    [01:07:50] <@BenLand420> YEA

  4. #4
    Join Date
    Apr 2007
    Location
    Colchester, UK
    Posts
    1,220
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    this new bank screen can be great for autoing, the search feature means you can check for specific items, so no more not finding axes at they are off the bank screen.

    what do you guys think?

  5. #5
    Join Date
    Apr 2007
    Location
    Perth, Australia
    Posts
    3,926
    Mentioned
    3 Post(s)
    Quoted
    2 Post(s)

    Default

    Quote Originally Posted by bobzilla69 View Post
    this new bank screen can be great for autoing, the search feature means you can check for specific items, so no more not finding axes at they are off the bank screen.

    what do you guys think?
    Thats a good idea. Perhap we could make a SearchBank function or something.

  6. #6
    Join Date
    Apr 2007
    Location
    Colchester, UK
    Posts
    1,220
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by ZephyrsFury View Post
    Thats a good idea. Perhap we could make a SearchBank function or something.

    glad to hear u like my idea. [wishes] if only i get credit for idea[/wishes]

    in my opinion it seems like they are making it easier for us to auto, yeh the graphics and other updates put us down for a bit but some of there changes seem to make other tasks much easier.

  7. #7
    Join Date
    Feb 2006
    Location
    Amsterdam
    Posts
    13,692
    Mentioned
    146 Post(s)
    Quoted
    130 Post(s)

    Default

    First post.
    Zeph is writing the search functions.



    The best way to contact me is by email, which you can find on my website: http://wizzup.org
    I also get email notifications of private messages, though.

    Simba (on Twitter | Group on Villavu | Website | Stable/Unstable releases
    Documentation | Source | Simba Bug Tracker on Github and Villavu )


    My (Blog | Website)

  8. #8
    Join Date
    Jun 2007
    Location
    Liverpool ,Nsw,Australia
    Posts
    740
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Fcuk Wizzup?....You taken a whole lot of dog tranquilizer? Thats was fcuking ownage fast
    Quote Originally Posted by Darkmage View Post
    I got 2 questions'
    #1. When i run the script will it automatically pick up the mouse and move?

  9. #9
    Join Date
    Feb 2006
    Location
    Amsterdam
    Posts
    13,692
    Mentioned
    146 Post(s)
    Quoted
    130 Post(s)

    Default

    Fixed Deposit.



    The best way to contact me is by email, which you can find on my website: http://wizzup.org
    I also get email notifications of private messages, though.

    Simba (on Twitter | Group on Villavu | Website | Stable/Unstable releases
    Documentation | Source | Simba Bug Tracker on Github and Villavu )


    My (Blog | Website)

  10. #10
    Join Date
    Jan 2008
    Location
    NC, USA.
    Posts
    4,429
    Mentioned
    0 Post(s)
    Quoted
    4 Post(s)

    Default

    And the race is over! What the hell did you win? I agree with stricker lol
    Is it completely done?
    Quote Originally Posted by irc
    [00:55:29] < Guest3097> I lol at how BenLand100 has become noidea
    [01:07:40] <@BenLand100> i'm not noidea i'm
    [01:07:44] -!- BenLand100 is now known as BenLand42-
    [01:07:46] <@BenLand42-> shit
    [01:07:49] -!- BenLand42- is now known as BenLand420
    [01:07:50] <@BenLand420> YEA

  11. #11
    Join Date
    Feb 2006
    Location
    Amsterdam
    Posts
    13,692
    Mentioned
    146 Post(s)
    Quoted
    130 Post(s)

    Default

    Quote Originally Posted by noidea View Post
    And the race is over! What the hell did you win? I agree with stricker lol
    Is it completely done?
    Except for the tab and search, yes. But that will be done in ~15 mins.



    The best way to contact me is by email, which you can find on my website: http://wizzup.org
    I also get email notifications of private messages, though.

    Simba (on Twitter | Group on Villavu | Website | Stable/Unstable releases
    Documentation | Source | Simba Bug Tracker on Github and Villavu )


    My (Blog | Website)

  12. #12
    Join Date
    Jan 2008
    Posts
    33
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    thats FANTASTIC!. Testing it right now (:.

    edit: it detected the bank, but it couldnt/didnt close it. Seems like its clicking a little too far up and right (when it try's to hit the x).

  13. #13
    Join Date
    Dec 2006
    Posts
    908
    Mentioned
    1 Post(s)
    Quoted
    17 Post(s)

    Default

    That seems something easy to fix....

    Anyways, this new update could be an awsome for autoing!

    EDIT:

    WAIT! So the whole time, you guys used BITMAPS to find the bank in QpenBankQuiet? SO does that mean i can do that to the Camelot Bank too?

  14. #14
    Join Date
    Jun 2007
    Location
    Greenville, SC
    Posts
    1,149
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Wow... u guys are AMAZING! So quick... yet so perfect.

  15. #15
    Join Date
    Feb 2006
    Location
    Amsterdam
    Posts
    13,692
    Mentioned
    146 Post(s)
    Quoted
    130 Post(s)

    Default

    Added FixBankTab;
    If you didn't read this post, update your Bank.scar again from the first post.
    Not a crucial fix, but nice to have.



    The best way to contact me is by email, which you can find on my website: http://wizzup.org
    I also get email notifications of private messages, though.

    Simba (on Twitter | Group on Villavu | Website | Stable/Unstable releases
    Documentation | Source | Simba Bug Tracker on Github and Villavu )


    My (Blog | Website)

  16. #16
    Join Date
    Mar 2007
    Posts
    4,810
    Mentioned
    3 Post(s)
    Quoted
    3 Post(s)

    Default

    Wow very efficient guys. Well Done!

  17. #17
    Join Date
    Apr 2007
    Location
    Perth, Australia
    Posts
    3,926
    Mentioned
    3 Post(s)
    Quoted
    2 Post(s)

    Default

    Added SearchBank (not BankSearch.. Wizzup)... anyway have fun...

  18. #18
    Join Date
    Jul 2007
    Location
    Norway.
    Posts
    1,938
    Mentioned
    3 Post(s)
    Quoted
    0 Post(s)

    Default

    UUh. Not to hi-jack, but ..
    As you probably know, I've made a bankopener, and I was thinking.
    Should it be added to SRL's Bank.scar? You know, since it's .. Progressive and stuff.

    I'm just asking for your opinions..

    E: Uhm, if added, remember that it is not fully up-to-date, but I don't know if it works or not.

  19. #19
    Join Date
    Feb 2006
    Location
    Amsterdam
    Posts
    13,692
    Mentioned
    146 Post(s)
    Quoted
    130 Post(s)

    Default

    I agree, SRL's Bank Finding could use an update. But I think OpenBankFast is quite alright... Maybe fix it, add less tolerance?
    I could also write a TPA sorting algorithm for Bank Opening...



    The best way to contact me is by email, which you can find on my website: http://wizzup.org
    I also get email notifications of private messages, though.

    Simba (on Twitter | Group on Villavu | Website | Stable/Unstable releases
    Documentation | Source | Simba Bug Tracker on Github and Villavu )


    My (Blog | Website)

  20. #20
    Join Date
    Mar 2007
    Location
    <3
    Posts
    2,683
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Thänk y0u v3ru mu<e ! Qu1ckn3ss

  21. #21
    Join Date
    Apr 2007
    Location
    Perth, Australia
    Posts
    3,926
    Mentioned
    3 Post(s)
    Quoted
    2 Post(s)

    Default

    Quote Originally Posted by Wizzup? View Post
    I agree, SRL's Bank Finding could use an update. But I think OpenBankFast is quite alright... Maybe fix it, add less tolerance?
    I could also write a TPA sorting algorithm for Bank Opening...
    OpenBankFast was fine when I fixed Lummy, Al-Kharid and Draynor bank the other day AFAIK. Didn't test the other banks though but they should be OK.

  22. #22
    Join Date
    Jan 2008
    Posts
    33
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    will you fix the bank closing too ?

    btw: another system update in about a minute ( :

    AHHHHG, IAM SORRY! : the banking is totally fine; its just that my script uses closewindow; which gotta be fixed

  23. #23
    Join Date
    Dec 2006
    Posts
    65
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Didn't even notice the bank screen had been updated, and you guys updated SRL already <3!

  24. #24
    Join Date
    Feb 2006
    Location
    Amsterdam
    Posts
    13,692
    Mentioned
    146 Post(s)
    Quoted
    130 Post(s)

    Default

    Quote Originally Posted by ZephyrsFury View Post
    OpenBankFast was fine when I fixed Lummy, Al-Kharid and Draynor bank the other day AFAIK. Didn't test the other banks though but they should be OK.
    Open VEB when you are standing outside the bank.



    The best way to contact me is by email, which you can find on my website: http://wizzup.org
    I also get email notifications of private messages, though.

    Simba (on Twitter | Group on Villavu | Website | Stable/Unstable releases
    Documentation | Source | Simba Bug Tracker on Github and Villavu )


    My (Blog | Website)

  25. #25
    Join Date
    Jun 2007
    Location
    south park
    Posts
    1,160
    Mentioned
    0 Post(s)
    Quoted
    62 Post(s)

    Default

    so this goes over the bank in the srl folder?
    http://www.youtube.com/user/YoHoJoSRL
    Good scripting guides on youtube
    Formerly known as (djcheater)

Page 1 of 2 12 LastLast

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Do DTM's work in Bank screen?
    By !bezo! in forum OSR Help
    Replies: 7
    Last Post: 09-04-2007, 02:10 PM
  2. bank screen update help
    By runekingex in forum RS has been updated.
    Replies: 1
    Last Post: 07-07-2007, 06:14 PM
  3. Loaded Bank Screen, but cant.....
    By passiondrive in forum OSR Help
    Replies: 2
    Last Post: 06-12-2007, 09:39 PM
  4. Update: New Login Screen
    By YoHoJo in forum RS has been updated.
    Replies: 0
    Last Post: 11-22-2006, 12:42 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
  •