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

Thread: Edgeville Yew Chopper & Banker

  1. #1
    Join Date
    Aug 2008
    Location
    London, UK
    Posts
    456
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default Edgeville Yew Chopper & Banker

    V0.07
    Edgeville Yew Chopper & Banker
    By ReadySteadyGo



    Hi all.

    This isn't actually my first script. I used to script a fair few years ago but the standard is that much higher and I had to go back to basics. SRL is crazy good and I'm enjoying all the new SCAR features such as ColorToleranceSpeed etc.

    Anyway, thought I'd post and see if I can get some help.

    Cheers.


    Progress Report:

    [==============================================]
    [ Yew Chopper Version 1.04 by Jack ]
    [==============================================]
    [ Script duration : 1 Hours, 36 Minutes and 7 Seconds ]
    [ Logs banked : 280 ]
    [ Loads : 10 ]
    [==============================================]


    Version Updates

    EDIT: Added V1.02 - Starting to work quite well now.

    EDIT: V1.03 - Animation IsChopping, fixed various problems working very smoothly now. Can anyone test it for me?

    EDIT: V1.04 -
    Added a lot, took off animation after fiddling with it for hours, you can do the same thing faster and more accurate with a TPA.
    Rewrote TreesToBank procedure.
    Rewrote Banking procedure.

    EDIT: V1.05
    Fixed Logout error.
    Cleaned up a few things.

    EDIT: V1.06

    EDIT: V1.07
    Added more in function antiban and improved some procedures.
    Last edited by ReadySteadyGo; 01-29-2010 at 11:09 PM.

  2. #2
    Join Date
    Jul 2008
    Location
    Canada
    Posts
    1,612
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    This script is really good, you should try attempting some TPAs soon

    By the way:

    SCAR Code:
    function BankToTrees : Boolean;
    begin
      if (not LoggedIn) then
        Exit;
      x := MMCX;
      y := MMCY;
      Result := FindColorSpiral(x, y, TreeSymbol, MMX1, MMY1, MMX2, MMY2);
      if (Result) then
      begin
        Mouse(x + 5, y + 17, 2, 2, True)
        WriteLn('Moving to trees');
      end else
      begin
        WriteLn('Could not find Tree Symbol');
        Players[CurrentPlayer].Active := False;
        LogOut;
        Exit;
      end;
    end;

    When you do Mouse(x + 5 that can be a bit bot-like. Thus, I suggest doing x + 3 + Random(2) or

    Mouse(x + RandomRange(1, 6),

    etc.

    Keep up the good work though

  3. #3
    Join Date
    Aug 2008
    Location
    London, UK
    Posts
    456
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    Hey thanks Smarter Child

    I just updated. I added some TPA's, failsafes etc. Lemme know what you think.

    Ok I'll change that, think I'm going to add multiple routes.

    Cheers for looking,

    Jack

    PS cool name!

  4. #4
    Join Date
    Apr 2008
    Location
    Marquette, MI
    Posts
    15,252
    Mentioned
    138 Post(s)
    Quoted
    680 Post(s)

    Default

    Here's some feedback for you

    FindTree
    [LIST][*]In your second for..to..do loop, you should add a length check to get rid of any colors SCAR may find that aren't on the tree (i.e. flowers, grass, bushes). Something like this:
    [LIST]
    SCAR Code:
    if (Length(boxesArr[i]) < 80) then
      Continue;
    • You should add a short before you check for uptext. The uptext takes some time to show up after the mouse is moved over the object. This wait is also useful in case of lag. You could also just use WaitUpTextMulti.


    Chop
    • You need a method of detecting whether the play is chopping or not. Check out Animation.scar.


    Bank
    • You have it set to enter in the PIN every time the bank is opened. What if the player doesn't have a bank PIN?


    Overall this is a good script. I like your use of constants, it really makes the code more readable. There's not much else I can say about this script, other than great job.

    Cheers,
    Coh3n

  5. #5
    Join Date
    Aug 2008
    Location
    London, UK
    Posts
    456
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    Cheers Coh3n, I've made the changes, I'll post when I've fixed a few more things.

    First progress report:

    [==============================================]
    [ Yew Chopper Version 1.03 by Jack ]
    [==============================================]
    [ Script duration : 19 Minutes and 58 Seconds ]
    [ Logs banked : 56 ]
    [ Loads : 2 ]
    [==============================================]

    Ran well, stopped it to make some changes.

  6. #6
    Join Date
    Jan 2010
    Posts
    2
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    im available to test mate

  7. #7
    Join Date
    Aug 2008
    Location
    London, UK
    Posts
    456
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    aha little bro you do make me chuckle.

  8. #8
    Join Date
    Jan 2010
    Posts
    2
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    will be posted tomorrow morning check back at around 7:30 defenitely on by then

  9. #9
    Join Date
    Aug 2008
    Location
    London, UK
    Posts
    456
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    Added a lot, took off animation after fiddling with it for hours, you can do the same thing faster and more accurate with a TPA.
    Rewrote TreesToBank procedure.
    Rewrote Banking procedure.

    Progress Reports are getting better :

    [==============================================]
    [ Yew Chopper Version 1.04 by Jack ]
    [==============================================]
    [ Script duration : 53 Minutes and 40 Seconds ]
    [ Logs banked : 112 ]
    [ Loads : 4 ]
    [==============================================]

  10. #10
    Join Date
    Aug 2008
    Location
    London, UK
    Posts
    456
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    Wooo! Getting there!

    [==============================================]
    [ Yew Chopper Version 1.04 by Jack ]
    [==============================================]
    [ Script duration : 1 Hours, 36 Minutes and 7 Seconds ]
    [ Logs banked : 280 ]
    [ Loads : 10 ]
    [==============================================]

    Could not find Tree Symbol

  11. #11
    Join Date
    Aug 2008
    Location
    London, UK
    Posts
    456
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    Can someone move this to the Free for all or junior scripts section please? I need people to test it.

  12. #12
    Join Date
    Oct 2009
    Location
    Stockton, CA
    Posts
    2,040
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    I shall test this in a few minutes .
    Join the IRC! irc.rizon.net:6667/srl | SQLite (0.99rc3+) | SRL Doc | Simba Doc | Extra Simba Libraries (openSSL & sqlite3)
    Quote Originally Posted by #srl
    10:45 < Toter> daphil when can get sex anyday I want
    10:45 < Toter> he is always on #SRL
    "A programmer is just a tool which converts caffeine into code"

  13. #13
    Join Date
    Aug 2008
    Location
    London, UK
    Posts
    456
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    Thank you!

  14. #14
    Join Date
    Jan 2010
    Posts
    25
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Sorry I'm new to this...I got this error:

    Line 847: [Error] (20810:4): Unknown identifier 'Respond' in script C:\Documents and Settings\Matthew\Desktop\scarprerelease\includes\S RL\SRL\Core\AntiRandoms\AntiRandoms.scar

  15. #15
    Join Date
    Oct 2009
    Location
    Stockton, CA
    Posts
    2,040
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    Quote Originally Posted by Baba mhillo View Post
    Sorry I'm new to this...I got this error:

    Line 847: [Error] (20810:4): Unknown identifier 'Respond' in script C:\Documents and Settings\Matthew\Desktop\scarprerelease\includes\S RL\SRL\Core\AntiRandoms\AntiRandoms.scar
    Try redownloading SRL via the SVN repository and move plugins.
    Join the IRC! irc.rizon.net:6667/srl | SQLite (0.99rc3+) | SRL Doc | Simba Doc | Extra Simba Libraries (openSSL & sqlite3)
    Quote Originally Posted by #srl
    10:45 < Toter> daphil when can get sex anyday I want
    10:45 < Toter> he is always on #SRL
    "A programmer is just a tool which converts caffeine into code"

  16. #16
    Join Date
    Jan 2010
    Posts
    25
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    It runs fine for a while, but eventually it clicks on the the levels tab and I get this error: [Runtime Error] : Exception: Could not convert variant of type (String) into type (Boolean) in line 366 in script C:\Documents and Settings\Matthew\Desktop\scarprerelease\includes\S RL\SRL\Core\GameTab.scar

  17. #17
    Join Date
    Dec 2009
    Location
    Newcastle, Australia
    Posts
    888
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    dunno how, buy mine got lost and went an extra click to the south west or something, and then started chopping normal trees...dunno why...I'll run it again and sit here and watch what happens

  18. #18
    Join Date
    Aug 2008
    Location
    London, UK
    Posts
    456
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    Baba mhillo, you might need to svn update, check this tutorial by coh3n. http://www.villavu.com/forum/showthread.php?t=47714

    Bad Boy, what was the message in the debug box?

    I just got a 6.5 hour proggie

    [==============================================]
    [ Yew Chopper Version 1.09 by ReadySteadyGo ]
    [==============================================]
    [ Script duration : 6 Hours, 57 Minutes and 23 Seconds ]
    [ Logs banked : 336 ]
    [ Loads : 12 ]
    [==============================================]

  19. #19
    Join Date
    Jan 2007
    Posts
    8,876
    Mentioned
    123 Post(s)
    Quoted
    327 Post(s)

    Default

    That is actually a 6.95 hour proggie :P
    How come it only gained 336 logs in nearly 7 hours? Isn't that low for a yew cutter?

  20. #20
    Join Date
    Aug 2008
    Location
    London, UK
    Posts
    456
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    oh jeez, maybe there is something wrong with my loads counter, i'll take a look at that thanks. I know it was definitely running well for at least 3 hours and that is low for even 3 hours.

  21. #21
    Join Date
    Dec 2009
    Location
    Newcastle, Australia
    Posts
    888
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    I got 140 for 1h 47m but I had a load that didn't get banked because the thing couldn't find the carpet...

    perhaps more failsafes...

    [==============================================]
    [ Yew Chopper Version 1.09 by ReadySteadyGo ]
    [==============================================]
    [ Script duration : 1 Hours, 47 Minutes and 41 Seconds ]
    [ Logs banked : 140 ]
    [ Loads : 5 ]
    [==============================================]
    CurrentTree: Could not find Tree Symbol
    Could not find carpet.
    Used a blind click.
    Could not find carpet.
    Could not find carpet.
    Could not find carpet.
    Could not find carpet.
    Could not find carpet.
    Could not find carpet.
    Could not find carpet.
    Could not find carpet.
    Could not find carpet.
    Could not find carpet.
    Could not find carpet.
    Could not find carpet.
    Could not find carpet.
    Could not find carpet.
    Could not find carpet.
    Could not find carpet.
    Could not find carpet.
    NextPlayer
    Also the next player, I have only got 1 player, and the next player just sits there, and doesn't do anything, is this how you configured it, or the NextPlayer's Scripter's fault.

    Edit:better clarify what that last thing meant, re-read and it was poorly worded...

    When the next player function executes, it must get halfway done, then stop, because the script doesn't terminate and all players would be inactive...

    Edit, the script got lost again, unfortunatly, didnt realise until after I restarted the script (which clears debug) it chops the normal trees, which is because you have an uptext option for 'hop' and 'own' which means it will repsond to any tree....not just yews...
    Last edited by Bad Boy JH; 01-31-2010 at 04:59 AM.

  22. #22
    Join Date
    Aug 2008
    Location
    London, UK
    Posts
    456
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    Thank you very much bad boy! I will fix those errors.

  23. #23
    Join Date
    Dec 2009
    Location
    Newcastle, Australia
    Posts
    888
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Lol, glad to help, you won't ever find all the errors on your own...lol

  24. #24
    Join Date
    Feb 2010
    Posts
    4
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Alright i know im a new user and all and im pretty new to this script stuff but ive been trying to get this thing to work for hours but it will not work. It will click to the spost where its supposed to go , then it just sits there and clicks on the inventory bag and detects the tree every once in a while but does not click on the tree to cut. Can you please help me?

  25. #25
    Join Date
    Dec 2009
    Location
    Newcastle, Australia
    Posts
    888
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Allright, It is probable that you are using Scar 3.22, which is the most recently released version, however due to a update late last year which screwed with the uptext, which is what is used to detect trees, and it broke, you now need the pre-release of scar, version 3.23...

    Tutorial here!
    Last edited by Bad Boy JH; 02-10-2010 at 03:50 AM.

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)

Posting Permissions

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