Can someone help me with my first basic script please!

Discussion in 'Scar/Simba Help' started by ashman, Nov 30, 2007.

Can someone help me with my first basic script please!
  1. Unread #1 - Nov 30, 2007 at 2:34 PM
  2. ashman
    Referrals:
    0

    ashman Guest

    Can someone help me with my first basic script please!

    Hi there i am having trouble getting this to actually chop wood... can anyone please help?

    I am obviously very new to all this so be gentle :(

    Code:
    {{
    
         Script By Ash
    
    }}
    
    
    
    
    program New;
    {.include SRL/SRL.scar}
    
    const
      LoadsPerPlayer = 10; //Number of loads before Moving onto the next user.
      TreeColor = 3364207;  //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 := '****'; //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;
        if TimeFromMark(MyMark) > (2*60*100) then  //If no chop within 2 mins then exit
        begin
          Logout;
          Exit;
        end;
      until false
    end;
    
    begin
      SetupSRL;
      DeclarePlayers;
      if Loggedin then Logout;
      LoginPlayer;
      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.
     
  3. Unread #2 - Dec 3, 2007 at 12:33 PM
  4. ashman
    Referrals:
    0

    ashman Guest

    Can someone help me with my first basic script please!

    Has nobody got any ideas???
     
  5. Unread #3 - Dec 8, 2007 at 2:18 PM
  6. ProphesyOfWolf
    Joined:
    Dec 6, 2007
    Posts:
    85
    Referrals:
    0
    Sythe Gold:
    0

    ProphesyOfWolf Member

    Can someone help me with my first basic script please!

    Well, first thing's first..

    {{

    Script By Ash

    }} <------ That second } makes the script screw up.. GET RID OF IT!

    Now try..
     
  7. Unread #4 - Dec 8, 2007 at 2:19 PM
  8. ProphesyOfWolf
    Joined:
    Dec 6, 2007
    Posts:
    85
    Referrals:
    0
    Sythe Gold:
    0

    ProphesyOfWolf Member

    Can someone help me with my first basic script please!

    okay, it works.. Nice job on your first script ^^
     
< so help me plz :) | Scar Error (I installed SRL correctly) >

Users viewing this thread
1 guest


 
 
Adblock breaks this site