Results 1 to 3 of 3

Thread: my script needs help

  1. #1
    Join Date
    Jun 2006
    Posts
    1,492
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default my script needs help

    heres my script. when i run it, its looks for a tree, finds it, and clicks it, and then scar freezes up, and im left with a moving mous that wont stop movin in hte same position over and over agan. i cant stop the script cuz scar is frozen. any ideas?

    Code:
    program WillowCutter;
    
    {.include SRL\SRL.scar}
    {.include SRL\SRL\skill\woodcutting.scar}
    
    var willow: integer;
    
    const
      Nick = 'Write 3-4 letters of your username here';
      TreeColor1=2914408;   //Set three tree colors here
      TreeColor2=2127968;
      TreeColor3=4358256;
      CutTime=15;           //Set time in seconds to wait before cutting down another tree
      
      
    Procedure welcome;
    begin
      ClearDebug
      writeln('////////////////////\\\\\\\\\\\\\\\\\\\\')
      writeln('/       Welcome to Infantry001''s       \')
      writeln('/             WillowCutter!            \')
      writeln('/                                      \')
      writeln('/          Hope you enjoy it!          \')
      writeln('////////////////////\\\\\\\\\\\\\\\\\\\\')
      wait(2000);
      readln('Welcome to my Willow-cutter. Enjoy, and remember, keep on auto-ing!')
    end;
    
    Procedure setup;
    begin
      FixChat
      SetupDemon
      FindAxeHeadColor
    end;
    
    Procedure loadbitmaps;
    begin
      willow := BitmapFromString(13, 14, 'z78DA333018C1C0D9D5D9D5' +
           '104A52A20659A5B1ABA18BABA185A19381194E35C4BB6DA898861' +
           '94A949B862932D44D8300B05E2889641A8A08A9C008AC17833434' +
           '07B91042926A24B25EFCE60000859CDB64');
    end;
    
    Procedure randoms;
    begin
      FindHead;
      FindEnt(TreeColor1);
    end;
      
    Procedure CutLogs;
    var x,y: integer;
    var x1,y1: integer;
    begin
    repeat
      if(FindColorTolerance(x,y,treecolor1, 4,1,515,337,5))or(FindColorTolerance(x,y,treecolor2, 5,4,515,337,5))or(FindColorTolerance(x,y,treecolor3, 5,4,515,337,5))then
      MMouse(x,y,3,3)
      wait(500+random(50));
      if(FindBitmapToleranceIn(willow,x1,y1,80,5,100,20,2))then;
      CMouse(x,y,3,3,true)
      wait(CutTime * 1000+random(500));
    until(InvFull);
    end;
    
    
      
    begin
    welcome;
    SetupSRL;
    ActivateClient;
    setup;
    NickNameBMP  := CreateBitmapMaskFromText(Nick, UpChars);
    loadbitmaps;
      wait(500);
    repeat
    Antiban;
    FindNormalRandoms;
    randoms;
    CutLogs;
    DropAllLogs;
      wait(500);
    until(false);
    end.

  2. #2
    Join Date
    May 2006
    Posts
    105
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Change This :
    Code:
    Procedure CutLogs;
    var x,y: integer;
    var x1,y1: integer;
    begin
    repeat
      if(FindColorSpiralTolerance(x,y,treecolor1, 4,1,515,337,5))or(FindColorSpiralTolerance(x,y,treecolor2, 5,4,515,337,5))or(FindColorSpiralTolerance(x,y,treecolor3, 5,4,515,337,5))then
      MMouse(x,y,3,3)
      wait(500+random(50));
      if(FindBitmapToleranceIn(willow,x1,y1,80,5,100,20,2))then;
      CMouse(x,y,3,3,true)
      wait(10000+random(500));
    until(InChat('Your inventory is too full to hold any more logs.'))
    end;
    To This :
    Code:
    Procedure CutLogs;
    var x,y: integer;
    var x1,y1: integer;
    begin
    repeat
      if(FindColorSpiralTolerance(x,y,treecolor1, 4,1,515,337,5))or(FindColorSpiralTolerance(x,y,treecolor2, 5,4,515,337,5))or(FindColorSpiralTolerance(x,y,treecolor3, 5,4,515,337,5))then
      MMouse(x,y,3,3)
      wait(500+random(50));
      if(FindBitmapToleranceIn(willow,x1,y1,80,5,100,20,2))then
       CMouse(x,y,3,3,true);
      wait(10000+random(500));
    until(InvFull);
    end;

  3. #3
    Join Date
    Jun 2006
    Posts
    1,492
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    ok thanks

    EDIT* mouse still shakes and shakes and never stops shaking...its like a lava lamp...you cant stop watching it...YES YOU CAN! so i still ahve that problem. what else is wrong about my script? and thanks for trying, realrune. that will certainly be a better procedure to use

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
  •