Results 1 to 17 of 17

Thread: Erke's Unf and Pot maker!

  1. #1
    Join Date
    Dec 2011
    Posts
    189
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default Erke's Unf and Pot maker!

    Welcome to my first script!

    So heres my first script, it is not the most beautiful work out there but it will run for 6hrs!

    Featuring:
    AntiBan
    InGame Proggy
    FailSafe
    (Soon) SRL stats!

    Setup:
    Place the player at the SW bankChest with the ingredients in the first and second bank slot (You can change this by Constants in the script)

    Proggy:
    Short proggy of me making some Ash Potion (u)

    ***************Unf/Pot Maker****************
    *****************By Erke*******************
    Running for: 19 Minutes and 27 Seconds
    Unfs/Pots made: 588
    Unf/Pots Made/Hour: 1813
    Experience Gained: 0
    Experience/Hour: 0
    Antibans: 22
    *******************************************

    The Script:
    Simba Code:
    program UnfPotMakerByErke;
    {$DEFINE SMART}
    {$i srl/srl.simba}

    Const

      HerbRow = 0;   //Herbs in the first bankslot
      HerbCol = 0;

      VialRow = 0;  //Vials in second bankslot
      VialCol = 1;

      Unf = True;   //True if you want to make Unfs
      Pot = False;    //True if you want to make Pots

      AntiBanChance = 20;

    var
      StartingXP, PotsOrUnfsMade, AntiBans: integer;

    Procedure DeclarePlayers;
    begin
      HowManyPlayers := 1;
      NumberOfPlayers(HowManyPlayers);
      CurrentPlayer := 0;
      Players[0].Name := '';
      Players[0].Pass := '';
      Players[0].Nick := '';
      Players[0].Pin  := '';
      Players[0].Active:=True;
    end;

    function Open_Banks(Location: Integer): Boolean;
    var
      bo, i, l, c, z: Integer;
      Info: TVariantArray;
      Chests: TPointArray;
      AChests: T2DPointArray;
      UpText: TStringArray;
      B: TBox;
    begin
      result := false;
      if (not LoggedIn) then
        Exit;
      if BankScreen or PinScreen then
      begin
        Result := True;
        Exit;
      end;
      UpText := ['Bank', 'chest', 'nk che'];
                       {              0          1         2        3     4     5      6       7       8   9     10   }
      case Location of {            Sort X     Sort Y     Color    Tol   Hue   Sat   Count  SplitTPA?  W   H   Compass}
        SRL_BANK_SW :      Info := [MSCX     , MSCY,      10198185, 21,   0.08, 0.25,  50,   True ,   10, 10,   's'];
        SRL_BANK_CW :      Info := [MSCX     , MSCY,      10198185, 21,   0.08, 0.25,  50,   True ,   10, 10,   'n'];
        SRL_BANK_B  :      Info := [MSCX     , MSCY,      10198185, 21,   0.08, 0.25,  50,   True ,   10, 10,   'n'];
        SRL_BANK_GG :      Info := [MSCX     , MSCY,      5921630,  9 ,   0.47, 0.08,  50,   True ,   10, 10,   'n'];

        else
        begin
          srl_Warn('OpenBankChestEdge', 'Unknown bank: '+IntToStr(Location), warn_AllVersions);    //will output loc as int (no longer string)
          Exit;
        end;
      end;

      MakeCompass(Info[10]);
      //SetAngle(SRL_ANGLE_HIGH);  //??
      z := GetColorToleranceSpeed;
      ColorToleranceSpeed(2);
      SetColorSpeed2Modifiers(Info[4], Info[5]);

      FindColorsSpiralTolerance(Info[0], Info[1], Chests, Info[2], MSX1, MSY1, MSX2, MSY2, Info[3]);
      ColorToleranceSpeed(z);
      SetColorSpeed2Modifiers(0.2, 0.2);

      { Split to ATPA. }
      if Info[7] then
        AChests := SplitTPA(Chests, 3)
      else
        AChests := TPAtoATPA(Chests, 10);

      Chests := [];

      { Go through ATPA. }
      l := GetArrayLength(AChests) -1;
      for i := 0 to l do
      begin
        { Too few pixels. }
        if (Length(AChests[i]) < Info[6]) then
          Continue;

        { Too small TPA bounds. }
        B := GetTPABounds(AChests[i]);
        If ((B.X2 - B.X1) < Info[8]) Or ((B.Y2 - B.Y1) < Info[9]) Then
          Continue;

        Inc(bo);
        SetArrayLength(Chests, bo);
        Chests[bo-1] :=  MiddleBox(GetTPABounds(AChests[i]));

      end;

      SortTPAFrom(Chests, Point(Info[0], Info[1]));

      l := GetArrayLength(Chests) -1;
      for i := 0 to l do
      begin

        MMouse(Chests[i].X, Chests[i].Y, 3, 3);
        if WaitUpTextMulti(UpText, 1000) Then
        begin
          GetMousePos(Chests[i].X, Chests[i].Y);
          Case Random(9) of
            0..7: Mouse(Chests[i].X, Chests[i].Y, 0, 0, mouse_left);
            8: begin
                 Mouse(Chests[i].X, Chests[i].Y, 0, 0, mouse_right);
                 if not WaitOptionMulti(['Use', 'se'], 1000) then Exit;
            end;
          end;
          FFLag(0);
          MarkTime(c);
          repeat
            Wait(100);
          until (BankScreen) or (PinScreen) or (TimeFromMark(c) > 10000);
          Wait(Random(300));
          if (HowManyPlayers > 0) then
            if (Players[CurrentPlayer].Pin <> '') then
              InPin(Players[CurrentPlayer].Pin);
          Result := (BankScreen) or (PinScreen);
          if (Result) then Exit;
        end;
      end;
    end;


    procedure SetupPlayer;
    begin
      SetAngle(0);
      MakeCompass('S');
      GameTab(tab_inv)
    end;

    Function XPPerHour(runtime,gained:integer):String;   //Fwd Motion
    begin
      result:=inttostr(Round((gained * 3600) / (runtime / 1000)));
    end;

    Function GainedXP:integer;     //Fwd Motion
    begin
      result:= GetXPBarTotal - startingxp;
    end;

    procedure Antiban;     //Based on Shut's AntiBan
    var
      Chance: Integer;
    begin
      Chance:= Random(100)+1;
      if Chance<=AntibanChance then
        case Random(100)+1 of
          1..20: begin
                   HoverSkill('Herblore', false);
                   Wait(1000+Random(500));
                   GameTab(tab_Inv);
                   antibans := antibans + 1;
                 end;
          21..40:
            begin
              PickUpMouse;
              antibans := antibans + 1;
            end;
          41..60:
            begin
              RandomMovement;
              antibans := antibans + 1;
            end;
          61..80:
            begin
              BoredHuman;
              antibans := antibans + 1;
            end;
          81..100:
            begin
              ExamineInv;
              antibans := antibans + 1;
            end;
        end;
      ChooseOption('ancel');
    end;

    function Open_Bank: boolean;
    begin
      if Open_Banks(SRL_BANK_SW) then
      Result:= true;
    end;

    procedure WithDrawStuff;
    begin
      if BankScreen then
      begin
        Withdraw(HerbCol, HerbRow, 14);
        Wait(100 + random(50));
        Withdraw(VialCol, VialRow, 14);
        Wait(100 + random(50));
        CloseBank;
      end else
      Open_Bank;
    end;

    procedure DepositStuff;
    begin
      if BankScreen then
        begin
          DepositAll;
          PotsOrUnfsMade := PotsOrUnfsMade + 14
        end else
        Open_Bank;
    end;

    procedure MakeStuff;
    begin
      case random(3) of
        0 : begin
              InvMouse(13, 1);
              Wait(200 + random(50));
              InvMouse(17, 1);
            end;
        1 : begin
              InvMouse(14, 1);
              Wait(200 + random(50));
              InvMouse(15, 1);
            end;
        2 : begin
              InvMouse(14, 1);
              Wait(200 + random(50));
              InvMouse(18, 1);
            end;
      end;
      Wait(900 + random(100));
      MMouse(257, 430, 13, 13);
      if WaitUptext('ake', 1000) then
        begin
          ClickMouse2(true);
          if Unf then
          begin
            Wait(8200 + random(500));
          end;
          if Pot then
          begin
            Wait(16000 + random(500));
          end;
        end else
        begin
          WriteLn('Something went wrong!');
          TerminateScript;
        end;
    end;

    Procedure Proggy;      //Based on Fwd Motion's Proggy
    begin
      ClearDebug;
      Writeln('***************Unf/Pot Maker***************');
      Writeln('*****************By Erke*******************');
      Writeln('Running for: ' + TimeRunning);
      Writeln('Unfs/Pots made: ' + inttostr(PotsOrUnfsMade));
      Writeln('Unf/Pots Made/Hour: ' + XPPerHour(GetTimeRunning, PotsOrUnfsMade));
      Writeln('Experience Gained: ' + inttostr(GainedXP));
      Writeln('Experience/Hour: ' + XPPerHour(GetTimeRunning, GainedXP));
      Writeln('Antibans: ' + inttostr(AntiBans));
      Writeln('*******************************************');
    end;

    begin
      Smart_Server := 117;
      Smart_Members := True;
      Smart_Signed := True;
      Smart_SuperDetail := False;
      SetUpSRL;
      ActivateClient;
      DeclarePlayers;
      Wait(1000);
      LoginPlayer;

      SetupPlayer;
      if not(IsXPBarOpen) then
        ToggleXPBar(True);
      startingxp:= GetXPBarTotal;
      writeln(GetXPBarTotal);
      Open_Bank;
      DepositAll;
      repeat
        WithDrawStuff;
        MakeStuff;
        AntiBan;
        Open_Bank;
        DepositStuff;
        Proggy;
      until (not LoggedIn)
    end.

    Please leave some feedback, would be awesome to hear what you guys think about my first RuneScape Script!

    Versions:
    Version 0.1: Initial release
    Version 0.2: Copied the OpenBankChestEdge function from SRL but edited it to spin the camera to South instead of West, should make the failsafe stop failing!
    Last edited by Erke; 02-21-2012 at 09:10 PM.

  2. #2
    Join Date
    Dec 2011
    Posts
    1,162
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Hmmm looks nice erke I'll have to run it later!

  3. #3
    Join Date
    Dec 2011
    Posts
    189
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by laakerules View Post
    Hmmm looks nice erke I'll have to run it later!
    Yay thanks! Do you wanna come to my 99str party? For now you are the only one invited

  4. #4
    Join Date
    Dec 2011
    Posts
    72
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Niceee, I will try it when i come back home from my Gf's. I would use it now, but i really rely on my bots not stopping which is SuperUser's bots. But he is limited to 4 unfs pots. So if youres is running flawlessy, I'll be switching over to yours

  5. #5
    Join Date
    Dec 2011
    Posts
    189
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by tight butts View Post
    Niceee, I will try it when i come back home from my Gf's. I would use it now, but i really rely on my bots not stopping which is SuperUser's bots. But he is limited to 4 unfs pots. So if youres is running flawlessy, I'll be switching over to yours
    Nice to see you will try it out, ive noticed that the failsafe sometimes fails (irony lol) so if it stops for you then just make sure you have a heavy bulk of resouces and edit the failsafe out and run it. Will hopefully get a better failsafe idea soon, it shouldnt fuck anything up so its ok to run it withouth the failsafe if you have enough resources for it to use

  6. #6
    Join Date
    Jan 2012
    Posts
    28
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    It works great while it is working , but it takes the stuff out of the bank clicks each of the items and when you have to click to make all it just stops right on theres and says this

    ***************Unf/Pot Maker***************
    *****************By Erke*******************
    Running for: 3 Minutes and 6 Seconds
    Unfs/Pots made: 98
    Unf/Pots Made/Hour: 1896
    Experience Gained: 11515
    Experience/Hour: 222870
    Antibans: 0
    *******************************************
    Something went wrong!
    Successfully executed.
    Last edited by madmatt9797; 02-20-2012 at 07:46 PM.

  7. #7
    Join Date
    Dec 2011
    Posts
    189
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by madmatt9797 View Post
    It works great while it is working , but it takes the stuff out of the bank clicks each of the items and when you have to click to make all it just stops right on theres and says this

    ***************Unf/Pot Maker***************
    *****************By Erke*******************
    Running for: 3 Minutes and 6 Seconds
    Unfs/Pots made: 98
    Unf/Pots Made/Hour: 1896
    Experience Gained: 11515
    Experience/Hour: 222870
    Antibans: 0
    *******************************************
    Something went wrong!
    Successfully executed.
    Thats cuz of a very poor failsafe made by me, ill try to replace it tomorrow

  8. #8
    Join Date
    Feb 2012
    Posts
    53
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    thank you erke for doing this, it was very needed bcuz none else working

  9. #9
    Join Date
    Jan 2012
    Posts
    28
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    Quote Originally Posted by Erke View Post
    Thats cuz of a very poor failsafe made by me, ill try to replace it tomorrow
    Sounds good , im still using it. when it does that i just press start quickly to restart it up again so its not the biggest problem ever , but would make it easier so i could just afk. its working great atm besides that problem , once its fixed itll be making easily 2k pots per hour. great script!

  10. #10
    Join Date
    Feb 2012
    Posts
    53
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    good script but stops after made like 100-200 pots

  11. #11
    Join Date
    Dec 2011
    Posts
    189
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    What do you guys think? I could make DTM's but then cant you have multiply herbs or vials/pots in the same tab

  12. #12
    Join Date
    Dec 2011
    Posts
    72
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    It keeps right clicking on people at the bank if there is alot of people.
    Also, when its doing the bored human, or random movement antiban, It does it, then clicks bank, but doesn't bank all items, and tries to withdraw herbs and vial and continue to try to make it, then it stops.
    Last edited by tight butts; 02-21-2012 at 08:30 AM.

  13. #13
    Join Date
    Dec 2011
    Posts
    189
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by tight butts View Post
    It keeps right clicking on people at the bank if there is alot of people.
    Also, when its doing the bored human, or random movement antiban, It does it, then clicks bank, but doesn't bank all items, and tries to withdraw herbs and vial and continue to try to make it, then it stops.
    Feels very odd cuz that has never happend to me :/ Uploading a version with a unfailing failsafe now however

  14. #14
    Join Date
    Dec 2011
    Posts
    189
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Could I bump my new version? I think I can =P

  15. #15
    Join Date
    Dec 2011
    Posts
    189
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Just noticed that my username, password and PIN was in the last version... It as uploaded for over 8hours and nobody has even downloaded the latest version... was that luck or does God watch over me? Will reupload new version tomorrow!

  16. #16
    Join Date
    Nov 2011
    Posts
    93
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Erke this is the best unf maker that i've run.In long time.thank you for doing this!Will send proggy...

  17. #17
    Join Date
    Mar 2012
    Posts
    690
    Mentioned
    2 Post(s)
    Quoted
    40 Post(s)

    Default

    Your best proggy ever...

    ***************Unf/Pot Maker***************
    *****************By Erke*******************
    Running for: 10 Minutes and 23 Seconds
    Unfs/Pots made: 322
    Unf/Pots Made/Hour: 1860
    Experience Gained: 190707
    Experience/Hour: 1101998
    Antibans: 5
    *******************************************

Thread Information

Users Browsing this Thread

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

Posting Permissions

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