Results 1 to 3 of 3

Thread: Error in my script.NEED HELP!

  1. #1
    Join Date
    Mar 2007
    Location
    In your computer
    Posts
    244
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default Error in my script.NEED HELP!

    Hello i keep on getting an error in my script...And i need to fix the problem, but i cant find it!So could someone help me out and find out whats wrong?
    Thanks -Pie

    ERROR:Line 37: [Error] (14787:20): Invalid number of parameters in script C:\Program Files\SCAR 2.03\Scripts\PieBoner.scar

    SCRIPT:
    SCAR Code:
    program PieBoner;
    {.include SRL/SRL.scar}
    //Stand near a place with some monsters, that are not high level.
    //Don't have anything with you, maybe just like a scimmy.
    Const
    BoneColor = 14342878;//The color of the bones dont change.
    BonesToBury = 10;//How many bones you want to bury.
    MonsterColor = 0;//The color of the monster.
    Monster = 'eag';//3 letters of the monster's name you want to fight
    NumberOfUsers = 1;//How many players you are using.
    Var
    BonesDone: Integer;

    Procedure DeclarePlayers;
    Begin
       HowManyPlayers:= NumberOfUsers;
       NumberOfPlayers( HowManyPlayers );
       CurrentPlayer := 0;

       Players[0].Name :='Username';//Your runescape username
       Players[0].Pass :='Password';//Your runescape password
       Players[0].Nick :='ser';//3 Letters of your username.Username = ser.
       Players[0].Loc :='Bank';
       Players[0].Active:=True;
       
       end;

    Procedure Kill;
    begin
    repeat
    FindColor(x,y,MonsterColor,0,0,450,450);
    MMouse(x,y,1,1);
    Until (IsUpText(Monster));
    if (IsUpText(Monster))then
    Mouse(x,y,2,2,false);
    Wait(1000+random(450));
    ChooseOption('ack');
    end;

    Procedure FindBones;
    begin
    repeat
    FindColor(x,y,BoneColor,0,0,450,450);
    MMouse(x,y,1,1);
    Until (IsUpText('one');
    if (IsUpText('one')then
    Mouse(x,y,1,1,false);
    Wait(1000+random(300));
    ChooseOption(x,y,'ury');
    end;

    Function FindFastRandoms: Boolean;    // By WT-Fakawi.
    var
      i: Integer;
    begin
      for i:=1 to 11 do
      begin
        case I of
           1:  If FindDead then
                 Result := True;
           2:  If FindMod then
                 Result := True;
           3:  If FindMime then
                 Result := True;
           4:  If FindMaze then
                 Result := True;
           5:  If FindQuiz then
                 Result := True;
           6:  If FindDemon then
                 Result := True;
           7:  if NoGameTab then
                 begin
                   Result := True;
                   Players[CurrentPlayer].loc := 'No GameTab';
                   Logout;
                   Exit;
                 end;
           8 : If RC Then Result := True;

           9: If FindTalk Then Result := True;

           10: If HandleTrade Then Result := True;
           11: ClickToContinue;
        End;
        Wait(1);
      end;
    end;

    Function FindFastRandoms: Boolean; //By WT-Fakawi.
    var
      i: Integer;
    begin
      for i := 1 to 8 do
      begin
        case I of
          1: if FindDead then
              Result := True;
          2: if FindMod then
              Result := True;
          3: if FindMime then
              Result := True;
          4: if FindMaze then
              Result := True;
          5: if FindQuiz then
              Result := True;
          6: if FindDemon then
              Result := True;
          7: begin
              if NoGameTab then
              begin
                Result := True;
                Players[CurrentPlayer].loc := 'No GameTab';
                Logout;
                Exit;
              end;
            end;
          7: begin
              if InBlack then
              begin
                Result := True;
                Players[CurrentPlayer].loc := 'InBlack';
                Logout;
                Exit;
              end;
            end;
          8: RC;
        end;
        wait(1);
      end;
    end;

    Procedure FindRandoms;
    begin
      FindFastRandoms;
      FindNormalRandoms;
    end;

    Procedure Report;
    begin
    ClearDebug;
    WriteLn('---PieBoner-----Report----------------');
    WriteLn('Running Time: ' + (TimeRunning) + '');
    WriteLn('Bones Buried: '+ (BonesToBury) +'');
    WriteLn('Monsters Pwned: '+ (BonesToBury) +'');
    WriteLn(':P:P:P:P:P:P:P:P:P:P:P:P:P:P:P:P:P:P:P:P:')
    end;

    begin
    SetupSRL;
    DeclarePlayers;
    if not LoggedIn then
    LoginPlayer
    repeat
    Kill;
    FindRandoms;
    FindBones;
    Until(BonesToBury = BonesDone);
    if (BonesToBury = BonesDone)then
    Report;
    Exit;
    TerminateScript;
    end.

    PLEASE SOMEONE I NEED DAMN HELP!


    Scripts made by me.
    PieShafter.Version 0.2. 100%Done!
    PieStringer.Version 0.1. 100%Done!
    PiePcAirRuneBuyer.Version 0.1. 100%Done!
    PieChestThiever.Version 0.1. 100%Done!
    Currently working on.
    PieBoner.Version 0.1. 95%Done!
    PieAirRuneBuyer.Version 0.2. 20%Done!

  2. #2
    Join Date
    Dec 2006
    Location
    Third rock from the sun.
    Posts
    2,510
    Mentioned
    4 Post(s)
    Quoted
    1 Post(s)

    Default

    SCAR Code:
    ChooseOption(x, y: Integer; txt: String): Boolean;

    See that? You had:

    SCAR Code:
    ChooseOption('ack');

    When you should have had something like this:

    SCAR Code:
    ChooseOption(x, y, 'ack');

    Have fun!

  3. #3
    Join Date
    Mar 2007
    Location
    In your computer
    Posts
    244
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Aight..Thanks lol but.. now i get this error
    Line 87: [Error] (14837:10): Duplicate identifier 'FINDFASTRANDOMS' in script C:\Program Files\SCAR 2.03\Scripts\PieBoner.scar

    Help?

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Line 135: [Error] (14845:1): Syntax error in script
    By AbsTrACt'^.| in forum OSR Help
    Replies: 16
    Last Post: 05-23-2008, 01:14 PM
  2. Replies: 5
    Last Post: 02-26-2008, 04:14 PM
  3. Error: Cannot Fix Script - Error Overgrowth - Begin Headdesking
    By PhantasmalScripter in forum OSR Help
    Replies: 6
    Last Post: 12-23-2006, 12:50 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
  •