Results 1 to 6 of 6

Thread: Script Errors....

  1. #1
    Join Date
    Dec 2006
    Posts
    173
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default Script Errors....

    Well, After I finished Macho Chopper( Just need to post it after the update for SRL), I started working on my Oak Owner(Draynor). I finished everything and and gave the credits I needed to( for now) My problem is that I keep getting this error message:
    SCAR Code:
    Line 582: [Error] (15396:8): Identifier expected in script

    If you could help me fix it, that would be great( also explainations are cool)

    Also if there are more things to fix, it would be great if you could post those too.
    Starting to merchant, if you know of any good clans, PM me please.

  2. #2
    Join Date
    Jul 2007
    Posts
    137
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    i think there is something wrong with the auto responder because if you remove it, it skips it.. and moves to your many other errors
    Do not propose an idea of peculation without evidence of such action.

    http://cashcrate.com/704591 click here and make money!

  3. #3
    Join Date
    May 2006
    Posts
    1,230
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    SCAR Code:
    program OakOwner;
    {========================================}
    {    Macho Oak Owner BETA                }
    { By: Macho Man67                        }
    {========================================}
    {         Setup Information              }
    {  1) Set Client Window                  }
    {  2) Fill in Your Players at line       }
    {  3) Fill in Setup                      }
    {  4) Hit play and watch for first load  }
    {========================================}
    {          Extra Stuff:                  }
    { USE Runescape with Low detail          }
    { Have players with brightness set HIGH  }
    {========================================}
    {         Credits                        }
    {-The whole SRL Community                }
    {-JAD for his tutorials and JADSymbol    }
    { function.                              }
    {-WT-Fakawi for function findfastrandoms }
    {-YoHoJo for this ent finder             }
    {-_Charmz for his autoresponder          }
    {-SantaClause for his lumby detection    }
    {========================================}

    {==============Setup!!!!!================}
    Const
      OakColor1= 0000;//The Oak color
      OakColor2= 0000;//Antoher Oak color
      OakColor3= 0000;//Final Oak color
      LoadsToDo= 3;//Loads to do before player switching
      TypeOfTree='Oak';//DO NOT TOUCH THIS!!!
      AutoResp= True;// Auto Respond True or False?
      VersionN= 'BETA';// Don't Touch this either
    {===========End Of Setup=================}

    {.include SRL\SRL.SCAR}
    {.include SRL\SRL\Skill\Woodcutting.SCAR}
    {.include SRL\SRL\extended\XInventory.Scar}

    Var
      RegAxe, BrokenAxe, OakLog : Integer;
      TreeSpot, TreeSpotTwo, House : Integer;
      Loads, EntsFound, Tries, TotalLoad, TotalLoads, TotalXPG, BeginXP, EndXP : Integer;
      Chat, Name, ChatName: String;
      {frmDesign : TForm;
      UserLabel1 : TLabel;
      Label1 : TLabel;
      Label2 : TLabel;
      Label3 : TLabel;
      Label4 : TLabel;
      UserEdit1 : TEdit;
      PassEdit1 : TEdit;
      StartButton : TButton;
      ActiveCombo : TComboBox;
      Username, Password : String;
      ActiveC : Boolean;}


    procedure DeclarePlayers;
    begin

      HowManyPlayers := 4;
      NumberOfPlayers(HowManyPlayers);
      CurrentPlayer := 0;

      Players[0].Name := '';// Your Username
      Players[0].Pass := '';// Your Password
      Players[0].Nick := '';// 3-4 letters of your Username
      Players[0].Active:=True;//Active True or False
      Players[0].Boolean1 := True;// True if axe equiped , false if in inventory
      Players[0].Boolean2 := False;// True to powerchopper, False to bank logs
      Players[0].Integer1 := 1;// 1 to walk to oaks near bank, two to go to oaks near willows

      Players[1].Name := '';// Your Username
      Players[1].Pass := '';// Your Password
      Players[1].Nick := '';// 3-4 letters of your Username
      Players[1].Active:=True;//Active True or False
      Players[1].Boolean1 := True;// True if axe equiped , false if in inventory
      Players[1].Boolean2 := False;// True to powerchopper, False to bank logs
      Players[1].Integer1 := 1;// 1 to walk to oaks near bank, 2 to go to oaks near willows

      Players[2].Name := '';// Your Username
      Players[2].Pass := '';// Your Password
      Players[2].Nick := '';// 3-4 letters of your Username
      Players[2].Active:=True;//Active True or False
      Players[2].Boolean1 := True;// True if axe equiped , false if in inventory
      Players[2].Boolean2 := False;// True to powerchopper, False to bank logs
      Players[2].Integer1 := 1;// 1 to walk to oaks near bank, 2 to go to oaks near willows

      Players[3].Name := '';// Your Username
      Players[3].Pass := '';// Your Password
      Players[3].Nick := '';// 3-4 letters of your Username
      Players[3].Active:=True;//Active True or False
      Players[3].Boolean1 := True;// True if axe equiped , false if in inventory
      Players[3].Boolean2 := False;// True to powerchopper, False to bank logs
      Players[3].Integer1 := 1;// 1 to walk to oaks near bank, 2 to go to oaks near willows

      NickNameBMP := CreateBitmapMaskFromText(Players[CurrentPlayer].Nick, UpChars);

    end;

    {==============================================================================}
    {!!!!!!Do NOT Touch Below This Except If You Know What You Are Doing!!!!!!!!!!!}
    {==============================================================================}

    {++++++++++++++++++++++++++++++++++++++++}
    {       My Signature                     }
    {++++++++++++++++++++++++++++++++++++++++}
    procedure Signature;
    begin
      ClearDebug;
      Writeln('     _  _                          ');
      Writeln('    / \/ \                         ');
      Writeln('   /      \                        ');
      Writeln('  /___/\___\acho Man67             ');
      Writeln('                                   ');
      Wait(750 + random(550));
      ClearDebug;
      Writeln('     _  _                          ');
      Writeln('    / \/ \                         ');
      Writeln('   /      \                        ');
      Writeln('  /___/\___\acho Man67             ');
      Writeln('       Presents  You:              ');
      Wait(2000 + random(550));
      ClearDebug;
      Writeln('  _____      _____                 ');
      Writeln(' /  _  \    /  _  \                ');
      Writeln(' | | | |    | | | |                ');
      Writeln(' | |_| |ak  | |_| |wner            ');
      Writeln(' \_____/    \_____/                ');
      Wait(2000 + random(550));
    end;

    {++++++++++++++++++++++++++++++++++++++++}
    {      DTM'S And Bitmaps                 }
    {++++++++++++++++++++++++++++++++++++++++}
    procedure LoadDTMsAndBMPs;
    begin

      RegAxe := DTMFromString('78DA6394636060D0604001618E9C0C0F81342' +
           '310FF0702463D204396010D302291405A0948481250230D248C09' +
           'A8D1021252F8D50000C9DE06EA');

      BrokenAxe := DTMFromString('78DA63E4676060E06640016D29BC0CBF80342' +
           '310FF07024609208383010D302291405A1A48B01250230A245888' +
           '30879B801A907B7809A801F98B9F801A90192204D480DC2249400' +
           'D286C648950234E400D0F117E07F98919BF1A00D64B07A2');

      OakLog := DTMFromString('78DA63746362606862644006FD798E0C2C401' +
           'A24FA1F0818BD806A2A51D54064612490F6C33407434D10504D07' +
           '11E6F410500372731F0135CE4035FD04D4D801D54C24A0C60AA8A' +
           '697801A1322FC650154D340847B6A08A87105AAA9C6AF060058A4' +
           '0FC5');
    end;

    {++++++++++++++++++++++++++++++++++++++++}
    { My Basic Form: Still Under Construction}
    {++++++++++++++++++++++++++++++++++++++++}
    {procedure StartClick(sender: TObject);
    begin
      Writeln('Hello world');
      Username := UserEdit.Text;
      Password := PassEdit.Text;
      ActiveC:=StrToBool(ActiveCombo.text);
      frmDesign.ModalResult:= mrOk;
    end;

    procedure InitForm;
    begin
    frmDesign := CreateForm;
    frmDesign.Left := 250;
    frmDesign.Top := 123;
    frmDesign.Width := 365;
    frmDesign.Height := 313;
    frmDesign.Caption := 'frmDesign';
    frmDesign.Color := clSilver;
    frmDesign.Font.Color := clWindowText;
    frmDesign.Font.Height := -13;
    frmDesign.Font.Name := 'MS Sans Serif';
    frmDesign.Font.Style := [];
    frmDesign.ShowHint := True;
    frmDesign.Visible := True;
    frmDesign.PixelsPerInch := 96;
    UserLabel1 := TLabel.Create(frmDesign);
    UserLabel1.Parent := frmDesign;
    UserLabel1.Left := 37;
    UserLabel1.Top := 61;
    UserLabel1.Width := 63;
    UserLabel1.Height := 16;
    UserLabel1.Caption := 'Username';
    UserLabel1.Font.Color := clWindowText;
    UserLabel1.Font.Height := -13;
    UserLabel1.Font.Name := 'MS Sans Serif';
    UserLabel1.Font.Style := [];
    UserLabel1.ParentFont := False;
    Label1 := TLabel.Create(frmDesign);
    Label1.Parent := frmDesign;
    Label1.Left := 39;
    Label1.Top := 99;
    Label1.Width := 60;
    Label1.Height := 16;
    Label1.Caption := 'Password';
    Label2 := TLabel.Create(frmDesign);
    Label2.Parent := frmDesign;
    Label2.Left := 114;
    Label2.Top := 11;
    Label2.Width := 100;
    Label2.Height := 31;
    Label2.Caption := 'Macho'#39's';
    Label2.Font.Color := clWindowText;
    Label2.Font.Height := -27;
    Label2.Font.Name := 'Microsoft Sans Serif';
    Label2.Font.Style := [];
    Label2.ParentFont := False;
    Label3 := TLabel.Create(frmDesign);
    Label3.Parent := frmDesign;
    Label3.Left := 75;
    Label3.Top := 226;
    Label3.Width := 61;
    Label3.Height := 38;
    Label3.Caption := 'Oak';
    Label3.Font.Color := clWindowText;
    Label3.Font.Height := -33;
    Label3.Font.Name := 'Microsoft Sans Serif';
    Label3.Font.Style := [];
    Label3.ParentFont := False;
    Label4 := TLabel.Create(frmDesign);
    Label4.Parent := frmDesign;
    Label4.Left := 163;
    Label4.Top := 227;
    Label4.Width := 97;
    Label4.Height := 38;
    Label4.Caption := 'Owner';
    Label4.Font.Color := clWindowText;
    Label4.Font.Height := -33;
    Label4.Font.Name := 'Microsoft Sans Serif';
    Label4.Font.Style := [];
    Label4.ParentFont := False;
    UserEdit1 := TEdit.Create(frmDesign);
    UserEdit1.Parent := frmDesign;
    UserEdit1.Left := 108;
    UserEdit1.Top := 58;
    UserEdit1.Width := 121;
    UserEdit1.Height := 24;
    UserEdit1.Hint := 'username';
    UserEdit1.TabOrder := 8;
    UserEdit1.Text := 'UserEdit1';
    PassEdit1 := TEdit.Create(frmDesign);
    PassEdit1.Parent := frmDesign;
    PassEdit1.Left := 109;
    PassEdit1.Top := 95;
    PassEdit1.Width := 121;
    PassEdit1.Height := 24;
    PassEdit1.Hint := 'password';
    PassEdit1.TabOrder := 9;
    PassEdit1.Text := 'PassEdit1';
    StartButton := TButton.Create(frmDesign);
    StartButton.Parent := frmDesign;
    StartButton.OnClick := @StartClick;
    StartButton.Left := 115;
    StartButton.Top := 175;
    StartButton.Width := 105;
    StartButton.Height := 39;
    StartButton.Caption := 'Start!!!';
    StartButton.TabOrder := 10;
    ActiveC := TComboBox.Create(frmDesign);
    .Parent := frmDesign;
    .Left := 109;
    .Top := 141;
    .Width := 118;
    .Height := 24;
    .Hint := 'Active';
    .ItemHeight := 16;
    .TabOrder := 11;
    .Items.Add('True');
    .Items.Add('False');
    end;

    procedure SafeInitForm;
    var
      v: TVariantArray;
    begin
      setarraylength(V, 0);
      ThreadSafeCall('InitForm', v);
    end;

    procedure ShowFormModal;
    begin
      frmDesign.ShowModal;
    end;

    procedure SafeShowFormModal;
    var
      v: TVariantArray;
    begin
      setarraylength(V, 0);
      ThreadSafeCall('ShowFormModal', v);
    end;}


    {++++++++++++++++++++++++++++++++++++++++}
    {       FindFastRandoms By: WT-Fakawi    }
    {++++++++++++++++++++++++++++++++++++++++}
    function FindFastRandoms: Boolean;
    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;

    {++++++++++++++++++++++++++++++++++++++++}
    {   Lumbridge Detection By: SantaClause  }
    {++++++++++++++++++++++++++++++++++++++++}
    function DetectLumby : Boolean;
    var
      rx, ry : Integer;
    begin
      Result := (GetSymbolColor(rx, ry, 'water source') > 0) or
                (GetSymbolColor(rx, ry, 'guide') > 0);
      if not result then
      NextPlayer(False);
    end;

    {++++++++++++++++++++++++++++++++++++++++}
    {      My Anti Randoms Procedure         }
    {++++++++++++++++++++++++++++++++++++++++}
    procedure KillAntiRandoms;
    begin
      if(not(LoggedIn))then
      Exit;
      FindTalk;
      DetectLumby;
      FindNormalRandoms;
      if (FindFight = true) then
      begin
        RunAwayDirection('N');
        Wait(10000 + random(3005));
        RunBack;
        FindFastRandoms;
        FindTalk;
        DetectLumby;
      end;
    end;

    {++++++++++++++++++++++++++++++++++++++++}
    {       My Anti Ban                      }
    {++++++++++++++++++++++++++++++++++++++++}
    procedure TheAntiBan;
    begin
      If(not(LoggedIn)) then
      Exit;
      case Random(60) of
      0: MouseBox(MIx1, MIy1, MIx2, MIy2, 3);
      1: MouseBox(MSx1, MSy1, MSx2, MSy2, 3);
      2: FindFastRandoms;
      3: PickUpMouse;
      4: begin
           HoverSkill('Woodcutting', False);
           wait(2000+random(2000));
           GameTab(4);
         end;
      5: BoredHuman;
      6: AlmostLogout;
      7: begin
           HoverSkill('Attack', False);
           wait(2000+random(2000));
           GameTab(4);
         end;
      8: begin
           HoverSkill('Strength', False);
           wait(1000+random(2000));
           GameTab(4);
         end;
      9: begin
           HoverSkill('Defence', False);
           wait(1000+random(2000));
           GameTab(4);
          end;
      10: begin
            HoverSkill('Range', False);
            wait(1000+random(2000));
            GameTab(4);
          end;
      11: begin
            HoverSkill('Prayer', False);
            wait(1000+random(2000));
            GameTab(4);
          end;
      12: begin
            HoverSkill('Magic', False);
            wait(1000+random(2000));
            GameTab(4);
          end;
      13: begin
            HoverSkill('Runecraft', False);
            wait(1000+random(2000));
            GameTab(4);
          end;
      14: begin
            HoverSkill('Construction', False);
            wait(1000+random(2000));
            GameTab(4);
          end;
      15: begin
            HoverSkill('Hitpoints', False);
            wait(1000+random(2000));
            GameTab(4);
          end;
      16: begin
            HoverSkill('Agility', False);
            wait(1000+random(2000));
            GameTab(4);
          end;
      17: begin
            HoverSkill('Herblore', False);
            wait(1000+random(2000));
            GameTab(4);
          end;
      18: begin
            HoverSkill('Thieving', False);
            wait(1000+random(2000));
            GameTab(4);
          end;
      19: begin
            HoverSkill('Crafting', False);
            wait(1000+random(2000));
            GameTab(4);
          end;
      20: begin
            HoverSkill('Fletching', False);
            wait(1000+random(2000));
            GameTab(4);
          end;
      21: begin
            HoverSkill('Slayer', False);
            wait(1000+random(2000));
            GameTab(4);
          end;
      22: begin
            HoverSkill('Hunting', False);
            wait(1000+random(2000));
            GameTab(4);
          end;
      23: begin
            HoverSkill('Mining', False);
            wait(1000+random(2000));
            GameTab(4);
          end;
      24: begin
            HoverSkill('Smithing', False);
            wait(1000+random(2000));
            GameTab(4);
          end;
      25: begin
            HoverSkill('Fishing', False);
            wait(2000+random(1000));
            GameTab(4);
          end;
      26: begin
            HoverSkill('Cooking', False);
            wait(1000+random(2000));
            GameTab(4);
          end;
      27: begin
            HoverSkill('Firemaking', False);
            wait(2000+random(1000));
            GameTab(4);
          end;
      28: begin
            HoverSkill('Farming', False);
            wait(1000+random(2000));
            GameTab(4);
          end;
      29: begin
            HoverSkill('random', False);
            wait(2000+random(1000));
            GameTab(4);
          end;
      30: begin
            GameTab(5);
            wait(1000+random(100));
            GameTab(4);
          end;
        end;
      KillAntiRandoms;
    end;

    {++++++++++++++++++++++++++++++++++++++++}
    {      Auto Responder By: _CHARMZ        }
    {++++++++++++++++++++++++++++++++++++++++}
    Function GetChatMessage(Text: String): Boolean;
    Var
    TX, TY: Integer;
    Chat: String;
    Begin

      If(IsTextInAreaEx(40, 415, 130, 415, TX, TY, ':', 0, SmallChars, False, True, 0, 0, 0))then
       Begin
        Chat:= Lowercase(Trim(GetTextAtEx(TX + 8, 415, 0, SmallChars, False, False, 0, 1, 16711680, 40, False, TR_AllChars)));

         If(Pos(Text, Chat) <> 0)then
          Begin
           Result:= True;
          End

       End

    End;

    Function GetChatName(Name: String): Boolean;
    Var
    I : Integer;
    ChatName : String;
    Begin

      ChatName := Lowercase(Trim(GetTextAtEx(21, 415, 0, SmallChars, False, False, 0, 0, 0, 50, False, TR_AllChars)));

      I:= Pos(':', ChatName);
      If(I <> 0)then
       Begin
         Delete(ChatName, I, I);
       End

      If(Pos(Name, ChatName) <> 0)then
       Begin
         Result:= True;
       End

    End;

    Function AutoRespond: Boolean;
    Var
    Responce, Lvl: String;
    RandomReply: Integer;
    Chat,Name,ChatName: String;
    Begin

    if(AutoResp=False)then
     begin
     Exit;
    end;

    if(AutoResp)then
    begin

      OldLine:= TheLine;
      TheLine:= Lowercase(Trim(GetTextAtEx(20, 415, 0, SmallChars, False, False, 0, 1, 16711680, 40, False, TR_AllChars)));

     If(GetChatName(Players[CurrentPlayer].Name))then
      Begin
       Exit;
      End

     If(OldLine=TheLine)then
      Begin
       Exit;
      End

      If(GetChatMessage(Players[CurrentPlayer].Name)) or (GetChatMessage(Players[CurrentPlayer].Nick))then
       Begin
         WriteLn(''+ChatName+': '+Chat);
         RandomReply:= Random(10)+1;
        Case (RandomReply) of
          0 : Responce:= ('?');
          1 : Responce:= ('what');
          2 : Responce:= ('yes');
          3 : Responce:= ('no');
          4 : Responce:= ('what do you want');
          5 : Responce:= ('me?');
          6 : Responce:= ('Yah?');
          7 : Responce:= ('who?');
          8 : Responce:= ('wha?');
          9 : Responce:= ('?');
          10 : Responce:= ('???');
        End
       TypeSend(Responce+' '+Name);
       Result:= True;
      End

      If(GetChatMessage('lol')) or (GetChatMessage('lmao')) or (GetChatMessage('rofl')) or (GetChatMessage('haha'))then
       Begin
        WriteLn(''+ChatName+': '+Chat);
        RandomReply:= Random(24)+1;
        Case (RandomReply) of
         0 : Responce:= ('heh');
         1 : Responce:= ('loll');
         2 : Responce:= ('lol');
         3 : Responce:= ('haha');
         4 : Responce:= ('hihi');
         5 : Responce:= ('ehe');
         6 : Responce:= ('lmao');
         7 : Responce:= ('lmfao');
         8 : Responce:= ('rofls');
         9 : Responce:= ('fun');
         10 : Responce:= ('nice');
         11 : Responce:= ('lolz');
         12 : Responce:= ('yep');
         13 : Responce:= ('hola');
         14 : Responce:= ('wow');
         15 : Responce:= ('i bet');
         16 : Responce:= ('rofl');
         17 : Responce:= ('ghehehghehighhe');
         18 : Responce:= ('cool');
         19 : Responce:= ('...');
         20 : Responce:= ('???');
         21 : Responce:= ('wow');
         22 : Responce:= ('grr..');
         23 : Responce:= ('rowr');
         24 : Responce:= ('lolololololol');
         25 : Responce:= ('ha ha ha!!!');
        End
       TypeSend(Responce);
       Result:= True;
      End


      If(GetChatMessage('wc')) or (GetChatMessage('woodcutting')) or (GetChatMessage('woodcuttin')) And
        (GetChatMessage('lvl')) or (GetChatMessage('level')) or (GetChatMessage('lvls')) or (GetChatMessage('levels'))then
       Begin
        WriteLn(''+ChatName+': '+Chat);
        Lvl:= IntToStr(GetSkillLevel('woodcutting'));
        RandomReply:= Random(5)+1;
         Case (RandomReply) of
          0 : Responce:= ('i''m lvl '+Lvl+' woodcuttin');
          1 : Responce:= ('level '+Lvl+' wc');
          2 : Responce:= ('lvl '+Lvl+' woodcut!');
          3 : Responce:= (+Lvl);
          4 : Responce:= ('i''m level '+lvl);
          5 : Responce:= (+Lvl+' here :P');
         End
        TypeSend(Responce);
        Result:= True;
       End

      If(GetChatMessage('wat')) or (GetChatMessage('what')) and (GetChatMessage('doin')) or (GetChatMessage('doing'))then
       Begin
       WriteLn(''+ChatName+': '+Chat);
       RandomReply:= Random(9)+1;
        Case RandomReply of
         0 : Responce:= ('not much');
         1 : Responce:= ('nothing');
         2 : Responce:= ('bored');
         3 : Responce:= ('aye?');
         4 : Responce:= ('emmm..nothin');
         5 : Responce:= ('nope');
         6 : Responce:= ('booo');
         7 : Responce:= ('no ty');
         8 : Responce:= ('what');
         9 : Responce:= ('....');
         10 : Responce:= ('nothin');
        End;
       TypeSend(Responce);
       Result:= True;
      End;

      If(GetChatMessage('hey')) or (GetChatMessage('hi')) or (GetChatMessage('hello')) or (GetChatMessage('wats up')) or (GetChatMessage('whats up')) or (GetChatMessage('yo'))then
       Begin
       WriteLn(''+ChatName+': '+Chat);
       RandomReply:= random(9)+1;
        Case RandomReply of
          0 : Responce:= ('hello');
          1 : Responce:= ('wassup');
          2 : Responce:= ('yo');
          3 : Responce:= ('whats up everyone');
          4 : Responce:= ('whats up');
          5 : Responce:= ('welcome');
          6 : Responce:= ('hello hello');
          7 : Responce:= ('wat up');
          8 : Responce:= ('yo');
          9 : Responce:= ('sup?');
          10 : Responce:= ('whats up');
        end
       TypeSend(Responce);
       Result:= True;
      end
     end;
    end;

    {++++++++++++++++++++++++++++++++++++++++}
    {       Ent Finder By: YoHoJo            }
    {++++++++++++++++++++++++++++++++++++++++}

    Procedure EntChecker;
    Var
      EX, EY : integer;
      FX, FY : integer;
    Begin
      Status('Checking For Ent')
      Flag;
      if (FindObjMultiText(EX, EY, TypeOfTree, TypeOfTree, TypeOfTree, OakColor1, 10)) or
        (FindObjMultiText(EX, EY, TypeOfTree, TypeOfTree, TypeOfTree, OakColor2, 10))  or
        (FindObjMultiText(EX, EY, TypeOfTree, TypeOfTree, TypeOfTree, OakColor3, 10))  then
      Begin
        MMouse(EX, EY, 0, 0)
        If FindColorTolerance( FX, FY, 55769, 85, 15, 115, 15, 20) then
        Begin
          Writeln('Ent Found');
          MouseFindFlag(648,83,5,5);
          Wait(15000+Random(5000));
          EntsFound := EntsFound + 1
        end;
      end;
    end;

    {++++++++++++++++++++++++++++++++++++++++}
    {     Walks to The Oak Tree ( Option 1 ) }
    {++++++++++++++++++++++++++++++++++++++++}

    Procedure WalkToOakOne;
    var
      XX, YY : Integer;
      TreeSpotColor : integer;
    begin
      If(Players[CurrentPlayer].Integer1 = 1) then
      begin
        MakeCompass('N');
        TreeSpot := BitmapFromString(8,10, 'a6803978DAED943112C32' +
           '00C04BF2440025C8610FEFFA420C9C14CA8718AE88A2B6E0E2F1A' +
           'C000E0A383AE92BB45120FCFEE94E370C70110495E5EA3494D3A2' +
           '88987AB792027CE8FAF69AE89F6A93EBEF298C5010757D7FA8C17' +
           '5D88CA524A3A6455A1E19403E7893B891A7BE1267AD9150AD2643' +
           '26D1502BFF31A68F894B888791371E54EC4D9374E3A79FF7D05C0' +
           '2DF475C6E6EE987A3953E5AE749DFD4C769CF2E4F31ECE9DDC72C' +
           '303B9FAF13B5FD6AFB82693C9F43F7A0329B');

        TreeSpotColor := AutoColorThis(TreeSpot, 50, MMX1, MMY1, MMX2, MMY2);
        RadialWalk(TreeSpotColor, 0, 46, 18, 4, 4);
        Flag;
        Wait(200 + random(100));
        Tries := 0;
        repeat
          if(Tries = 45)then
          begin
            Writeln(' Machos Oak Owner Updated News:  ');
            Writeln('  Could not find the Oak Spot,   ');
            Writeln('       Switching Players..       ');
            NextPlayer(False);
          end;
          Wait(400 + random(100));
          Tries := Tries + 1;
        until (FindColorTolerance(XX, YY, OakColor1, MSX1, MSY1, MSX2, MSY2, 10)) or
        (FindColorTolerance(XX, YY, OakColor2, MSX1, MSY1, MSX2, MSY2, 10)) or
        (FindColorTolerance(XX, YY, OakColor3, MSX1, MSY1, MSX2, MSY2, 10));
        FreeBitmap(TreeSpot);
      end;
    end;

    {++++++++++++++++++++++++++++++++++++++++}
    {    Walks To The Oak Tree ( Spot #2 )   }
    {++++++++++++++++++++++++++++++++++++++++}


    procedure WalkToTreesTwo;
    Var
      XXX, YYY : Integer;
      TreeSpotTwoColor : integer;
    begin
      If(Players[CurrentPlayer].Integer1 = 2) then
      begin
        MakeCompass('N');
        Wait(100 + random(100));
        RadialRoadWalk(FindRoadColor, 280, 300, 62, 4, 4);
        TreeSpotTwo := BitmapFromString(7,7, 'a62BBA78DAED94510E8' +
           '4200C44AF54A015FC5C04EE7FA405EA226A341B8DB8D9381F1333' +
           '14FA401100A4B110155CB48E4C72354427D315172900A29C5B5F2' +
           'A29E41ACC89845229ED30CDEA318D0A5956E69C139E4BEEB5C83B' +
           '931DB030F05C697022C9DDB92F77D17D9E65A9381995729D6A348' +
           '5E416A77AAF4B8E43AAC43E915C24D1A1F9F86D728AE624B7F164' +
           '922D9E465415C33ECF38DA9CA4E6993D3794F2424427E10E2F81E' +
           '017FBAA92EF77C40C0749B8E39AE4D08D3845B2FBAEE32F4E0136' +
           'BA05EB730862E7642E57F58E98A4E6E193B9FC266E50D53C23557' +
           'B659253DFDEFF913C7AF4337A0331A');

        TreeSpotTwoColor := AutoColorThis(TreeSpotTwo, 50, MMX1, MMY1, MMX2, MMY2);
        RadialWalk(TreeSpotTwoColor, 296, 261, 42, 4, 4);
        Flag;
        Wait(200 + random(100));
        Tries := 0;
        repeat
          if(Tries = 45)then
          begin
            Writeln(' Machos Oak Owner Updated News  :  ');
            Writeln('  Could not find the Oak Spot #2   ');
            Writeln('       Switching Players..         ');
            NextPlayer(False);
          end;
          Wait(400 + random(100));
          Tries := Tries + 1;
        until (FindColorTolerance(XXX, YYY, OakColor1, MSX1, MSY1, MSX2, MSY2, 10)) or
        (FindColorTolerance(XXX, YYY, OakColor2, MSX1, MSY1, MSX2, MSY2, 10)) or
        (FindColorTolerance(XXX, YYY, OakColor3, MSX1, MSY1, MSX2, MSY2, 10));
        Writeln('Successfully walked to Trees! ');
        FreeBitmap(TreeSpot);
      end;
    end;

    {++++++++++++++++++++++++++++++++++++++++}
    {   Determines If There Is A Broken Axe  }
    {++++++++++++++++++++++++++++++++++++++++}


    procedure IsAxeBrokenNow;
    Var
      BX, BY : Integer;
      KX, KY : Integer;
    begin
      If(Players[CurrentPlayer].Boolean1 = True) then
      begin
        GameTab(5)
        wait(10+random(10));
        If(Not(FindDTM(BrokenAxe, Bx, BY, MIX1, MIY1, MIX2, MIY2 ))) and FindDTM(RegAxe, KX, KY, MIX1, MIY1, MIX2, MIY2 ) Then
        begin
          GameTab(4);
          Exit;
        end;
        begin
          GameTab(5);
          If(FindDTM(BrokenAxe, BX, BY, MIX1, MIY1, MIX2, MIY2 )) and Not(FindDTM(RegAxe, KX, KY, MIX1, MIY1, MIX2, MIY2 )) Then
          begin
            Writeln(' Axe is be broken, Switching players now ');
            NextPlayer (False);
          end;
          begin
            If(Players[CurrentPlayer].Boolean1 = False) then
            begin
              GameTab(4);
              If(Not(FindDTM(BrokenAxe, Bx, BY, MIX1, MIY1, MIX2, MIY2 ))) and FindDTM(RegAxe, KX, KY, MIX1, MIY1, MIX2, MIY2 ) Then
              begin
                Exit;
              end;
              begin
                If(FindDTM(BrokenAxe, BX, BY, MIX1, MIY1, MIX2, MIY2 )) and Not(FindDTM(RegAxe, KX, KY, MIX1, MIY1, MIX2, MIY2 )) Then
                begin
                  Writeln(' Axe is be broken, Switching players now ');
                  NextPlayer (False);
                end;
              end;
            end;
          end;
        end;
      end;
    end;

    {++++++++++++++++++++++++++++++++++++++++}
    {         Tree Chopping Procedure        }
    {++++++++++++++++++++++++++++++++++++++++}
    procedure FindingTheTree;
    begin
      MakeCompass('N');
      If(Not(LoggedIn)) then NextPlayer (False);
      repeat
        IsAxeBrokenNow;
        Wait(10+random(10));
        AutoRespond;
        If(Not(LoggedIn)) then Exit;
        EntChecker;
        if (FindColorTolerance(x, y, OakColor1, 160, 97, 516, 209, 4)) or
          (FindColorTolerance(x, y, OakColor2, 160, 97, 516, 209, 4))  or
          (FindColorTolerance(x, y, OakColor3, 160, 97, 516, 209, 4))  then
        begin
          If (FindObjMultiText(x, y, TypeOfTree, TypeOfTree, TypeOfTree, OakColor1, 10)) or
            (FindObjMultiText(x, y, TypeOfTree, TypeOfTree, TypeOfTree, OakColor2, 10))  or
            (FindObjMultiText(x, y, TypeOfTree, TypeOfTree, TypeOfTree, OakColor3, 10))  then
          begin
            MMouse(x, y, 4, 4);
            If IsUpTextMulti('hop', 'own', 'ak') then
            begin
              Mouse(x, y, 5, 5, True);
              EntChecker;
              repeat
                if (InvFull) or (InventoryCount = 28) or (PopUp('ontinue')) then
                  Exit;
                  KillAntiRandoms;
                  SleepAndMoveMouse(5000 + random(2000));
                  TheAntiBan;
                  Wait(10);
                  IsAxeBrokenNow;
                  Wait(10 + random(20));
                  AutoRespond;
              until (not (FindColorTolerance(x, y, OakColor1, 160, 97, 410, 340, 4))) or
                  (not (FindColorTolerance(x, y, OakColor2, 160, 97, 410, 340, 4)))or
                  (not (FindColorTolerance(x, y, OakColor3, 160, 97, 410, 340, 4)));
                If(Not(FindObjMultiText(x, y, TypeOfTree, TypeOfTree, TypeOfTree, OakColor1, 10))) then
                begin
                  Tries := Tries + 1;
                  If(Tries = 35) then
                  begin
                    Writeln('[]=================================[]');
                    Writeln('     /\  /\  Info:  ____             ');
                    Writeln('    /  \/  \       /  __|            ');
                    Writeln('   /        \      |  |              ');
                    Writeln('  /    /\    \     |  |_             ');
                    Writeln(' /____/  \____\acho\____|hopper      ');
                    Writeln('Could Not Find The Trees, Switching  ');
                    Writeln('        Players  Now....             ');
                    Wait(100+random(200));
                    NextPlayer (False);
                  end;
                end;
            end;
          end;
        end;
      until (InvFull) or (InventoryCount = 28);
    end;

    {++++++++++++++++++++++++++++++++++++++++}
    {        Dropping Procedure              }
    {++++++++++++++++++++++++++++++++++++++++}


    procedure DropTheLogs;
    var
      X3, Y3 :Integer;
    begin
      If(Players[CurrentPlayer].Boolean2 = True) then
      begin
        If(Not(LoggedIn)) then NextPlayer (false)
        If (InvFull) or (InventoryCount = 28) then
        repeat
          KillAntiRandoms;
          If (FindDTM(OakLog,X3,Y3, MIX1, MIY1, MIX2, MIY2)) then
          begin
            MMouse(x,y,3,3);
            wait(500+random(200));
            if (IsUpTextMulti('se',TypeOfTree,'log'))then
            begin
              Mouse(x,y,4,4,False);
              ChooseOption(x,y,'rop');
              TheAntiBan;
            end;
         end;
       until Not(FindDTM(OakLog,X3,Y3, MIX1, MIY1, MIX2, MIY2)) or (CountItemDTM(OakLog) = 0);
      Loads := Loads +1;
      TotalLoad := TotalLoad + 1;
      end;
    end;

    {********************************************************
    function JadSymbol(WhatSymbol: String; Click, Switch: Boolean): Boolean;
    By: JAD
    Description: My symbol finding. Repeats waiting and
    looking for symbol until found or took too long. Clicks
    the symbol if told to. Will switch players if it doesn't
    find the symbol if told to.
    ********************************************************}


    function JadSymbol(WhatSymbol: String; Click, Switch: Boolean): Boolean;
    var I: Integer;
    begin
      for I := 1 to 25 do
      begin
        if(FindSymbol(x,y,(WhatSymbol)))then
        begin
          if(Click)then
            Mouse(x,y,2,2,true);
          Result := True;
          Exit;
        end;
        wait(750+random(500));
      end;
      Writeln('Could NOT find symbol.');
      Result := False;
      if(Switch)then
        LogOut;
    end;

    {++++++++++++++++++++++++++++++++++++++++}
    {  Walk Bank Procedure For: Option 1     }
    {++++++++++++++++++++++++++++++++++++++++}

    procedure WalkBankOne;
    Var
      X1, Y1 : Integer;
    begin
      If(Players[CurrentPlayer].Integer1 = 1) then
      begin
        If (InvFull) or (InventoryCount = 28) then
        begin
          MakeCompass('N');
          TreeSpot := BitmapFromString(8,10, 'a6803978DAED943112C32' +
           '00C04BF2440025C8610FEFFA420C9C14CA8718AE88A2B6E0E2F1A' +
           'C000E0A383AE92BB45120FCFEE94E370C70110495E5EA3494D3A2' +
           '88987AB792027CE8FAF69AE89F6A93EBEF298C5010757D7FA8C17' +
           '5D88CA524A3A6455A1E19403E7893B891A7BE1267AD9150AD2643' +
           '26D1502BFF31A68F894B888791371E54EC4D9374E3A79FF7D05C0' +
           '2DF475C6E6EE987A3953E5AE749DFD4C769CF2E4F31ECE9DDC72C' +
           '303B9FAF13B5FD6AFB82693C9F43F7A0329B');

          If(FindBitmap(TreeSpot, X1, Y1)) then
          begin
            MakeCompass('N');
            RadialRoadWalk(FindRoadColor, 320, 293, 32, 4, 4);
            Wait(100 + random(200));
            JadSymbol('bank',true,true);// Credits go to JAD
            Flag;
            Wait(200 + random(100));
            TheAntiBan;
            FreeBitmap(TreeSpot);
          end;
        end;
      end;
    end;

    {++++++++++++++++++++++++++++++++++++++++}
    {  Walk Bank Procedure For: Option 2     }
    {++++++++++++++++++++++++++++++++++++++++}
    Var
      X2, Y2 : Integer;
      X3, Y3 : Integer;

    procedure WalkBankTwo;
    begin
      If(Players[CurrentPlayer].Integer1 = 2) then
      begin
        If (InvFull) or (InventoryCount = 28) then
        begin
          MakeCompass('N');
          TreeSpotTwo := BitmapFromString(7,7, 'a62BBA78DAED94510E8' +
           '4200C44AF54A015FC5C04EE7FA405EA226A341B8DB8D9381F1333' +
           '14FA401100A4B110155CB48E4C72354427D315172900A29C5B5F2' +
           'A29E41ACC89845229ED30CDEA318D0A5956E69C139E4BEEB5C83B' +
           '931DB030F05C697022C9DDB92F77D17D9E65A9381995729D6A348' +
           '5E416A77AAF4B8E43AAC43E915C24D1A1F9F86D728AE624B7F164' +
           '922D9E465415C33ECF38DA9CA4E6993D3794F2424427E10E2F81E' +
           '017FBAA92EF77C40C0749B8E39AE4D08D3845B2FBAEE32F4E0136' +
           'BA05EB730862E7642E57F58E98A4E6E193B9FC266E50D53C23557' +
           'B659253DFDEFF913C7AF4337A0331A');

          House := BitmapFromString(6,6, 'a99A8E78DAED923B12C3200C' +
           '44AF24401F521202F73F52D8B5C72E327191A40CC51BB12B562A1' +
           '0912C0F5927CA4299283D65D01DD4B6681575EA74450FC56F54AC' +
           '9E2EEB2D61532CA8145C4C075F8D23679F453757261B3B27F3618' +
           'A76248461B9E806366CEB77D439D09FB8F90FCF9461A3A9A435E9' +
           '33FE73AEF97DC275CEE09778E5BBFE27680');

          If(FindBitmap(TreeSpot, X2, Y2)) then
          begin
            MakeCompass('N');
            RadialRoadWalk(FindRoadColor, 105, 72, 33, 4, 4);
            Wait(100 + random(200));
            RadialRoadWalk(FindRoadColor, 91, 95, 45, 4, 4);
            Wait(100 + random(200));
            If(FindBitmap(House, X3, Y3)) then
            begin
              JadSymbol('bank',true,true);// Credits go to JAD
              Flag;
              Wait(10 + random(10));
              TheAntiBan;
              FreeBitmap(TreeSpotTwo);
              FreeBitmap(House);
            end;
          end;
        end;
      end;
    end;

    {++++++++++++++++++++++++++++++++++++++++}
    {   Banking Procedure                    }
    {++++++++++++++++++++++++++++++++++++++++}

    function BankThoseLogs : boolean;
    Var
      X4, Y4 : Integer;
      X5, Y5 : Integer;
    begin
      If(Players[CurrentPlayer].Boolean2 = True) then
      begin
        If (InvFull) or (InventoryCount = 28) then
        begin
          MakeCompass('W');
          wait(250 + random(250));
          OpenBankQuiet('db');
          Flag;
          Wait(200 + random(200));
          FixBank;
          If (FindDTM(OakLog, X4, Y4, MIX1, MIY1, MIX2, MIY2)) then
          begin
            MMouse(X4, Y4, 4,4);
            If IsUpTextMulti('se', 'ak', 'og') then
            begin
              Mouse(X4, Y4, 4, 4, False);
              ChooseOption( X5, Y5, 'All');
              if (CountItemDTM(OakLog)= 0) then
              begin
                Result := True;
                if (Result = True) then
                begin
                  Loads := Loads + 1;
                  TotalLoads := TotalLoads + 1;
                end;
              end;
              CloseBank;
              Wait(10 + random(10));
              MakeCompass('N');
            end;
          end;
        end;
      end;
    end;

    {++++++++++++++++++++++++++++++++++++++++}
    {   Progress Report :)                   }
    {++++++++++++++++++++++++++++++++++++++++}
    procedure MyProggy;
    begin
      ClearDebug;
      Writeln('[] Macho Man67s Oak Owner Version :' + VersionN + '[]');
      Writeln('=================================================');
      Writeln(' Ran For      :' + ScriptTime2(2)                 );
      Writeln('=================================================');
      Writeln(' Loads Banked :' + IntToStr(TotalLoads) + 'Loads ');
      Writeln('=================================================');
      Writeln(' Loads Dropped:' + IntToStr(TotalLoad) + ' Loads ');
      Writeln('=================================================');
      Writeln(' Ents Found!  :' + IntToStr(EntsFound)            );
      Writeln('=================================================');
      Writeln(' Total XP Gained :' + IntToStr(TotalXPG)          );
      Writeln('[]=============================================[]');
      SRLRandomsReport;
    end;

    {++++++++++++++++++++++++++++++++++++++++}
    {   Main Loop :(                         }
    {++++++++++++++++++++++++++++++++++++++++}
    begin
      SetupSRL;
      ActivateClient;
      DeclarePlayers;
      LoadDTMsAndBMPs;
      Signature;
      {SafeInitForm;
      SafeShowFormModal;
      if(ActiveC) then
       WriteLn('Yay It worked!')
      else
       WriteLn('False?!');}

      If (Not(LoggedIn)) then
      LoginPlayer;
      wait(10+random(10));
      HighestAngle;
      MakeCompass('N');
      repeat
        BeginXP := GetXp('Woodcutting');
        WalkToOakOne;
        WalkToTreesTwo;
        FindingTheTree;
        DropTheLogs;
        WalkBankOne;
        WalkBankTwo;
        BankThoseLogs;
        EndXP :=  GetXp('Woodcutting');
        TotalXPG := (EndXP - BeginXP) + (TotalXPG);
        MyProggy;
        if (Loads = LoadsToDo) then
        begin
          MakeCompass('N');
          LogOut;
          Loads:= 0;
          NextPlayer(True);
          HighestAngle;
          MakeCompass('N');
        end;
      until (False);
    end.

    one thing, there was like 20 errors throughout the script ,did u make it without testing it lol =S

  4. #4
    Join Date
    Dec 2006
    Posts
    173
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Ya I could not test it because of the rs update. I was going to test it after to make sure everything worked, but right now I just wanted to see if it could compile or not....

    Also Thank you The Rs Monkey!!!!!!You are my hero! Rep+

    Off Topic: How do you become a lesser demon? Because I am still a chicken lol!

    Also What were your thoughts on the script( people who looked(looking) at it).
    It would be nice to get some suggestions or comments too!
    Starting to merchant, if you know of any good clans, PM me please.

  5. #5
    Join Date
    May 2006
    Posts
    1,230
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    well, i think lesser demons and king black dragon are decided upon your activity.

    and as for suggestions, some errors were not putting a tolerance on the 3 lines of FindColorTolerance, i filled in a '10', but you may want to replace it with Tries, and it would be better.

    SCAR Code:
    repeat
          if(Tries = 45)then
          begin
            Writeln(' Machos Oak Owner Updated News:  ');
            Writeln('  Could not find the Oak Spot,   ');
            Writeln('       Switching Players..       ');
            NextPlayer(False);
          end;
          Wait(400 + random(100));
          Tries := Tries + 1;
        until (FindColorTolerance(XX, YY, OakColor1, MSX1, MSY1, MSX2, MSY2, 10)) or
        (FindColorTolerance(XX, YY, OakColor2, MSX1, MSY1, MSX2, MSY2, 10)) or
        (FindColorTolerance(XX, YY, OakColor3, MSX1, MSY1, MSX2, MSY2, 10));
        FreeBitmap(TreeSpot);

    also, since u used Tries as a global variable, make sure when u use it, u set it to 0 first, some parts in the script u didn't, and make sure u don't use a procedure that uses tries in a loop that uses tries, e.g.

    procedure blank;
    begin
    repeat
    Tries := Tries + 1
    until blah
    end;
    ...
    repeat
    Tries := Tries + 1;
    blank;
    until blah

    but i didn't have alot of time to look at the script thoroughly.

  6. #6
    Join Date
    Feb 2007
    Posts
    31
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    What is FindColorTolerance?? my scar 2.03 is not recognizing it.......

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Errors with my script...
    By Runescapian321 in forum OSR Help
    Replies: 4
    Last Post: 01-06-2008, 04:04 PM
  2. First Script/with errors.
    By hihi12340 in forum OSR Help
    Replies: 21
    Last Post: 06-19-2007, 02: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
  •