Results 1 to 8 of 8

Thread: Failed when compiling [Error] (18058:22): Invalid number of parameters in sc

  1. #1
    Join Date
    Aug 2006
    Posts
    151
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default Failed when compiling [Error] (18058:22): Invalid number of parameters in sc

    It keeps giving me an invlaid number of paraments in script but im pretty sure that its thr gith number so i dont know why its doing this feel free to point out other errors in script to because i jsut threw it together

    PS. I put
    SCAR Code:
    //probs here
    where the problem is below if u cnat find it


    SCAR Code:
    procedure FlyFish;
    begin
    if (FindDTM(Fish, x, y, MSX1, MSY1, MSX2, MSY2)) then
        MMouse(x, y, 5, 5);
      if (IsUpText('Fly Fishing')) then
      FishingSpots := FishingSpots +1
        Mouse(x, y, 5, 5, True);
      FindFishingEquipment;
      HandleWhirlPool;
      FindRandoms;
      Ban;
       if(invFull) then
       Dropit;
      end;
       begin
       if (not(FindDTM(Fish)))then//probs here
       FindSymbol(x,y, 'water source')) then
       wait(300+random(110))
       Mouse(x,y,1,1,true)
       Flag;
       Atempts := Atempts + 1
       until if (FindDTM(Fish, x, y, MSX1, MSY1, MSX2, MSY2)) then
        MMouse(x, y, 5, 5);
      if (IsUpText('Fly Fishing')) then
      FishingSpots := FishingSpots +1
        Mouse(x, y, 5, 5, True);
      FindFishingEquipment;
      HandleWhirlPool;
      FindRandoms;
      Ban;
       if(invFull) then
       Dropit;
       or
       (Atempts > 5)
       end;
       begin
       if (Atempts > 5)then
       Writeln('Couldnt Find Fishing Spot Reposition Player')
       NextPlayer(False);
    end;

  2. #2
    Join Date
    Sep 2006
    Posts
    916
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    if (not(FindDTM(Fish)))then//probs here

    You put to many close things, AND you dont have enough params.

    Try this:

    If(not(FindDTM(Fish, x, y, MSX1, MSY1, MSX2, MSY2)))Then


    Also, this will present another problem:

    until if (FindDTM(Fish, x, y, MSX1, MSY1, MSX2, MSY2)) then

    Do this:

    until(FindDTM(Fish, x, y, MSX1, MSY1, MSX2, MSY2))

  3. #3
    Join Date
    Aug 2006
    Posts
    151
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    ok another identifier expected problem look below

    probs at the or at the end

    SCAR Code:
    procedure FlyFish;
    begin
    if (FindDTM(Fish, x, y, MSX1, MSY1, MSX2, MSY2)) then
        MMouse(x, y, 5, 5);
      if (IsUpText('Fly Fishing')) then
      FishingSpots := FishingSpots +1
        Mouse(x, y, 5, 5, True);
      FindFishingEquipment;
      HandleWhirlPool;
      FindRandoms;
      Ban;
       if(invFull) then
       Dropit;
      end;
       begin
       If(not(FindDTM(Fish, x, y, MSX1, MSY1, MSX2, MSY2)))Then
       if(FindSymbol(x,y, 'water source')) then
       wait(300+random(110))
       MMouse(x,y,1,1)
       Mouse(x,y,1,1,true)
       Flag;
       Atempts := Atempts + 1
       if(FindDTM(Fish, x, y, MSX1, MSY1, MSX2, MSY2)) then
        MMouse(x, y, 5, 5);
      if(IsUpText('Fly Fishing')) then
      FishingSpots := FishingSpots +1
        Mouse(x, y, 5, 5, True);
      FindFishingEquipment;
      HandleWhirlPool;
      FindRandoms;
      Ban;
       if(invFull) then
       Dropit;
       or//prob here
       (Atempts > 5)
       end;
       begin
       if (Atempts > 5)then
       Writeln('Couldnt Find Fishing Spot Reposition Player')
       NextPlayer(False);
    end;
       begin
        if(not(FindSymbol(x,y, 'water source')) then
        Writeln('Where da Fuck are you')
        NextPlayer(False);
       end;

  4. #4
    Join Date
    Sep 2006
    Posts
    916
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    if(invFull) Then
    DropIt;
    If(Atempts > 5)Then
    Exit;

  5. #5
    Join Date
    Sep 2006
    Posts
    5,219
    Mentioned
    4 Post(s)
    Quoted
    1 Post(s)

    Default

    Maybe you mean

    if ((invFull) or (Atempts > 5)) then
    Dropit;

    You are using if then wrong, see drigers tutorial.exe for multiple conditions in an if statement.

  6. #6
    Join Date
    Aug 2006
    Posts
    151
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Ok i fixed that up i just acidently copied and pasted procedure back into it but i have yet another problem with one of my failsafish things here it is

    begin
    if(not(FindSymbol(x,y, 'water source')) then
    Writeln('Where da Fuck are you');
    Players[currentplayer].active:=false;
    NextPlayer(False);
    end;

    error=
    Identifier expected
    and it also says close round expected but when i add another ) it says^

  7. #7
    Join Date
    Sep 2006
    Posts
    5,219
    Mentioned
    4 Post(s)
    Quoted
    1 Post(s)

    Default

    SCAR Code:
    begin
      if not(FindSymbol(x,y, 'water source')) then
      begin
        Writeln('Where da Fuck are you');
        Players[currentplayer].active:=false;
        NextPlayer(False);
      end;
    end;

  8. #8
    Join Date
    Aug 2006
    Posts
    151
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    ok last error i hope


    it makes no sence at all its in main loop



    here what it keeps saying for error

    SCAR Code:
    [Error] (18109:4): Identifier expected


    SCAR Code:
    begin
     DeclarePlayers;
     beginscript;
     Setup;
     repeat
     FlyFish;
     if(LoggedIn)
        and(LoadsDroped > LoadsToComplete)then
          begin
          ProgressReport;
            LogOut;
            Wait(500);
            NextPlayer(True);
            end;
        if(FindDead)
        or(InBlack)then
          Players[currentplayer].active:=false;
          begin
           NextPlayer(False);
           end;
            begin
             if(not(loggedIn)) then Exit;
             end;
     until (False)
    end.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 9
    Last Post: 12-29-2008, 12:24 PM
  2. Invalid number of parameters error??
    By Bonfield in forum OSR Help
    Replies: 5
    Last Post: 03-01-2008, 12:05 PM
  3. Invalid Number of Parameters Error
    By jmoney343 in forum OSR Help
    Replies: 7
    Last Post: 05-07-2007, 01:22 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
  •