Results 1 to 3 of 3

Thread: Started work on my powercutter and...

  1. #1
    Join Date
    Feb 2007
    Location
    South East England
    Posts
    2,906
    Mentioned
    2 Post(s)
    Quoted
    8 Post(s)

    Default Started work on my powercutter and...

    I get this error with this part:

    Line 591: [Error] (13455:38): 'THEN' expected in script

    and its like.. Well there is a THEN!! Look THERE!! >.>

    SCAR Code:
    procedure RepeatThis;
    begin
     
      if Players[CurrentPlayer].Strings[1] := 'normal' then
      begin
      Writeln('Chopping Normal Trees - You have to start somewhere! :D');
        repeat
        ChopNormalTrees;
        PowerDrop;
        ToFProggy;
        SRLRandomsReport;
        until(False)
      end;
     
      if (Players[CurrentPlayer].Strings[1] := 'oak') then
      begin
      Writeln('Chopping Normal Trees - You have to start somewhere! :D');
        repeat
        ChopOakss;
        PowerDrop;
        ToFProggy;
        SRLRandomsReport;
        until(False)
      end;
     
      if (Players[CurrentPlayer].Strings[1] := 'willow') then
      begin
      Writeln('Chopping Willow Trees - Smart! Good exp and not too much of a watse :D');
        repeat
        ChopWillows;
        PowerDrop;
        ToFProggy;
        SRLRandomsReport;
        until(False)
      end;
     
      if (Players[CurrentPlayer].Strings[1] := 'maple') then
      begin
      Writeln('Chopping Maple Trees - You could loose some money :D');
        repeat
        ChopMaples;
        PowerDrop;
        ToFProggy;
        SRLRandomsReport;
        until(False)
      end;
     
      if (Players[CurrentPlayer].Strings[1] := 'yew') then
      begin
      Writeln('Chopping Yew Trees - Kinda a waste of money :D');
        repeat
        ChopYewTrees;
        PowerDrop;
        ToFProggy;
        SRLRandomsReport;
        until(False)
      end;
     
      if (Players[CurrentPlayer].Strings[1] := 'magic') then
      begin
      Writeln('Chopping Magic Trees - Are you mad?! 0_o');
        repeat
        ChopMagicTrees;
        PowerDrop;
        ToFProggy;
        SRLRandomsReport;
        until(False)
      end;

      if (Players[CurrentPlayer].Strings[1] := 'any') then
      begin
      Writeln('Chopping Any Tree - Not too picky eh?');
        repeat
        CutAnyTree;
        PowerDrop;
        ToFProggy;
        SRLRandomsReport;
        until(False)
      end;

      if (LoadsNum2=Players[CurrentPlayer].Integers[0]) then
        begin
          NextPlayer(True);
          LoadsNum2 := 0;
          MakeCompass('S')
          Writeln('Players Switched successfully')
        end;
    end;
    Jus' Lurkin'

  2. #2
    Join Date
    Nov 2007
    Location
    Chile
    Posts
    1,901
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Your :
    SCAR Code:
    (Players[CurrentPlayer].Strings[1] := 'willow')

    Correct :
    SCAR Code:
    (Players[CurrentPlayer].Strings[1] = 'willow')

    := is for declaring something, not =

    And you should use cases there.


  3. #3
    Join Date
    Feb 2007
    Location
    South East England
    Posts
    2,906
    Mentioned
    2 Post(s)
    Quoted
    8 Post(s)

    Default

    I tried cases but they didnt work. It logged in zoomed around the mouse for ages then logged out and ended.

    I had:

    SCAR Code:
    case LowerCase (Players[CurrentPlayer].Strings[1]) of
      'normal': ChopAnyTree;
      'oak': ChopOaks;

    etc.. But it didnt work, like I said.
    Jus' Lurkin'

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. just started
    By aznsensation in forum Who Are You ? Who ? Who ?
    Replies: 1
    Last Post: 07-05-2008, 05:38 PM
  2. Who got you started?
    By gothguydante in forum News and General
    Replies: 22
    Last Post: 12-06-2007, 08:52 PM
  3. Please Help Me Getting Started.
    By XxtOmxX in forum OSR Help
    Replies: 14
    Last Post: 06-02-2007, 06:34 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
  •