Results 1 to 5 of 5

Thread: First script help

  1. #1
    Join Date
    Jun 2007
    Posts
    52
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default First script help

    ok, my script is a feather buyer, that buys the feathers, then waits for it to restock, then buys again. this is the script:

    ///////JACOBDM0\\\\\\\\\\\
    ////Setup on line 9\\\\\\\\
    ///Have Trade Window OPEN\\\


    program FeatherBuyer;

    Const
    /////// SETUP \\\\\\
    FeathersToBuy= 1000; //This is how many feathers you want to buy.
    BuyVariable= 10; //This is how many to buy at a time. (1, 5, or 10)

    //DO NOT TOUCH BELOW\\
    var
    i, sum: Integer;
    MoveMouseSmooth: String;

    begin;
    i:= 0;
    Repeat
    i= i+1;
    MoveMouseSmooth(380,79);
    ClickMouse(false);
    Wait(Random(2500));
    If (BuyVariable:= 10);
    Then
    Begin
    MoveMouseSmooth(345,146);
    ClickMouse(true);
    Wait(10000+Random(1000))
    end else
    If (BuyVariable:= 5);
    Then
    Begin
    MoveMouseSmooth(351,132);
    ClickMouse(true);
    Wait(5000+Random(1000))
    end else
    If (BuyVariable:= 1);
    Then
    Begin
    MoveMouseSmooth(348,119);
    ClickMouse(true);
    Wait(1000+Random(1000))
    Until ((FeathersToBuy/BuyVariable)=i)
    WriteLn('You Have finished buying your feathers')
    Wait(4000)
    Writln('Now Deleting all in debug box')
    Wait(5000)
    ClearDebug
    end.

    Whenever i try to run it...it says "Line 22: [error] (22:2): Assignment expected in script"

    Because this is my first script, and i am VERY new to scripting, i'm not sure what the problem is, or how to fix it. There also may be other errors, so if you find them, please tell me how to fix those too.

  2. #2
    Join Date
    Jun 2007
    Location
    New Yawk
    Posts
    943
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    You're missing a LOT of semicolons.
    I guess the holidays are over - no sig for now.

  3. #3
    Join Date
    Mar 2007
    Location
    Netherlands->Amersfoort.
    Posts
    1,615
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    u use things like:

    If (BuyVariable:= 1);
    Then
    Begin

    that cant because you allready close the ''if'' before you said ''then''. so:

    If (BuyVariable:= 1) Then
    Begin;

    the rest of the script

    -that erro was becasue you vergot to set a '':'' after the I

    SCAR Code:
    ///////JACOBDM0\\\\\\\\\\\
    ////Setup on line 9\\\\\\\\
    ///Have Trade Window OPEN\\\


    program FeatherBuyer;

    Const
    /////// SETUP \\\\\\
    FeathersToBuy= 1000; //This is how many feathers you want to buy.
    BuyVariable= 10; //This is how many to buy at a time. (1, 5, or 10)

    //DO NOT TOUCH BELOW\\
    var
    i, sum: Integer;
    MoveMouseSmooth: String;

    begin;
      I:= 0;
      Repeat;
        I:= I+1;
        MoveMouseSmooth(380, 79);
        ClickMouse(False);
        Wait(Random(2500));
        If (BuyVariable:= 10) Then
        Begin;
          MoveMouseSmooth(345,146);
          ClickMouse(true);
          Wait(10000+Random(1000))
        end else
        If (BuyVariable:= 5) Then
        Begin
          MoveMouseSmooth(351,132);
          ClickMouse(true);
          Wait(5000+Random(1000))
        end else
        If (BuyVariable:= 1) Then
        Begin
          MoveMouseSmooth(348,119);
          ClickMouse(true);
          Wait(1000+Random(1000))
      Until ((FeathersToBuy/BuyVariable)=i)
      WriteLn('You Have finished buying your feathers')
      Wait(4000)
      Writln('Now Deleting all in debug box')
      Wait(5000)
      ClearDebug
    end.

    just go tough your script with this guide: http://www.villavu.com/forum/showthread.php?t=6413 and try to fix the erros

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

    Default

    you don't need

    SCAR Code:
    MoveMouseSmooth: String;

    MoveMouseSmooth is already a procedure...

    SCAR Code:
    ClickMouse(False);

    You haven't got enough parameters in clickmouse.

    it should be

    SCAR Code:
    ClickMouse(x,y,False);

    where x and y are the co-ordinates.

    Another thing is

    SCAR Code:
    If (BuyVariable:= 10) Then

    you dont need the := it should be =

    SCAR Code:
    If (BuyVariable= 10) Then

  5. #5
    Join Date
    Feb 2007
    Location
    Alberta, Canada
    Posts
    4,615
    Mentioned
    50 Post(s)
    Quoted
    429 Post(s)

    Default

    Bent Zilla, good job.

    Ps- Clickmouse and MoveMouseSmooth and stuff = Ban. Use SRL MMouse and Mouse.

    Scripts: Edgeville Chop & Bank, GE Merchanting Aid
    Tutorials: How to Dominate the Grand Exchange

    Quote Originally Posted by YoHoJo View Post
    I like hentai.

Thread Information

Users Browsing this Thread

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

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •