Results 1 to 4 of 4

Thread: stuck on error

  1. #1
    Join Date
    Dec 2007
    Location
    FL, USA
    Posts
    149
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default stuck on error

    i get this error

    Line 22: [Error] (14802:1): Identifier expected in script

    script of course isnt done yet this is what i got so far





    program YakkysFlaxSpinner;

    {.include SRL/SRL.scar}
    {.include SRL/SRL/skill/crafting.scar}

    //V .1 writing needs testing

    Var

    ////////////////////////////
    ////Standard SRL login//////
    ////////////////////////////
    Procedure DeclarePlayers;
    begin
    SRLID := '';
    SRLPassword := '';
    HowManyPlayers := 1;//How many players you want
    CurrentPlayer := 0;//Current player
    NumberOfPlayers(HowManyPlayers);

    Players[0].Name := 'YourUsername';//Username of your character
    Players[0].Pass := 'YourPassword';//Password of your character
    Players[0].Nick := 'Nickname';//A few letters from your name, no capitals!
    Players[0].Skill:='crafting';// Enter the skill you want to use for genie lamps
    Players[0].Pin := 1234;// Enter your bank pin, if you have one.
    Players[0].Active := True;

    CheckUserNicks;
    end;

    ///////////////////////////////////
    //Procedure LoginWhich by Pwnaz0r//
    //Details: Starts up the script //
    ///////////////////////////////////
    Procedure LoginWhich(Player: integer);
    Begin
    if LoggedIn then exit;
    if Players[Player].Active = false then
    begin
    writeln('Changing player to active...');
    Players[Player].Active:= true;
    end;
    CurrentPlayer:= Player;
    LoginPlayer;
    End;

    procedure Loc(where: string);
    begin
    Players[CurrentPlayer].Loc:= where;
    Players[CurrentPlayer].Rand:= where;
    end;

    procedure PlayerSetup;
    begin
    NickNameBMP := CreateBitmapMaskFromText(Players[CurrentPlayer].Nick, UpChars);
    Players[CurrentPlayer].Integers[1] := 0;
    LampSkill := (Players[CurrentPlayer].Skill);
    end;


    ///////////////////////
    //////Proggy///////////
    ///////////////////////
    Procedure Report;
    Begin
    ClearReport;
    AddToReport('Yakky''s Flax Spinner);
    AddToReport('Ran for '+TimeRunning);
    AddToReport('Bowstrings Made: '+IntToStr(Totaldone));
    AddToReport('Fights found: '+IntToStr(Fights));
    AddToReport('Talked to '+IntToStr(NPCTalks)+' NPC''s');
    AddToReport('Gained '+IntToStr(DeXLevels)+' levels');
    End;


    Procedure Retrieve Colors;
    Begin
    if loggedout then exit;
    if LoggedIn then
    begin
    writeln('getting colors');
    findcolorspiral(x,y,3651023,589,222)

    end
    end;

    Procedure Start;
    SetAngle(High: Boolean)
    Getstat(<crafting>,true)
    LoadCraftingBitMaps;

    end
    end;

    procedure Setup;
    Begin
    ClearReport;
    ClearDebug;
    SetupSrl;
    ScriptID := '521';
    LoadSymbolBitmapColor('spin');
    Writeln('Yakkys flax spinner......HERE WE GO!!!');
    DeclarePlayers;
    PlayerSetup;
    if not FindRS then
    begin
    writeln('Could not find Runescape');
    TerminateScript;
    end;
    if not LoggedIn then LoginWhich(CurrentPlayer);
    SetAngle(High: Boolean);
    SetRun(True);
    End;



    if(LogOutWhenDone)then
    begin
    LogOut;
    Writeln('All Flax is bowstring');
    end;

    End.
    YAKKY

    LEGEND....WAIT FOR IT..........DARY!!!

  2. #2
    Join Date
    Dec 2007
    Posts
    103
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    The line 13-error (13 and not 22, I suppose?) is because of the var you've added but not used. Delete var if you're not declaring any variables.

    At line 65 you need an ending ' in your string:
    Code:
    AddToReport('Yakky''s Flax Spinner');
    In line 67 you have an integer called Totaldone but you have not declared it. Line 69 contains NPCTalks which isn't declared and at line 70 DeXLevels is not declared.

    The procedure Retrieve Colors should be RetrieveColors.
    Line 76 contains a variable, loggedout, which is not declared.

    You have not declared x and y for the FindColorSpiral in line 80.
    The procedure Start contains no begin and contains 2 end (one with a semicolon and one without).

    The SetAngle in line 87 should be SetAngle(True);
    In line 88 there's an error with Getstat which is not declared.
    Line 108 has the SetAngle-error again.

    There's no proper main loop!



    Phew! That took a while.
    This sentence is false.

  3. #3
    Join Date
    Dec 2007
    Location
    FL, USA
    Posts
    149
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    wow.... thanks alot
    YAKKY

    LEGEND....WAIT FOR IT..........DARY!!!

  4. #4
    Join Date
    Jul 2007
    Location
    Norway.
    Posts
    1,938
    Mentioned
    3 Post(s)
    Quoted
    0 Post(s)

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. stuck with first script
    By sjlou in forum OSR Help
    Replies: 10
    Last Post: 09-27-2007, 06:48 AM
  2. Stuck
    By RS Rebel in forum OSR Help
    Replies: 9
    Last Post: 07-03-2007, 09:27 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
  •