Results 1 to 13 of 13

Thread: My First attempt...need some guidence!

  1. #1
    Join Date
    Sep 2007
    Posts
    43
    Mentioned
    1 Post(s)
    Quoted
    0 Post(s)

    My First attempt...need some guidence!

    Hi guys, basically i've started to follow tutorials that i have found on this site and gone through them to learn about scripting.

    For this script i didn't write it myself i was following a tutorial by The_Rs_Monkey

    I've experimented with changing a few things from the final script to get it to work. I and was just looking for some pointers on what to look at next.

    Basically it will log-on fine but it won't begin to chop the wood...i think its done it like once... I select the colours right before i run the script and everything....



    Thank you in advance

    heres the code...

    P.S. before you rip into me...remember this is my first attempt and i havent bin able to put anti-ban etc on yet because i havent learnt that much yet lol
    Code:
    {
    
    
    
    
    
         Script By Ash With ALOT! help from...
         The_Rs_Monkey's tutorial on www.srl-forums.com
    
    
    }
    
    
    
    
    program New;
    {.include SRL/SRL.scar}
    
    const
      LoadsPerPlayer = 10; //Number of loads before Moving onto the next user.
      TreeColor = 4156042;  //Colour of the tree you wish to chop.
      WaitPerTree = 5000; //Time to wait before clicking another tree.
    
    
    
    procedure DeclarePlayers;
    begin
        NumberOfPlayers(1)
      
         Players[0].Name := ''; //Please enter your Runescape User name.
         Players[0].Pass := ''; //Please enter your Runesacpe Password.
         Players[0].Nick := 'shma'; //Please enter a nick E.G. if your username is donkey enter 'onke'
         Players[0].Active := True; //Is this player active?
         
         {Players[1].Name := ''; //Please enter your Runescape User name.
         Players[1].Pass := ''; //Please enter your Runesacpe Password.
         Players[1].Nick := ''; //Please enter a nick E.G. if your username is donkey enter 'onke'
         Players[1].Active := True; //Is this player active?   }
      
     { LoadPlayerArray(Players); }
    end;
    
    procedure ChopTree;
    
    var
      x,y, MyMark : integer;
    
    begin
      if not loggedin then Exit;
      MarkTime(MyMark);
      repeat
        if FindObj(x, y, 'hop', TreeColor, 20) then
        begin
          Mouse(x, y, 0, 0, False);
          if ChooseOption('hop') then
          begin
            Wait(WaitPerTree);
            Exit; //Successfull chop so exit.
          end;
          end else
          begin
            writeln('Could not find Tree.');
        end;
        if TimeFromMark(MyMark) > (1*30*100) then  //If no chop within 30 secs then exit
        begin
          Logout;
          Exit;
        end;
      until false
    end;
    
    
    {var
    level : integer;}
    
    begin
      SetupSRL;
      DeclarePlayers;
      if Loggedin then LogOut;
      LoginPlayer;
      //level := GetSkillLevel('Woodcutting');
      writeln('logged in');
      
      repeat
        ChopTree;
        if InvFull then
        begin
         DropToPosition(2,28);
         Inc(Players[CurrentPlayer].Banked);
         if Players[CurrentPlayer].Banked mod LoadsPerPlayer = 0 then
         begin
           NextPlayer(True);
         end;
        end;
         if not Loggedin then NextPlayer(False);
      until false
    end.

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

    Default

    you might wna remove your details..
    ~ Rs-Gp-4U
    _____________________________________________

    Bux.To! Sign Up Easy Money!

  3. #3
    Join Date
    Sep 2007
    Posts
    43
    Mentioned
    1 Post(s)
    Quoted
    0 Post(s)

    Default

    lol yeh duh!!!...i think i have now....haven't I??? i've jst changed my password and everything...shows im a n00b to this doesn't it!!!

    thnx

  4. #4
    Join Date
    Nov 2007
    Location
    SCAR central
    Posts
    116
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    pretty good for a first attempt... have some failsafes, anti randoms,proggie,auto responder is optional,and sig the chop procedure is good but have a drop 1 as it wont chop after your inv's full
    Click here for Rora's Power Woodcutter!
    Testers needed!
    |
    |
    |
    |
    V



    http://www.fenjer.com/adnan/SRL//100...Woodcutter.png

    http://photos33.flickr.com/38918814_8370ddb570_m.jpg




    If I see you autoing with level 3/default clothes/crap name I WILL report you. Auto Correctly. - put this in your sig.

  5. #5
    Join Date
    Sep 2007
    Posts
    43
    Mentioned
    1 Post(s)
    Quoted
    0 Post(s)

    Default

    is there any reason why it would just log on and not click the tree though??? like theres no reason why it shouldn't wrk as it is???

    coz it doesn't lol

  6. #6
    Join Date
    Oct 2007
    Location
    http://ushort.us/oqmd65
    Posts
    2,605
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    It should click the tree...
    I do visit every 2-6 months

  7. #7
    Join Date
    Nov 2007
    Posts
    48
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    in declareplayers...

    CheckUserNicks;
    or
    NickNameBMP := CreateBitmapMaskFromText(Players[CurrentPlayer].Nick, UpChars);

    helps with antirandom

  8. #8
    Join Date
    Sep 2007
    Posts
    43
    Mentioned
    1 Post(s)
    Quoted
    0 Post(s)

    Default

    kool thanks guys...
    im still having trouble actually just getting it to click on a tree....
    is there anything wrong with my 'ChopTree' procedure that anyone can see??
    ....
    when i run the program it logs in and then just stops doesn't have any errors so im confussed!!!

  9. #9
    Join Date
    Jan 2007
    Location
    Hamilton, New Zealand
    Posts
    177
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Code:
    function ChooseOption(txt: String): Boolean; 
    By: Stupid3ooo, modded by Sumilion 
    Description:
         Finds Popup menu, then clicks on it.
    For the ChoseOption thing, take out the x and y. Only if you are using SRL4 i think though.
    Also, I got told to use "Function FindObjCustom(var cx, cy: Integer; Text: TStringArray; Color: TIntegerArray;" instead of just FindObj.

    I found that hard to understand, so here is an example.
    FindObjCustom(x, y, ['ssence','Ess','ine Ess','Mine Essence'], [8948115,5270647,10066341,3158068], 3)

    Where the essence parts of words are the text + the colours are some diffrent colours to look for.
    Not sure if that solves your problem but it cant hurt to try.

  10. #10
    Join Date
    Jan 2007
    Location
    Hamilton, New Zealand
    Posts
    177
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Ok. On my computer it rightclicks on the tree then doesnt click on the chop tree option.
    Maybe you could change

    SCAR Code:
    Mouse(x, y, 0, 0, False);
          if ChooseOption('hop') then
          begin
            Wait(WaitPerTree);
            Exit; //Successfull chop so exit.
          end;

    To

    SCAR Code:
    Mouse(x, y, 0, 0, True);
            Wait(WaitPerTree);
            Exit; //Successfull chop so exit.
          end;

  11. #11
    Join Date
    Sep 2007
    Posts
    43
    Mentioned
    1 Post(s)
    Quoted
    0 Post(s)

    Default

    thanks ill give all that a go and give you an update on what the result is....thanks for your help its much appreciated...and also thanks for the example of the findobjcustom i was looking through the srl manual and i was confident on exactly what the syntax meant so thats a great help...
    Thank you


    UPDATE:
    Hi there thanks to ss23 and looking through some other scripts in the junior member scripts forum i was able to find something in the main function of the script that seemed for some reason to make all the difference...

    its basically the activate client procedure. I just put that before any other functions in the scripts and hey presto is started clicking away...
    So thank you all for your help...


    now i am going to be adding an anti ban into the script so im off to look at some tutorials!!!

  12. #12
    Join Date
    Nov 2007
    Location
    SCAR central
    Posts
    116
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    after declare players in the main loop,

    put 'activateclient;'

    if you havent already
    Click here for Rora's Power Woodcutter!
    Testers needed!
    |
    |
    |
    |
    V



    http://www.fenjer.com/adnan/SRL//100...Woodcutter.png

    http://photos33.flickr.com/38918814_8370ddb570_m.jpg




    If I see you autoing with level 3/default clothes/crap name I WILL report you. Auto Correctly. - put this in your sig.

  13. #13
    Join Date
    Sep 2007
    Posts
    43
    Mentioned
    1 Post(s)
    Quoted
    0 Post(s)

    Default

    Thanks yeh that was what was stopping it working. Its running now, so i put it in the my first script section...obviously i added antirandom and anti ban. But yeh thanks guys you really helped me so yeh thanks

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. First Attempt
    By Harry in forum Graphics and Multimedia
    Replies: 5
    Last Post: 03-25-2008, 01:13 PM
  2. First ever sig attempt
    By jhildy in forum Graphics and Multimedia
    Replies: 1
    Last Post: 02-13-2008, 02:42 AM
  3. Bginer who needs guidence
    By wazzumatt21 in forum OSR Help
    Replies: 3
    Last Post: 12-09-2007, 01:49 AM
  4. 3d attempt
    By jhildy in forum Semi Stupid Pictures
    Replies: 12
    Last Post: 08-08-2007, 01:56 PM
  5. My attempt lol
    By rotflmfwao in forum OSR Help
    Replies: 8
    Last Post: 07-16-2007, 05:01 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
  •