Results 1 to 4 of 4

Thread: Line 2: [Error] (16831:1): Identifier expected in script

  1. #1
    Join Date
    Feb 2009
    Posts
    2,155
    Mentioned
    4 Post(s)
    Quoted
    42 Post(s)

    Default Line 2: [Error] (16831:1): Identifier expected in script

    Code:
    {.include srl/srl.scar}
    {.include tester.scar}
    
     var x,y:integer;
    
    
    procedure DeclarePlayers;
    begin
      HowManyPlayers := 1; // If you add more players , make sure you set this correct, ;)
      NumberOfPlayers(HowManyPlayers);
    
      Players[0].Name := ''; //Your username
      Players[0].Pass := ''; //Your password
      Players[0].Nick := ''; //Nickname from you username
      Players[0].Active := True; //Active->True or False.
      Players[0].Integers[0] := 40; //Loads to do.  Random 3 will be added.
      Players[0].Strings[1] := 'woodcutting'; //what skill do u want to do mining or wcing
      Players[0].strings[2] := 'willow' //what tree or ore do u want to power skill
      { woodcutting
         tree =  normal   oak =oak  willow= willow yew = yew
         
      mining
        all the normal ore name must be spelled perfectly}
    end;
    
    procedure woodcutting;
    var
      i , m: integer;
      treecolors: array [0..3] of integer;
      treeNames: array [0..2] of String;
    begin
      Players[CurrentPlayer].Loc := 'trees';
      repeat
        if Players[CurrentPlayer].strings[2] = 'willow' then
          chopwillows;
          if Players[CurrentPlayer].strings[2] = 'normal' then
            choptrees;
       
         {AntiBanz;
          FindRandoms;}
          if not (LoggedIn) then
            begin
              NextPlayer(False);
              LoginPlayer;
            end;
         until invfull or inchat('full to')
    end;
    
    
    begin
      setupsrl;
      activateclient;
      declareplayers;
      loginplayer;
      if Players[CurrentPlayer].strings[1] = 'woodcutting' then
      woodcutting;
    end.


    i get that error now {.include tester.scar} is my making my own include practice and the error line

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

    Default

    Post tester.scar.

    You messed something up in there.
    I do visit every 2-6 months

  3. #3
    Join Date
    Feb 2009
    Posts
    2,155
    Mentioned
    4 Post(s)
    Quoted
    42 Post(s)

    Default

    Code:
    var
      i , m, x, y: integer;
      treecolors: array [0..3] of integer;
      treeNames: array [0..2] of String;
    
    
    procedure chopwillows;
    begin
    begin
      disguise('chopping')
      treecolors[0]:= 3759203;
      treecolors[1]:= 5406322;
      treecolors[2]:= 6132352;
      treecolors[3]:= 3363673;
      treenames[0]:= 'Wil';
      treenames[1]:= 'llo';
      treenames[2]:= 'low';
      repeat
        if (not LoggedIn) then Exit;
          for i := 0 to 3 do
            if FindObjTPA(x, y, treecolors[i], 10, 2, 15, 25, 10, [treenames[0], treenames[1], treenames[2]]) then
            begin
              FindObjTPA(x, y, treecolors[i], 10, 2, 15, 25, 10, [treenames[0], treenames[1], treenames[2]])
              Wait(100 + Random(300));
                 begin
                      Mouse(x, y, 4, 4, True);
                      m:=0;
                      MarkTime(M);
                      repeat
                       Case (Random(3)) of
                         0: wait(100);
                         1: wait(3500);
                         2: wait(3000);
                       end;
                       until not(IsUpText('willow')) or (m > 30000);
                      end;
                     end;
              until invfull or inchat('full to')
             end;
            end;
    
    
    procedure choptrees;
    begin
        treecolors[0]:= 1195316;//get new colors
        treecolors[1]:= 4814702;
        treecolors[2]:= 4353679;
        treecolors[3]:= 4287628;
        treenames[0]:= 'Tree';
        treenames[1]:= 'Tre';
        treenames[2]:= 'ree';
        repeat
        if (not LoggedIn) then Exit;
          for i := 0 to 3 do
          if FindObjTPA(x, y, treecolors[i], 10, 2, 15, 25, 10, [treenames[0], treenames[1], treenames[2]]) then
          begin
            FindObjTPA(x, y, treecolors[i], 10, 2, 15, 25, 10, [treenames[0], treenames[1], treenames[2]])
            Wait(100 + Random(300));
            begin
              Mouse(x, y, 4, 4, True);
              m:=0;
              MarkTime(M);
              repeat
                Case (Random(3)) of
                  0: wait(10); //findrandoms;
                  1: wait(3500);
                  2: wait(3000);
                end;
              until not(IsUpText('tree')) or (m > 30000);
            end;
          end;
    end;

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

    Default

    SCAR Code:
    var
      i , m, x, y: integer;
      treecolors: array [0..3] of integer;
      treeNames: array [0..2] of String;


    procedure chopwillows;
    begin
      begin
        disguise('chopping')
        treecolors[0]:= 3759203;
        treecolors[1]:= 5406322;
        treecolors[2]:= 6132352;
        treecolors[3]:= 3363673;
        treenames[0]:= 'Wil';
        treenames[1]:= 'llo';
        treenames[2]:= 'low';
        repeat
          if(not(LoggedIn))then
            Exit;
          for i := 0 to 3 do
            if FindObjTPA(x, y, treecolors[i], 10, 2, 15, 25, 10, [treenames[0], treenames[1], treenames[2]]) then
            begin
              FindObjTPA(x, y, treecolors[i], 10, 2, 15, 25, 10, [treenames[0], treenames[1], treenames[2]])
              Wait(100 + Random(300));
              begin
                Mouse(x, y, 4, 4, True);
                m:=0;
                MarkTime(M);
                repeat
                  Case (Random(3)) of
                    0: wait(100);
                    1: wait(3500);
                    2: wait(3000);
                  end;
                until not(IsUpText('willow')) or (m > 30000);
              end;
            end;
        until invfull or inchat('full to')
      end;
    end;


    procedure choptrees;
    begin
      treecolors[0]:= 1195316;//get new colors
      treecolors[1]:= 4814702;
      treecolors[2]:= 4353679;
      treecolors[3]:= 4287628;
      treenames[0]:= 'Tree';
      treenames[1]:= 'Tre';
      treenames[2]:= 'ree';
      repeat
        if(not LoggedIn)then
          Exit;
        for i := 0 to 3 do
          if FindObjTPA(x, y, treecolors[i], 10, 2, 15, 25, 10, [treenames[0], treenames[1], treenames[2]]) then
          begin
            FindObjTPA(x, y, treecolors[i], 10, 2, 15, 25, 10, [treenames[0], treenames[1], treenames[2]])
            Wait(100 + Random(300));
            begin
              Mouse(x, y, 4, 4, True);
              m:=0;
              MarkTime(M);
              repeat
                Case (Random(3)) of
                  0: wait(10); //findrandoms;
                  1: wait(3500);
                  2: wait(3000);
                end;
            end;
          end;
      until not(IsUpText('tree')) or (m > 30000);
    end;

    Better standards.

    The problem was the until not isuptex tree part at the bottom. It was at the wrong place.
    I do visit every 2-6 months

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
  •