Results 1 to 13 of 13

Thread: 'BEGIN' expected in script But there is one

  1. #1
    Join Date
    Mar 2007
    Posts
    3,116
    Mentioned
    0 Post(s)
    Quoted
    2 Post(s)

    Default 'BEGIN' expected in script But there is one

    The problem is on Line 293. Heres the script. I know i need to do standerds i will do that after it works fine.
    SCAR Code:
    program RuneBuyer;
    {.include SRL/SRL.scar}
    {.include SRL/SRL/Misc/WorldSwitcher.scar}
    var
      Form1 : TForm;
      RadioButton1 : TRadioButton;
      RadioButton2 : TRadioButton;
      RadioButton3 : TRadioButton;
      RadioButton4 : TRadioButton;
      RadioButton5 : TRadioButton;
      RadioButton6 : TRadioButton;
      RadioButton7 : TRadioButton;
      Button1 : TButton;
      WhatToBuy:Integer;
      death:Integer;
      chaos:Integer;
      fire:Integer;
      water:Integer;
      air:Integer;
      earth:Integer;
      mind:Integer;
      body:Integer;
      Bought:Integer;

    procedure ClickButton(sender: TObject);
    begin
      form1.Caption:= form1.Caption + '.';
      form1.ModalResult:= mrOk;
    end;

    procedure MakeForm;
    begin
    Form1 := CreateForm;
    Form1.Left := 192;
    Form1.Top := 114;
    Form1.Width := 205;
    Form1.Height := 209;
    Form1.Caption := 'Buy runes';
    Form1.Color := clBtnFace;
    Form1.Font.Color := clWindowText;
    Form1.Font.Height := -11;
    Form1.Font.Name := 'Tahoma';
    Form1.Font.Style := [];
    Form1.PixelsPerInch := 96;
    RadioButton1 := TRadioButton.Create(Form1);
    RadioButton1.Parent := Form1;
    RadioButton1.Left := 0;
    RadioButton1.Top := 80;
    RadioButton1.Width := 81;
    RadioButton1.Height := 17;
    RadioButton1.Caption := 'Buy waters';
    RadioButton1.TabOrder := 0;
    RadioButton2 := TRadioButton.Create(Form1);
    RadioButton2.Parent := Form1;
    RadioButton2.Left := 0;
    RadioButton2.Top := 56;
    RadioButton2.Width := 73;
    RadioButton2.Height := 17;
    RadioButton2.Caption := 'Buy earth';
    RadioButton2.TabOrder := 1;
    RadioButton3 := TRadioButton.Create(Form1);
    RadioButton3.Parent := Form1;
    RadioButton3.Left := 0;
    RadioButton3.Top := 32;
    RadioButton3.Width := 57;
    RadioButton3.Height := 17;
    RadioButton3.Caption := 'Buy airs';
    RadioButton3.TabOrder := 2;
    RadioButton4 := TRadioButton.Create(Form1);
    RadioButton4.Parent := Form1;
    RadioButton4.Left := 0;
    RadioButton4.Top := 8;
    RadioButton4.Width := 65;
    RadioButton4.Height := 17;
    RadioButton4.Caption := 'Buy fires';
    RadioButton4.Checked := True;
    RadioButton4.TabOrder := 3;
    RadioButton4.TabStop := True;
    RadioButton5 := TRadioButton.Create(Form1);
    RadioButton5.Parent := Form1;
    RadioButton5.Left := 0;
    RadioButton5.Top := 152;
    RadioButton5.Width := 73;
    RadioButton5.Height := 17;
    RadioButton5.Caption := 'Buy chaos';
    RadioButton5.TabOrder := 4;
    RadioButton6 := TRadioButton.Create(Form1);
    RadioButton6.Parent := Form1;
    RadioButton6.Left := 0;
    RadioButton6.Top := 128;
    RadioButton6.Width := 73;
    RadioButton6.Height := 17;
    RadioButton6.Caption := 'Buy bodys';
    RadioButton6.TabOrder := 5;
    RadioButton7 := TRadioButton.Create(Form1);
    RadioButton7.Parent := Form1;
    RadioButton7.Left := 0;
    RadioButton7.Top := 104;
    RadioButton7.Width := 73;
    RadioButton7.Height := 17;
    RadioButton7.Caption := 'Buy death';
    RadioButton7.TabOrder := 6;
    Button1:= TButton.Create(Form1);
    Button1.Parent := Form1;
    Button1.Left := 80;
    Button1.Top := 136;
    Button1.Width := 113;
    Button1.Height := 33;
    Button1.Caption := 'Start';
      Button1.TabOrder := 7;
      button1.ONCLICK := @clickbutton
    end;

    procedure SafeShowWF;
    var
      tva: TVariantArray;
    begin
      setarraylength(tva, 0);
      ThreadSafeCall('MakeForm', tva);
    end;

    procedure ShowFormModal;
    begin
      Form1.ShowModal
    end;

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

    procedure Form;
       begin
       SafeShowWF;
       SafeShowFormModal;
       end;

    procedure loadbitmaps;
    begin
      chaos := BitmapFromString(10, 10, 'z78DABD91410E80300804BF5' +
           '41264F15885FEFF49D6EAA189C1E04548E6B4B31CB05685561B74' +
           'F6D237A04D494B582CBC14BD1835CCC9FFDD0C332E319D3398772' +
           '3EBEBF5CC8FDE1B9E1955785F459196E9BC2DC686AA02C37E0023' +
           'E789B3');
      death := BitmapFromString(10, 10, 'z78DA8D8F510AC4201043AF5' +
           '4AD7692CFB18EF73FD25AA70B966ECB1A78204C42A2911BB3AE04' +
           '453716AAD3922D5D13B5B0B19D340D5D0B13937AC2E0DD7549002' +
           'B77555AD7CED0658C8C4FF72185E30D9E09A31B0143BD5FBE7B9D' +
           '5C71D85FBD4F444346FEE7F287B72020BC2FBDF4CCDDA14E6C526' +
           '507C4C4FA6F91E6BC7BBD212304E24B91A4C83761F0B161C5DA35' +
           '25200A8527E71C6F32F719EBE6840F038187CD');
      fire := BitmapFromString(10, 10, 'z78DAE58E510EC4200844AF54' +
           'B594994FDAEAFD8F5457D944D3762FB0217924C0BC404341E1C15' +
           '0ABD1B618C26A0B577E19B9512C1154A7909F8E03BB13C8387B96' +
           'A33333324ECE666384429950839D9E7D71FAB6397122D52A10C8B' +
           '8F59BEE14ECB0693ED86058B4DCB36FCEE9069A353FCCDB57BFB3' +
           'FFC30B8D147FFF');
      water := BitmapFromString(10, 10, 'z78DA8D906D0AC3201005AF1' +
           '4E3C7BEF7538DDEFF485D762D58A4A57930606026127606DDE0AD' +
           '33D68B89A9DE2CCC2105D652234159CC24510B1B2B818167B1626' +
           '2D26BC6E57A6D6B7A87112A32A3A152D0D116ADE6EE4773BBA1BE' +
           'CD3AA39E04ABE6D6728FA6D7F47B41E77C1075D6D9DD55D86F684' +
           '491473A2043869E2E99CED33DEF86244DDE05E3697D2BE016FD61' +
           '8BD6F9EDEE05BD6BD64DD1C70BFFB84EE912755BE17FF70561E88' +
           '405');
      air := BitmapFromString(10, 10, 'z78DA7D8F510E80200C43AF842' +
           '2B6FB0494FB1FC9C5F10199C8927ED0AE79636362929D20EEE30E' +
           '3AAF4A626116B0B28CFFA36A62D3B91819BD2B91429A2E1B32039' +
           'AE9F4FF5271C13625D5C2BDA2B286E5EE890BF583E7F7AE9E3C50' +
           '903DC9D830BAEA257412EE108827F96F98DA1AF4AD1A3EF2199B4' +
           'E45C4749191789EBE4584B3D9AEBFC5183C89E90371F4888D');
      earth := BitmapFromString(10, 10, 'z78DABD90410AC3300C04BF9' +
           '4A4EECEFA68C7F1FF9F5413A7E0928BA1A512CC490CDAB539389C' +
           'BC509DBD7A550E5ECA0C1DC8A4F9FB5FB17DFC6C5B69E38D48BC7' +
           '8FE6351D8DD73DDD2B1F368DB0D77CF68183DA781C4CADB307A26' +
           '0C9845F5FF5D7DC52A049BA2224159E9A254B4F7441F9D0CADBE0' +
           '0EB8E864E');
      mind := BitmapFromString(10, 10, 'z78DA95913B12C3200C44AF04' +
           '06BCAB92EFFD8F146228C4C8458266B6D0E7B18836082F025696A' +
           '5F18EC951AB54F133BA5C331ECD4EA2440E2626DBFF42203B9BE4' +
           '393116CDF62C9A5C0421E13B7210120BB376C84C87B174671A038' +
           '3A659C2AEDE68A8243AFACE147A7ACBD9B38FAB5D8D28C89AB075' +
           'F9519C97D90B0239089AA3DE629D60609E7F095A17C1728E1BD55' +
           '6A76D778F5FFED7EEE403AA0A8232');
      body := BitmapFromString(10, 10, 'z78DA75D0618EC5200804E02B' +
           '89ADCF999FD0E2FD8FB43E7113CC66319998A25F69A58B3FA37C4' +
           'B54E974350E8E9DAEA2624D676BCC2A51626ECD5AEC6509FAA151' +
           '157CF9EC5C5A7425BDC5D48A95FC5C2F827D672389D0F299C8988' +
           '40F652E6765D5C29BF7CECA0F5B38871FA66BD52AB77C2B65D622' +
           'F7ADD0B219E71B0C7A0880E3A562606CEDCF84B3D7D058D1D18FB' +
           'B4BDBD9F1C0B696CCD993B95E5C732DE7102ECCC3FF395094FE2B' +
           '24E710D654E1E4FF0674EFBE3339712B7F511662861F539B8584');
    end;

    procedure ClickBMPS;
    begin
    wait(300+random(32))
    movemousesmooth(x,y)
    wait(32+random(16))
    clickmouse(x,y,false)
    end;

    procedure NoGP;
    begin
    Mouse(485,33,3,3,true);
    LogOut;
    writeln('out of money logged out');
    end;

    procedure NoRunes;
    begin
    writeln('shop ran out of stock loggin out');
    Mouse(485,33,3,3,true);
    LogOut;
    end;

    procedure BuychaosRunes;
    begin
    if(FindBitmap(chaos,x,y))then
    ClickBMPS;
    Bought:= Bought + 1;
    end;

    procedure BuyDeathRunes;
    begin
    if(FindBitmap(death,x,y))then
    ClickBMPS;
    Bought:= Bought + 1;
    end;

    procedure BuyFireRunes;
    begin
    if(FindBitmap(fire,x,y))then
    ClickBMPS;
    Bought:= Bought + 1;
    end;

    procedure BuyWaterRunes;
    begin
    if(FindBitmap(water,x,y))then
    ClickBMPS;
    Bought:= Bought + 1;
    end;

    procedure BuyEarthRunes;
    begin
    if(FindBitmap(earth,x,y))then
    ClickBMPS;
    Bought:= Bought + 1;
    end;

    procedure BuyMindRunes;
    begin
    if(FindBitmap(mind,x,y))then
    ClickBMPS;
    Bought:= Bought + 1;
    end;

    procedure BuyBodyRunes;
    begin
    if(FindBitmap(body,x,y))then
    ClickBMPS;
    Bought:= Bought + 1;
    end;

    procedure BuyingWater;
    begin
    if(RadioButton1.checked)then
    WhatToBuy:= Water
    end;

    procedure BuyingEarth;
    begin
    if(RadioButton2.checked)then
    WhatToBuy:= Earth
    end;

    Procedure buyingAir;
    begin
    if(RadioButton3.checked)then
    WhatToBuy:= Air
    end;

    procedure BuyingFire;
    begin
    if(RadioButton4.checked)then
    WhatToBuy:= Fire
    end;

    program Buyingchaos;
    begin
    if(RadioButton5.checked)then
    WhatToBuy:= chaos
    end;

    program BuyingBody;
    begin
    if(RadioButton6.checked)then
    WhatToBuy:= Body
    end;
    program BuyingDeath;
    begin
    if(RadioButton7.checked)then
    WhatToBuy:= Death
    end;

    program WhatToBuy;
    begin
    BuyingWater;
    BuyingEarth;
    BuyingAir;
    BuyingFire;
    BuyingWater;
    Buyingchaos;
    Buyingbody;
    BuyingDeath;
    end;

    procedure BuyThem;
    begin
    if(WhatToBuy = Mind)then
      BuyMindRunes;
    if(WhatToBuy = Fire)then
      BuyFireRunes;
    if(WhatToBuy = Water)then
      BuyWaterRunes;
    if(WhatToBuy = Earth)then
      BuyEarthRunes;
    if(WhatToBuy = Air)then
      BuyAirRunes;
    if(WhatToBuy = Body)then
      BuyBodyRunes;
    if(WhatToBuy = Death)then
      BuyDeathRunes;
    if(WhatToBuy = chaos)then
      BuychaosRunes;
    end;


    procedure proggy;
    begin
      writeln('==================')
      writeln('Madness rune buyer')
      writeln('==================')
      writeln('==worker for:'+ScriptTime2(2)+'==')
      writeln('==bought'+IntToStr(bought)+IntToStr(WhatToBuy)+'runes==')
      writeln('==================')
      writeln('Madness rune buyer')
      writeln('==================')
    end;


    begin
    setupsrl;
    loadbitmaps;
    cleardebug;
    Form;
    WhatToBuy;
    repeat
    Buythem;
    if(InChat('enough coin')) then NoGP;
    if(InChat('shop has ran out of stock'))Then NoRunes;
    proggy;
    until(False)
    end

  2. #2
    Join Date
    Dec 2006
    Location
    Birmingham/UK
    Posts
    105
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default =]

    SCAR Code:
    proggy;
    until(False)
    end
    at the end of script put a .
    If I see you autoing with level 3/default clothes/crap name I WILL report you. Auto Correctly. - put this in your sig<BR>
    http://www.draynor.net/skill/underse...dvance_war.png

  3. #3
    Join Date
    Mar 2007
    Posts
    3,116
    Mentioned
    0 Post(s)
    Quoted
    2 Post(s)

    Default

    That still didn't help it compile. It will help when i finish tho.

  4. #4
    Join Date
    Dec 2006
    Location
    Birmingham/UK
    Posts
    105
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    hmmm 293 its because u put program and not procedure =] the same with 299 ,304 and 310

    u also have made some duplicate identifiers

    Line 310: [Error] (18279:11): Duplicate identifier 'WHATTOBUY' in script change that to a different name
    If I see you autoing with level 3/default clothes/crap name I WILL report you. Auto Correctly. - put this in your sig<BR>
    http://www.draynor.net/skill/underse...dvance_war.png

  5. #5
    Join Date
    Dec 2006
    Location
    Birmingham/UK
    Posts
    105
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    thts as much as i cna help there are lots moire errors which i found in the script but i am too busy too help i might help in a few hours if no1 else can which im sure they will =]
    If I see you autoing with level 3/default clothes/crap name I WILL report you. Auto Correctly. - put this in your sig<BR>
    http://www.draynor.net/skill/underse...dvance_war.png

  6. #6
    Join Date
    Mar 2007
    Posts
    3,116
    Mentioned
    0 Post(s)
    Quoted
    2 Post(s)

    Default

    yep that was the problem program not procedure now it compiles. I had to add a buy air procedure and fix the program procedure thing.

    edit:now i have more problems it says "Line 210: [Error] (14960:1): Identifier expected in script"
    heres the code
    SCAR Code:
    program RuneBuyer;
    {.include SRL/SRL.scar}
    var
      Form1 : TForm;
      RadioButton1 : TRadioButton;
      RadioButton2 : TRadioButton;
      RadioButton3 : TRadioButton;
      RadioButton4 : TRadioButton;
      RadioButton5 : TRadioButton;
      RadioButton6 : TRadioButton;
      RadioButton7 : TRadioButton;
      Button1 : TButton;
      WhatToBuy:Integer;
      death:Integer;
      chaos:Integer;
      fire:Integer;
      water:Integer;
      air:Integer;
      earth:Integer;
      mind:Integer;
      body:Integer;
      Bought:Integer;

    procedure ClickButton(sender: TObject);
    begin
      form1.Caption:= form1.Caption + '.';
      form1.ModalResult:= mrOk;
    end;

    procedure MakeForm;
    begin
      Form1 := CreateForm;
      Form1.Left := 192;
      Form1.Top := 114;
      Form1.Width := 205;
      Form1.Height := 209;
      Form1.Caption := 'Buy runes';
      Form1.Color := clBtnFace;
      Form1.Font.Color := clWindowText;
      Form1.Font.Height := -11;
      Form1.Font.Name := 'Tahoma';
      Form1.Font.Style := [];
      Form1.PixelsPerInch := 96;
      RadioButton1 := TRadioButton.Create(Form1);
      RadioButton1.Parent := Form1;
      RadioButton1.Left := 0;
      RadioButton1.Top := 80;
      RadioButton1.Width := 81;
      RadioButton1.Height := 17;
      RadioButton1.Caption := 'Buy waters';
      RadioButton1.TabOrder := 0;
      RadioButton2 := TRadioButton.Create(Form1);
      RadioButton2.Parent := Form1;
      RadioButton2.Left := 0;
      RadioButton2.Top := 56;
      RadioButton2.Width := 73;
      RadioButton2.Height := 17;
      RadioButton2.Caption := 'Buy earth';
      RadioButton2.TabOrder := 1;
      RadioButton3 := TRadioButton.Create(Form1);
      RadioButton3.Parent := Form1;
      RadioButton3.Left := 0;
      RadioButton3.Top := 32;
      RadioButton3.Width := 57;
      RadioButton3.Height := 17;
      RadioButton3.Caption := 'Buy airs';
      RadioButton3.TabOrder := 2;
      RadioButton4 := TRadioButton.Create(Form1);
      RadioButton4.Parent := Form1;
      RadioButton4.Left := 0;
      RadioButton4.Top := 8;
      RadioButton4.Width := 65;
      RadioButton4.Height := 17;
      RadioButton4.Caption := 'Buy fires';
      RadioButton4.Checked := True;
      RadioButton4.TabOrder := 3;
      RadioButton4.TabStop := True;
      RadioButton5 := TRadioButton.Create(Form1);
      RadioButton5.Parent := Form1;
      RadioButton5.Left := 0;
      RadioButton5.Top := 152;
      RadioButton5.Width := 73;
      RadioButton5.Height := 17;
      RadioButton5.Caption := 'Buy chaos';
      RadioButton5.TabOrder := 4;
      RadioButton6 := TRadioButton.Create(Form1);
      RadioButton6.Parent := Form1;
      RadioButton6.Left := 0;
      RadioButton6.Top := 128;
      RadioButton6.Width := 73;
      RadioButton6.Height := 17;
      RadioButton6.Caption := 'Buy bodys';
      RadioButton6.TabOrder := 5;
      RadioButton7 := TRadioButton.Create(Form1);
      RadioButton7.Parent := Form1;
      RadioButton7.Left := 0;
      RadioButton7.Top := 104;
      RadioButton7.Width := 73;
      RadioButton7.Height := 17;
      RadioButton7.Caption := 'Buy death';
      RadioButton7.TabOrder := 6;
      Button1:= TButton.Create(Form1);
      Button1.Parent := Form1;
      Button1.Left := 80;
      Button1.Top := 136;
      Button1.Width := 113;
      Button1.Height := 33;
      Button1.Caption := 'Start';
      Button1.TabOrder := 7;
      button1.ONCLICK := @clickbutton
    end;

    procedure SafeShowWF;
    var
      tva: TVariantArray;
    begin
      setarraylength(tva, 0);
      ThreadSafeCall('MakeForm', tva);
    end;

    procedure ShowFormModal;
    begin
      Form1.ShowModal
    end;

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

    procedure Form;
    begin
      SafeShowWF;
      SafeShowFormModal;
    end;

    procedure loadbitmaps;
    begin
      chaos := BitmapFromString(10, 10, 'z78DABD91410E80300804BF5' +
           '41264F15885FEFF49D6EAA189C1E04548E6B4B31CB05685561B74' +
           'F6D237A04D494B582CBC14BD1835CCC9FFDD0C332E319D3398772' +
           '3EBEBF5CC8FDE1B9E1955785F459196E9BC2DC686AA02C37E0023' +
           'E789B3');
      death := BitmapFromString(10, 10, 'z78DA8D8F510AC4201043AF5' +
           '4AD7692CFB18EF73FD25AA70B966ECB1A78204C42A2911BB3AE04' +
           '453716AAD3922D5D13B5B0B19D340D5D0B13937AC2E0DD7549002' +
           'B77555AD7CED0658C8C4FF72185E30D9E09A31B0143BD5FBE7B9D' +
           '5C71D85FBD4F444346FEE7F287B72020BC2FBDF4CCDDA14E6C526' +
           '507C4C4FA6F91E6BC7BBD212304E24B91A4C83761F0B161C5DA35' +
           '25200A8527E71C6F32F719EBE6840F038187CD');
      fire := BitmapFromString(10, 10, 'z78DAE58E510EC4200844AF54' +
           'B594994FDAEAFD8F5457D944D3762FB0217924C0BC404341E1C15' +
           '0ABD1B618C26A0B577E19B9512C1154A7909F8E03BB13C8387B96' +
           'A33333324ECE666384429950839D9E7D71FAB6397122D52A10C8B' +
           '8F59BEE14ECB0693ED86058B4DCB36FCEE9069A353FCCDB57BFB3' +
           'FFC30B8D147FFF');
      water := BitmapFromString(10, 10, 'z78DA8D906D0AC3201005AF1' +
           '4E3C7BEF7538DDEFF485D762D58A4A57930606026127606DDE0AD' +
           '33D68B89A9DE2CCC2105D652234159CC24510B1B2B818167B1626' +
           '2D26BC6E57A6D6B7A87112A32A3A152D0D116ADE6EE4773BBA1BE' +
           'CD3AA39E04ABE6D6728FA6D7F47B41E77C1075D6D9DD55D86F684' +
           '491473A2043869E2E99CED33DEF86244DDE05E3697D2BE016FD61' +
           '8BD6F9EDEE05BD6BD64DD1C70BFFB84EE912755BE17FF70561E88' +
           '405');
      air := BitmapFromString(10, 10, 'z78DA7D8F510E80200C43AF842' +
           '2B6FB0494FB1FC9C5F10199C8927ED0AE79636362929D20EEE30E' +
           '3AAF4A626116B0B28CFFA36A62D3B91819BD2B91429A2E1B32039' +
           'AE9F4FF5271C13625D5C2BDA2B286E5EE890BF583E7F7AE9E3C50' +
           '903DC9D830BAEA257412EE108827F96F98DA1AF4AD1A3EF2199B4' +
           'E45C4749191789EBE4584B3D9AEBFC5183C89E90371F4888D');
      earth := BitmapFromString(10, 10, 'z78DABD90410AC3300C04BF9' +
           '4A4EECEFA68C7F1FF9F5413A7E0928BA1A512CC490CDAB539389C' +
           'BC509DBD7A550E5ECA0C1DC8A4F9FB5FB17DFC6C5B69E38D48BC7' +
           '8FE6351D8DD73DDD2B1F368DB0D77CF68183DA781C4CADB307A26' +
           '0C9845F5FF5D7DC52A049BA2224159E9A254B4F7441F9D0CADBE0' +
           '0EB8E864E');
      mind := BitmapFromString(10, 10, 'z78DA95913B12C3200C44AF04' +
           '06BCAB92EFFD8F146228C4C8458266B6D0E7B18836082F025696A' +
           '5F18EC951AB54F133BA5C331ECD4EA2440E2626DBFF42203B9BE4' +
           '393116CDF62C9A5C0421E13B7210120BB376C84C87B174671A038' +
           '3A659C2AEDE68A8243AFACE147A7ACBD9B38FAB5D8D28C89AB075' +
           'F9519C97D90B0239089AA3DE629D60609E7F095A17C1728E1BD55' +
           '6A76D778F5FFED7EEE403AA0A8232');
      body := BitmapFromString(10, 10, 'z78DA75D0618EC5200804E02B' +
           '89ADCF999FD0E2FD8FB43E7113CC66319998A25F69A58B3FA37C4' +
           'B54E974350E8E9DAEA2624D676BCC2A51626ECD5AEC6509FAA151' +
           '157CF9EC5C5A7425BDC5D48A95FC5C2F827D672389D0F299C8988' +
           '40F652E6765D5C29BF7CECA0F5B38871FA66BD52AB77C2B65D622' +
           'F7ADD0B219E71B0C7A0880E3A562606CEDCF84B3D7D058D1D18FB' +
           'B4BDBD9F1C0B696CCD993B95E5C732DE7102ECCC3FF395094FE2B' +
           '24E710D654E1E4FF0674EFBE3339712B7F511662861F539B8584');
    end;

    procedure ClickBMPS;
    begin
      wait(300+random(32))
      movemousesmooth(x,y)
      wait(32+random(16))
      clickmouse(x,y,false)
      Case Random(4) of
      0: ChooseOption(x,y,'uy 10');
      1: ChooseOption(x,y,'uy 5');
      2: ChooseOption(x,y,'uy 10');
      3: ChooseOption(x,y,'uy 10');
    end;

    procedure NoGP;
    begin
      Mouse(485,33,3,3,true);
      LogOut;
      writeln('out of money logged out');
    end;

    procedure NoRunes;
    begin
      writeln('shop ran out of stock logging out');
      Mouse(485,33,3,3,true);
      LogOut;
    end;

    procedure BuyAirRunes;
    begin
    if(FindBitmap(Air,x,y))then
      ClickBMPS;
      Bought:= Bought + 1;
    end;

    procedure BuychaosRunes;
    begin
    if(FindBitmap(chaos,x,y))then
      ClickBMPS;
      Bought:= Bought + 1;
    end;

    procedure BuyDeathRunes;
    begin
    if(FindBitmap(death,x,y))then
      ClickBMPS;
      Bought:= Bought + 1;
    end;

    procedure BuyFireRunes;
    begin
    if(FindBitmap(fire,x,y))then
      ClickBMPS;
      Bought:= Bought + 1;
    end;

    procedure BuyWaterRunes;
    begin
    if(FindBitmap(water,x,y))then
      ClickBMPS;
      Bought:= Bought + 1;
    end;

    procedure BuyEarthRunes;
    begin
    if(FindBitmap(earth,x,y))then
      ClickBMPS;
      Bought:= Bought + 1;
    end;

    procedure BuyMindRunes;
    begin
    if(FindBitmap(mind,x,y))then
      ClickBMPS;
      Bought:= Bought + 1;
    end;

    procedure BuyBodyRunes;
    begin
    if(FindBitmap(body,x,y))then
      ClickBMPS;
      Bought:= Bought + 1;
    end;

    procedure BuyingWater;
    begin
    if(RadioButton1.checked)then
      WhatToBuy:= Water
    end;

    procedure BuyingEarth;
    begin
    if(RadioButton2.checked)then
      WhatToBuy:= Earth
    end;

    Procedure buyingAir;
    begin
    if(RadioButton3.checked)then
      WhatToBuy:= Air
    end;

    procedure BuyingFire;
    begin
    if(RadioButton4.checked)then
      WhatToBuy:= Fire
    end;

    procedure Buyingchaos;
    begin
    if(RadioButton5.checked)then
      WhatToBuy:= chaos
    end;

    procedure BuyingBody;
    begin
    if(RadioButton6.checked)then
      WhatToBuy:= Body
    end;

    Procedure BuyingDeath;
    begin
    if(RadioButton7.checked)then
      WhatToBuy:= Death
    end;

    Procedure Buyingwhat;
    begin
      BuyingWater;
      BuyingEarth;
      BuyingAir;
      BuyingFire;
      BuyingWater;
      Buyingchaos;
      Buyingbody;
      BuyingDeath;
    end;

    procedure BuyThem;
    begin
    if(WhatToBuy = Mind)then
      BuyMindRunes;
    if(WhatToBuy = Fire)then
      BuyFireRunes;
    if(WhatToBuy = Water)then
      BuyWaterRunes;
    if(WhatToBuy = Earth)then
      BuyEarthRunes;
    if(WhatToBuy = Air)then
      BuyAirRunes;
    if(WhatToBuy = Body)then
      BuyBodyRunes;
    if(WhatToBuy = Death)then
      BuyDeathRunes;
    if(WhatToBuy = chaos)then
      BuychaosRunes;
    end;


    procedure proggy;
    begin
      writeln('==================')
      writeln('Madness rune buyer')
      writeln('==================')
      writeln('==worker for:'+ScriptTime2(2)+'==')
      writeln('==bought'+IntToStr(bought)+IntToStr(WhatToBuy)+'runes==')
      writeln('==================')
      writeln('Madness rune buyer')
      writeln('==================')
    end;


    begin
    setupsrl;
    loadbitmaps;
    cleardebug;
    Form;
    Buyingwhat;
    repeat
    Buythem;
    if(InChat('enough coin')) then NoGP;
    if(InChat('shop has ran out of stock'))Then NoRunes;
    proggy;
    until(False)
    end.

  7. #7
    Join Date
    Jun 2007
    Location
    #SRL
    Posts
    200
    Mentioned
    2 Post(s)
    Quoted
    1 Post(s)

    Default

    uuuhhh... dude you just need to press enter on line 208 to make a blank 209 then add one more "end;" in line 209 it worked fine for me.

  8. #8
    Join Date
    Dec 2006
    Location
    Birmingham/UK
    Posts
    105
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    SCAR Code:
    program RuneBuyer;
    {.include SRL/SRL.scar}
    var
      Form1 : TForm;
      RadioButton1 : TRadioButton;
      RadioButton2 : TRadioButton;
      RadioButton3 : TRadioButton;
      RadioButton4 : TRadioButton;
      RadioButton5 : TRadioButton;
      RadioButton6 : TRadioButton;
      RadioButton7 : TRadioButton;
      Button1 : TButton;
      WhatToBuy:Integer;
      death:Integer;
      chaos:Integer;
      fire:Integer;
      water:Integer;
      air:Integer;
      earth:Integer;
      mind:Integer;
      body:Integer;
      Bought:Integer;

    procedure ClickButton(sender: TObject);
    begin
      form1.Caption:= form1.Caption + '.';
      form1.ModalResult:= mrOk;
    end;

    procedure MakeForm;
    begin
      Form1 := CreateForm;
      Form1.Left := 192;
      Form1.Top := 114;
      Form1.Width := 205;
      Form1.Height := 209;
      Form1.Caption := 'Buy runes';
      Form1.Color := clBtnFace;
      Form1.Font.Color := clWindowText;
      Form1.Font.Height := -11;
      Form1.Font.Name := 'Tahoma';
      Form1.Font.Style := [];
      Form1.PixelsPerInch := 96;
      RadioButton1 := TRadioButton.Create(Form1);
      RadioButton1.Parent := Form1;
      RadioButton1.Left := 0;
      RadioButton1.Top := 80;
      RadioButton1.Width := 81;
      RadioButton1.Height := 17;
      RadioButton1.Caption := 'Buy waters';
      RadioButton1.TabOrder := 0;
      RadioButton2 := TRadioButton.Create(Form1);
      RadioButton2.Parent := Form1;
      RadioButton2.Left := 0;
      RadioButton2.Top := 56;
      RadioButton2.Width := 73;
      RadioButton2.Height := 17;
      RadioButton2.Caption := 'Buy earth';
      RadioButton2.TabOrder := 1;
      RadioButton3 := TRadioButton.Create(Form1);
      RadioButton3.Parent := Form1;
      RadioButton3.Left := 0;
      RadioButton3.Top := 32;
      RadioButton3.Width := 57;
      RadioButton3.Height := 17;
      RadioButton3.Caption := 'Buy airs';
      RadioButton3.TabOrder := 2;
      RadioButton4 := TRadioButton.Create(Form1);
      RadioButton4.Parent := Form1;
      RadioButton4.Left := 0;
      RadioButton4.Top := 8;
      RadioButton4.Width := 65;
      RadioButton4.Height := 17;
      RadioButton4.Caption := 'Buy fires';
      RadioButton4.Checked := True;
      RadioButton4.TabOrder := 3;
      RadioButton4.TabStop := True;
      RadioButton5 := TRadioButton.Create(Form1);
      RadioButton5.Parent := Form1;
      RadioButton5.Left := 0;
      RadioButton5.Top := 152;
      RadioButton5.Width := 73;
      RadioButton5.Height := 17;
      RadioButton5.Caption := 'Buy chaos';
      RadioButton5.TabOrder := 4;
      RadioButton6 := TRadioButton.Create(Form1);
      RadioButton6.Parent := Form1;
      RadioButton6.Left := 0;
      RadioButton6.Top := 128;
      RadioButton6.Width := 73;
      RadioButton6.Height := 17;
      RadioButton6.Caption := 'Buy bodys';
      RadioButton6.TabOrder := 5;
      RadioButton7 := TRadioButton.Create(Form1);
      RadioButton7.Parent := Form1;
      RadioButton7.Left := 0;
      RadioButton7.Top := 104;
      RadioButton7.Width := 73;
      RadioButton7.Height := 17;
      RadioButton7.Caption := 'Buy death';
      RadioButton7.TabOrder := 6;
      Button1:= TButton.Create(Form1);
      Button1.Parent := Form1;
      Button1.Left := 80;
      Button1.Top := 136;
      Button1.Width := 113;
      Button1.Height := 33;
      Button1.Caption := 'Start';
      Button1.TabOrder := 7;
      button1.ONCLICK := @clickbutton
    end;

    procedure SafeShowWF;
    var
      tva: TVariantArray;
    begin
      setarraylength(tva, 0);
      ThreadSafeCall('MakeForm', tva);
    end;

    procedure ShowFormModal;
    begin
      Form1.ShowModal
    end;

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

    procedure Form;
    begin
      SafeShowWF;
      SafeShowFormModal;
    end;

    procedure loadbitmaps;
    begin
      chaos := BitmapFromString(10, 10, 'z78DABD91410E80300804BF5' +
           '41264F15885FEFF49D6EAA189C1E04548E6B4B31CB05685561B74' +
           'F6D237A04D494B582CBC14BD1835CCC9FFDD0C332E319D3398772' +
           '3EBEBF5CC8FDE1B9E1955785F459196E9BC2DC686AA02C37E0023' +
           'E789B3');
      death := BitmapFromString(10, 10, 'z78DA8D8F510AC4201043AF5' +
           '4AD7692CFB18EF73FD25AA70B966ECB1A78204C42A2911BB3AE04' +
           '453716AAD3922D5D13B5B0B19D340D5D0B13937AC2E0DD7549002' +
           'B77555AD7CED0658C8C4FF72185E30D9E09A31B0143BD5FBE7B9D' +
           '5C71D85FBD4F444346FEE7F287B72020BC2FBDF4CCDDA14E6C526' +
           '507C4C4FA6F91E6BC7BBD212304E24B91A4C83761F0B161C5DA35' +
           '25200A8527E71C6F32F719EBE6840F038187CD');
      fire := BitmapFromString(10, 10, 'z78DAE58E510EC4200844AF54' +
           'B594994FDAEAFD8F5457D944D3762FB0217924C0BC404341E1C15' +
           '0ABD1B618C26A0B577E19B9512C1154A7909F8E03BB13C8387B96' +
           'A33333324ECE666384429950839D9E7D71FAB6397122D52A10C8B' +
           '8F59BEE14ECB0693ED86058B4DCB36FCEE9069A353FCCDB57BFB3' +
           'FFC30B8D147FFF');
      water := BitmapFromString(10, 10, 'z78DA8D906D0AC3201005AF1' +
           '4E3C7BEF7538DDEFF485D762D58A4A57930606026127606DDE0AD' +
           '33D68B89A9DE2CCC2105D652234159CC24510B1B2B818167B1626' +
           '2D26BC6E57A6D6B7A87112A32A3A152D0D116ADE6EE4773BBA1BE' +
           'CD3AA39E04ABE6D6728FA6D7F47B41E77C1075D6D9DD55D86F684' +
           '491473A2043869E2E99CED33DEF86244DDE05E3697D2BE016FD61' +
           '8BD6F9EDEE05BD6BD64DD1C70BFFB84EE912755BE17FF70561E88' +
           '405');
      air := BitmapFromString(10, 10, 'z78DA7D8F510E80200C43AF842' +
           '2B6FB0494FB1FC9C5F10199C8927ED0AE79636362929D20EEE30E' +
           '3AAF4A626116B0B28CFFA36A62D3B91819BD2B91429A2E1B32039' +
           'AE9F4FF5271C13625D5C2BDA2B286E5EE890BF583E7F7AE9E3C50' +
           '903DC9D830BAEA257412EE108827F96F98DA1AF4AD1A3EF2199B4' +
           'E45C4749191789EBE4584B3D9AEBFC5183C89E90371F4888D');
      earth := BitmapFromString(10, 10, 'z78DABD90410AC3300C04BF9' +
           '4A4EECEFA68C7F1FF9F5413A7E0928BA1A512CC490CDAB539389C' +
           'BC509DBD7A550E5ECA0C1DC8A4F9FB5FB17DFC6C5B69E38D48BC7' +
           '8FE6351D8DD73DDD2B1F368DB0D77CF68183DA781C4CADB307A26' +
           '0C9845F5FF5D7DC52A049BA2224159E9A254B4F7441F9D0CADBE0' +
           '0EB8E864E');
      mind := BitmapFromString(10, 10, 'z78DA95913B12C3200C44AF04' +
           '06BCAB92EFFD8F146228C4C8458266B6D0E7B18836082F025696A' +
           '5F18EC951AB54F133BA5C331ECD4EA2440E2626DBFF42203B9BE4' +
           '393116CDF62C9A5C0421E13B7210120BB376C84C87B174671A038' +
           '3A659C2AEDE68A8243AFACE147A7ACBD9B38FAB5D8D28C89AB075' +
           'F9519C97D90B0239089AA3DE629D60609E7F095A17C1728E1BD55' +
           '6A76D778F5FFED7EEE403AA0A8232');
      body := BitmapFromString(10, 10, 'z78DA75D0618EC5200804E02B' +
           '89ADCF999FD0E2FD8FB43E7113CC66319998A25F69A58B3FA37C4' +
           'B54E974350E8E9DAEA2624D676BCC2A51626ECD5AEC6509FAA151' +
           '157CF9EC5C5A7425BDC5D48A95FC5C2F827D672389D0F299C8988' +
           '40F652E6765D5C29BF7CECA0F5B38871FA66BD52AB77C2B65D622' +
           'F7ADD0B219E71B0C7A0880E3A562606CEDCF84B3D7D058D1D18FB' +
           'B4BDBD9F1C0B696CCD993B95E5C732DE7102ECCC3FF395094FE2B' +
           '24E710D654E1E4FF0674EFBE3339712B7F511662861F539B8584');
    end;

    procedure ClickBMPS;
    begin
      wait(300+random(32))
      movemousesmooth(x,y)
      wait(32+random(16))
      clickmouse(x,y,false)
      Case Random(4) of
      0: ChooseOption(x,y,'uy 10');
      1: ChooseOption(x,y,'uy 5');
      2: ChooseOption(x,y,'uy 10');
      3: ChooseOption(x,y,'uy 10');
    end;
    end;
    procedure NoGP;
    begin
      Mouse(485,33,3,3,true);
      LogOut;
      writeln('out of money logged out');
    end;

    procedure NoRunes;
    begin
      writeln('shop ran out of stock logging out');
      Mouse(485,33,3,3,true);
      LogOut;
    end;

    procedure BuyAirRunes;
    begin
    if(FindBitmap(Air,x,y))then
      ClickBMPS;
      Bought:= Bought + 1;
    end;

    procedure BuychaosRunes;
    begin
    if(FindBitmap(chaos,x,y))then
      ClickBMPS;
      Bought:= Bought + 1;
    end;

    procedure BuyDeathRunes;
    begin
    if(FindBitmap(death,x,y))then
      ClickBMPS;
      Bought:= Bought + 1;
    end;

    procedure BuyFireRunes;
    begin
    if(FindBitmap(fire,x,y))then
      ClickBMPS;
      Bought:= Bought + 1;
    end;

    procedure BuyWaterRunes;
    begin
    if(FindBitmap(water,x,y))then
      ClickBMPS;
      Bought:= Bought + 1;
    end;

    procedure BuyEarthRunes;
    begin
    if(FindBitmap(earth,x,y))then
      ClickBMPS;
      Bought:= Bought + 1;
    end;

    procedure BuyMindRunes;
    begin
    if(FindBitmap(mind,x,y))then
      ClickBMPS;
      Bought:= Bought + 1;
    end;

    procedure BuyBodyRunes;
    begin
    if(FindBitmap(body,x,y))then
      ClickBMPS;
      Bought:= Bought + 1;
    end;

    procedure BuyingWater;
    begin
    if(RadioButton1.checked)then
      WhatToBuy:= Water
    end;

    procedure BuyingEarth;
    begin
    if(RadioButton2.checked)then
      WhatToBuy:= Earth
    end;

    Procedure buyingAir;
    begin
    if(RadioButton3.checked)then
      WhatToBuy:= Air
    end;

    procedure BuyingFire;
    begin
    if(RadioButton4.checked)then
      WhatToBuy:= Fire
    end;

    procedure Buyingchaos;
    begin
    if(RadioButton5.checked)then
      WhatToBuy:= chaos
    end;

    procedure BuyingBody;
    begin
    if(RadioButton6.checked)then
      WhatToBuy:= Body
    end;

    Procedure BuyingDeath;
    begin
    if(RadioButton7.checked)then
      WhatToBuy:= Death
    end;

    Procedure Buyingwhat;
    begin
      BuyingWater;
      BuyingEarth;
      BuyingAir;
      BuyingFire;
      BuyingWater;
      Buyingchaos;
      Buyingbody;
      BuyingDeath;
    end;

    procedure BuyThem;
    begin
    if(WhatToBuy = Mind)then
      BuyMindRunes;
    if(WhatToBuy = Fire)then
      BuyFireRunes;
    if(WhatToBuy = Water)then
      BuyWaterRunes;
    if(WhatToBuy = Earth)then
      BuyEarthRunes;
    if(WhatToBuy = Air)then
      BuyAirRunes;
    if(WhatToBuy = Body)then
      BuyBodyRunes;
    if(WhatToBuy = Death)then
      BuyDeathRunes;
    if(WhatToBuy = chaos)then
      BuychaosRunes;
    end;


    procedure proggy;
    begin
      writeln('==================')
      writeln('Madness rune buyer')
      writeln('==================')
      writeln('==worker for:'+ScriptTime2(2)+'==')
      writeln('==bought'+IntToStr(bought)+IntToStr(WhatToBuy)+'runes==')
      writeln('==================')
      writeln('Madness rune buyer')
      writeln('==================')
    end;


    begin
    setupsrl;
    loadbitmaps;
    cleardebug;
    Form;
    Buyingwhat;
    repeat
    Buythem;
    if(InChat('enough coin')) then NoGP;
    if(InChat('shop has ran out of stock'))Then NoRunes;
    proggy;
    until(False)
    end.

    so basically there is your script =] the guy is right even tho i dont understand why u need two end;s
    If I see you autoing with level 3/default clothes/crap name I WILL report you. Auto Correctly. - put this in your sig<BR>
    http://www.draynor.net/skill/underse...dvance_war.png

  9. #9
    Join Date
    Dec 2006
    Location
    Birmingham/UK
    Posts
    105
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    maybe u could add some player arrays so that it buys a certain ammount of runes for each player ? would be usefull maybe u could learn radial walk which im still stuck on lol and make it bank at the varrock east
    If I see you autoing with level 3/default clothes/crap name I WILL report you. Auto Correctly. - put this in your sig<BR>
    http://www.draynor.net/skill/underse...dvance_war.png

  10. #10
    Join Date
    Mar 2007
    Posts
    3,116
    Mentioned
    0 Post(s)
    Quoted
    2 Post(s)

    Default

    why i would i need it to bank. runes are stackable so is cash so no need for walking. maybe multi player but no banking. Thanks guys. I will post anymore problems so stay tuned.

  11. #11
    Join Date
    Dec 2006
    Location
    Birmingham/UK
    Posts
    105
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    just incase u get sum total randomly random which may kill or teleport u u might loose your runes tht u buy maybe u should add like just for extra safety i would if it was mine although u would probs encounter more randoms walking lol oh well just a thaught
    If I see you autoing with level 3/default clothes/crap name I WILL report you. Auto Correctly. - put this in your sig<BR>
    http://www.draynor.net/skill/underse...dvance_war.png

  12. #12
    Join Date
    Jun 2007
    Location
    Portugal, somewhere.
    Posts
    15
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Hmmm I'm not sure but I think randoms can't appear while autobuying (or buying normally, for the matter)... I've seen a thug inside a rune shop (Aubury's on varrock) with lvl3 autobuyers, and the thug didn't attack them... I'm not sure but seems it's like I said. Or maybe it just applies for monsters? It only attacked characters that were moving around, not the autobuyers that were standing in a square. Anyone know?

  13. #13
    Join Date
    Sep 2006
    Location
    Great Britain
    Posts
    27
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Well it either means you're short of one 'begin'

    or you've got one too many 'end;' s

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. 'Begin' expected in script?
    By Mistagnerd in forum OSR Help
    Replies: 5
    Last Post: 11-12-2007, 10:01 AM
  2. Replies: 8
    Last Post: 04-09-2007, 12:21 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
  •