Page 1 of 3 123 LastLast
Results 1 to 25 of 53

Thread: Updated Guide to Making a PowerMiner

  1. #1
    Join Date
    Feb 2007
    Location
    South East England
    Posts
    2,906
    Mentioned
    2 Post(s)
    Quoted
    8 Post(s)

    Default Updated Guide to Making a PowerMiner

    Original my PLM found here: http://www.villavu.com/forum/showthread.php?t=24726


    If you liked my tutorial please Rep++ or Rank The Thread. If you actually read it, please comment!


    Credits to PLM for providing the outline to this tutorial.

    This needed updating as there was alot of errors on that Tutorial, and I feel it is time to get a new one out there for people to use to stop people asking about obsolete items of errors they recieve.

    Anyway....

    Welcome to Torrent's Updated Power Miner Guide!

    This Tutorial will cover:
    - AntiBan
    - AntiRandoms
    - Mining
    - FailSafes
    - Constants
    - Variables
    - Loops
    - Declare Players


    To Start we should name the the program that we are going to use, calling it something significant to the program you are going to make:

    SCAR Code:
    program MyFirstPowerMiner;

    Then you HAVE to include this part, as it controls everything that we need to use in this script (FindObjCustom, etc.)

    SCAR Code:
    {.include SRL/SRL.scar}

    The we include our constants. Constants are basically what they say they are, something that is ALWAYS the same, like RockColours, TreeColours, SMART Worlds, etc.

    SCAR Code:
    const
    RockColour1= 111111;
    RockColour2= 222222;

    These Rock Colours would be picked from the Rock You wish to mine, so Iron and Rune would be different, The example colours are obviousley false for any type of rock [Prove me wrong on that one ]

    Then we have to declare our variables, not variables again explain themselves, something that is a variable, can constantly change. The variables in this case are the x and the y, the co-ordinates on the game screen. It is an "integer" as they are co-ordinates, which are numerical. Tries will be explained later.

    SCAR Code:
    var x, y, Tries: integer;

    Then we have our first procedure. I will explain the procedure after we see the overview.

    SCAR Code:
    procedure DeclarePlayers;
    begin

         HowManyPlayers := 1;  
         NumberOfPlayers(HowManyPlayers);
         CurrentPlayer:= 0

         Players[0].Name   := 'Username';
         Players[0].Pass   := 'Password';
         Players[0].Nick   := 'erna';
         Players[0].Active := True;

    end;

    Procedure DeclarePlayers tells us the name of the procedure that we are using. Begin starts the procedure [Every "Begin" has an "End", Every "Repeat" has an "Until" and Every "If" has a "Then" - Follow this and it should stop "Idenfitifer Expected ]. How Many Players means how many players we are going to use, and Current player tells us which player to start with. Username, Password are pretty basic, but the Nickname HAS to be 3-4 letters of non-capital or without a space of your Username, like mine is. The Active = True tells us if the player is to be run in the script or not.


    Now we have our next procedure, our AntiRandoms:

    SCAR Code:
    Procedure AntiRandoms;
    begin
      If(FindFight)then
      RunAway('N', True,1,15000);
      FindNormalRandoms;
      FindLamp('Mining');
    end;

    And our AntiBan:

    SCAR Code:
    procedure AntiBan;
    begin
      if not LoggedIn then Exit;
      case Random(30) of
        1: RandomRClick;
        2: HoverSkill('Woodcutting', False);
        3: RandomMovement;
        4: BoredHuman;
        5: AlmostLogout;
        6: DoEmote(400 +Random(90));
      end;
    end;

    Im Not going to explain AntiBan or AntiRandoms, but you can find a tutorial on them found here: http://www.villavu.com/forum/showthread.php?t=27515

    Now onto our actual mining procedure. This part will be merged with an explanation of Fail Safes:

    SCAR Code:
    procedure RockMining;
    begin
    if not LoggedIn then
      Exit;
      if (not (FindObjCustom(x, y, ['Mi', 'ne'], [RockColour1, RockColour2], 7))) then
        Wait(100+random(100));
        Tries := Tries + 1;
        if(Tries = 20)then
          begin
            Logout;
            Exit;
          end else
      if FindObjCustom(x, y, ['Min', 'ine'], [RockColour1, RockColour2], 7) then
      repeat
        case (Random(2)) of
          1: Mouse(x, y, 4, 4,false);
             ChooseOption('ine');
          2: Mouse(x, y, 4, 4, True);
        end;
      until (InvFull)
    end;

    From the Start:

    SCAR Code:
    procedure RockMining;
    begin
    if not LoggedIn then
      Exit;

    We name our procedure, and then it begins. We have our first Fail Safe. If our character is not logged in, the script will exit.

    SCAR Code:
    if (not (FindObjCustom(x, y, ['Mi', 'ne'], [RockColour1, RockColour2], 7))) then
               Wait(100+random(100));
               Tries := Tries + 1;
               if(Tries = 20)then
               begin
                 Logout;
                 Exit;
               end else

    Well first, if it doesnt find the Object that says "Mine" when hovered over, including a Tolerance of 7, so it can search 7 pixels either side, it will wait 0.2 seconds, add 1 to the number of tries, and try again. If it Tries 20 times with no success, it will logout your character, to stop you standing there like an idiot, and then exit the script, and Ends ELSE - IE, otherwise..

    SCAR Code:
    if FindObjCustom(x, y, ['Min', 'ine'], [RockColour1, RockColour2], 7) then
      repeat
        case (Random(2)) of
          1: Mouse(x, y, 4, 4,false);
             ChooseOption('ine');
          2: Mouse(x, y, 4, 4, True);
        end;
      until (InvFull)
    end;

    If it actually finds the Rock to mine, it will repeat a random of these 2, it will hover over the rock and Choose "Mine" or it will automatically click on the rock, to make it more human like. It then ends the case, and the repeat goes with the until, like I said earlier, so it will repeat mining until it has a full inventory, then ends the procedure.

    Onto our final procedure before the loop, the dropping of the mined material:

    SCAR Code:
    Procedure DropRocks;
    begin
        if FindObjCustom(x, y, ['Ore'], [RockColour1, RockColour2], 7) then
        DropTo(2,28);
    end;

    So, it begins, and if it finds the Object "Ore" with the colours you have picked (The Ore colour is generally the same as the rock colour) then it will drop ores from inventory position 2, to inventory position 28.

    Now for our Loop.

    We begin by setting up SRL, then repeating the Mine Procedure & Drop procedure:

    SCAR Code:
    begin
      SetupSRL;
      repeat
        RockMining;
        DropRocks;
        AntiBan;
      until (False)
    end.

    So it begins, sets up SRL, repeats Rock Mining, Drop Rocks and AntiBanning, until it is stopped manually.


    NOTE: If someone could do the Drop procedure - Greatly appreciated.


    Thanks
    Jus' Lurkin'

  2. #2
    Join Date
    Dec 2007
    Location
    192.168.1.73
    Posts
    2,439
    Mentioned
    6 Post(s)
    Quoted
    119 Post(s)

    Default

    Wow! This is a very good and detialed tut.

    I repped you btw

    PS: erma isnt 4 letters of username

  3. #3
    Join Date
    Nov 2007
    Location
    Chile
    Posts
    1,901
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Nice one keep posting tuts.


  4. #4
    Join Date
    Feb 2007
    Location
    South East England
    Posts
    2,906
    Mentioned
    2 Post(s)
    Quoted
    8 Post(s)

    Default

    Thanks guys

    Just an example Dude Ill edit it now
    Jus' Lurkin'

  5. #5
    Join Date
    Mar 2007
    Posts
    1,223
    Mentioned
    0 Post(s)
    Quoted
    5 Post(s)

    Default

    repped! love this tut!

  6. #6
    Join Date
    Dec 2006
    Location
    Program TEXAS home of AUTOERS
    Posts
    7,934
    Mentioned
    26 Post(s)
    Quoted
    237 Post(s)

    Default

    NEWBIE SCRIPTERS! use this! really helpful detail!!!!

    good job bro

  7. #7
    Join Date
    Aug 2007
    Posts
    123
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    yea nice work mate. very good

  8. #8
    Join Date
    Jan 2008
    Posts
    40
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Nice tut, i looked at your anti ban/random one. Both are excellent. Keep of the good work.

    thanx
    Codester93

  9. #9
    Join Date
    Feb 2007
    Location
    South East England
    Posts
    2,906
    Mentioned
    2 Post(s)
    Quoted
    8 Post(s)

    Default

    Thanks Guys
    Jus' Lurkin'

  10. #10
    Join Date
    Dec 2007
    Location
    192.168.1.73
    Posts
    2,439
    Mentioned
    6 Post(s)
    Quoted
    119 Post(s)

    Default

    I think that this should get stickied, a helpful and very detailed tut

  11. #11
    Join Date
    Feb 2007
    Location
    South East England
    Posts
    2,906
    Mentioned
    2 Post(s)
    Quoted
    8 Post(s)

    Default

    Would be nice =]
    Jus' Lurkin'

  12. #12
    Join Date
    Feb 2007
    Posts
    111
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Thanks! My first ever script that actually works. :P +repped!
    Free runescape members? Yes, for 1 cent a click go here!
    http://www.stats.srl-forums.com/sigs/1854.png
    Need a tester? I could test for you. PM me for details =)

  13. #13
    Join Date
    Feb 2007
    Location
    South East England
    Posts
    2,906
    Mentioned
    2 Post(s)
    Quoted
    8 Post(s)

    Default

    No problem dude
    Jus' Lurkin'

  14. #14
    Join Date
    Feb 2007
    Posts
    433
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    making a drop procedure atm, I'll post it soon great tuts btw (even tho I just changed em a little and didn't read a thing )

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

    var x, y, Tries: integer;

    const
    RockColour1= 111111;
    RockColour2= 222222;

    procedure DeclarePlayers;
    begin
     HowManyPlayers := 1;
     NumberOfPlayers(HowManyPlayers);
     CurrentPlayer:= 0

     Players[0].Name   := 'Username';
     Players[0].Pass   := 'Password';
     Players[0].Nick   := 'erna';
     Players[0].Active := True;
    end;

    Procedure AntiRandoms;
    begin
      If(FindFight)then
      RunAway('N', True,1,15000);
      FindNormalRandoms;
      FindLamp('Mining');
    end;

    procedure AntiBan;
    begin
      if not LoggedIn then Exit;
      case Random(30) of
        1: RandomRClick;
        2: HoverSkill('Woodcutting', False);
        3: RandomMovement;
        4: BoredHuman;
        5: AlmostLogout;
        6: DoEmote(400 +Random(90));
      end;
    end;

    procedure RockMining;
    begin
    if not LoggedIn then
      Exit;
      if (not (FindObjCustom(x, y, ['Mi', 'ne'], [RockColour1, RockColour2], 7))) then
        Wait(100+random(100));
        Tries := Tries + 1;
        if(Tries = 20)then
          begin
            Logout;
            Exit;
          end else
      if FindObjCustom(x, y, ['Min', 'ine'], [RockColour1, RockColour2], 7) then
      repeat
        case (Random(2)) of
          0: begin
             Mouse(x, y, 4, 4,false);
             ChooseOption('ine');
             end;
          1: Mouse(x, y, 4, 4, True);
        end;
      until (InvFull)
    end;

    Procedure DropRocks;
    begin
        if FindObjCustom(x, y, ['Ore'], [RockColour1, RockColour2], 7) then
        DropAll;
    end;

    begin
      SetupSRL;
      repeat
        RockMining;
        DropRocks;
        AntiBan;
      until (False)
    end.

    oops, just noticed you already had a drop proc... this compiles now

    when you did..

    SCAR Code:
    case (Random(2)) of
          1: Mouse(x, y, 4, 4,false);
              ChooseOption('ine');
          2: Mouse(x, y, 4, 4, True);
        end;

    it should be..

    SCAR Code:
    case (Random(2)) of
          0: begin
             Mouse(x, y, 4, 4,false);
             ChooseOption('ine');
             end;
          1: Mouse(x, y, 4, 4, True);
        end;

    because the first case is like another proc so you need a
    SCAR Code:
    begin
    and an
    SCAR Code:
    end;
    and the case's should be 0 and 1, not 1 and 2

  15. #15
    Join Date
    Feb 2007
    Location
    South East England
    Posts
    2,906
    Mentioned
    2 Post(s)
    Quoted
    8 Post(s)

    Default

    Thanks for the fix Pwnt
    Jus' Lurkin'

  16. #16
    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

    wow very nuce tut man keep up the good qwork

    rep++ fro u

  17. #17
    Join Date
    Apr 2008
    Location
    washington
    Posts
    2
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    nice tut, it looks sweet

  18. #18
    Join Date
    Mar 2008
    Posts
    9
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    awesome tut. I tried and it mined heaps of iron.

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

    Default

    Quote Originally Posted by Torrent of Flame View Post
    Now we have our next procedure, our AntiRandoms:

    SCAR Code:
    Procedure AntiRandoms;
    begin
      If(FindFight)then
      RunAway('N', True,1,15000);
      FindNormalRandoms;
      FindLamp('Mining');
    end;
    Kinda wrong. FindNormalRandoms finds lamp. And even better, SRL's deafult lampskill is mining! No need for findlamp at all! If you want findlamp to be a different skill, insert this in the 'setup' part of the mainloop in the script. (The part of the mainloop that only is ran once.

    SCAR Code:
    LampSkill := 'LampSkill'; // Eg. LampSkill := 'Fishing';

    And by the way, your mining procedure can be improved.
    Add more failsafes, getmousepos and fix that case. remove randomness from mouseclicks, because you're using FindObj.

  20. #20
    Join Date
    Mar 2008
    Location
    Look behind you.
    Posts
    795
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    does this power miner thing also apply to making an ess miner? like does most of the rules to making a power miner apply to making a ess miner?

    sorry if this confused you but i wanna know how to make an ess miner so bad

  21. #21
    Join Date
    Sep 2007
    Posts
    501
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    All the same rules apply except that the colour of Essence is close to the color of the walls and surroundings you might want to look at what Wizzup? did in his miner.

  22. #22
    Join Date
    Feb 2007
    Location
    South East England
    Posts
    2,906
    Mentioned
    2 Post(s)
    Quoted
    8 Post(s)

    Default

    Meh..

    Bumpage
    Jus' Lurkin'

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

    Default

    Very nice tutorial - and is helping me alot with creating my auto fisher.

  24. #24
    Join Date
    Feb 2007
    Location
    South East England
    Posts
    2,906
    Mentioned
    2 Post(s)
    Quoted
    8 Post(s)

    Default

    WTF? Autofisher.

    Its an POWER MINER. WTH MAN?
    Jus' Lurkin'

  25. #25
    Join Date
    Apr 2008
    Posts
    86
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    this is a great [TUT], how do i add a progress report?

    how do i fix this?
    Line 77: [Error] (12731:1): Unknown identifier 'DropTo' in script C:\Program Files\SCAR 3.15\Scripts\SunnysFirstPowerMiner.scar

Page 1 of 3 123 LastLast

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Riffe's Making Money Guide!
    By Riffe in forum Cash Guides
    Replies: 13
    Last Post: 12-27-2008, 11:55 PM
  2. Random Money Making guide ish
    By IsrafelDarklight in forum Cash Guides
    Replies: 12
    Last Post: 05-22-2008, 04:40 PM
  3. Updated AntiBan & AntiRandoms Guide!
    By Torrent of Flame in forum Outdated Tutorials
    Replies: 22
    Last Post: 03-29-2008, 11:08 AM
  4. What's the best Money Making guide
    By rkroxpunk in forum RuneScape News and General
    Replies: 1
    Last Post: 04-22-2007, 03:34 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
  •