Page 2 of 8 FirstFirst 1234 ... LastLast
Results 26 to 50 of 200

Thread: How to create your first script

  1. #26
    Join Date
    Feb 2006
    Location
    L.A, USA
    Posts
    1,632
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Well this is a "make your very first script thread"

    Yea nice Bebe, many good comments from starters for you.

  2. #27
    Join Date
    Feb 2006
    Location
    Pennsylvania
    Posts
    1,524
    Mentioned
    2 Post(s)
    Quoted
    1 Post(s)

    Default

    Updated a bit, added a few things. Have fun learning

  3. #28
    Join Date
    Jun 2006
    Posts
    41
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    hay guys just so you know i,am starting to wright scrips in scar and going to sell them

    i have made and auto typer thats types hello world 1000000 times over i will be selling it for 10 mil rs gp

    lol

    nice tut dude i loved it

  4. #29
    Join Date
    Jun 2006
    Posts
    3
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Nice begineer tutorial for me. It helped alot with the basics. Just one question, after this tutorial am I supposed to be able to code like:

    Quote Originally Posted by Bebemycat2
    Code:
    program Bebeclicker;
    
    
    Const
    X=0; {X coord}
    Y=0; {Y coord}
    
    
    Procedure ClickHuman(x, y : Integer; left : Boolean);
    Begin
      holdmouse(x, y, left);
      wait(40 + random(50));
      releasemouse(x, y, left);
    End;
    
    Function Dist(a1, b1, a2, b2 : Integer) : Integer;
    Begin
      Result := Trunc(Sqrt(Sqr(a1 - a2) + Sqr(b1 - b2)) + 0.999999);
    End;
    
    
    procedure MouseC(Mousex, Mousey, Click : Integer);
    var
       Movex, Movey, Ax, Ay, Bx, By, Cx, Cy,
       T, tCubed, tSquared, Increase: extended;
       Con1x, Con1y, Con2x, Con2y, MinWait, MaxWait, SControl,
       EControl, Step, Tempx, Tempy, TempDistance: Integer;
    begin
         GetMousePos(Tempx, Tempy);
         TempDistance:= Dist(Mousex, Mousey, Tempx, Tempy);
         MinWait:= 2;
         MaxWait:= 5;
         SControl:= TempDistance div 6;
         EControl:= TempDistance div 2;
         Step:= 7;
         If not(TempDistance = 0)Then
           Increase:= (1 div TempDistance) * Step;
         Con1x:= Tempx + Random(SControl * 2) - SControl;
         Con1y:= Tempy + Random(SControl * 2) - SControl;
         Con2x:= Mousex + Random(EControl * 2) - EControl;
         Con2y:= Mousey + Random(EControl * 2) - EControl;
         Cx:= 3 * (Con1x - Tempx);
         Bx:= 3 * (Con2x - Con1x) - Cx;
         Ax:= Mousex - Tempx - Cx - Bx;
         Cy:= 3 * (Con1y - Tempy);
         By:= 3 * (Con2y - Con1y) - Cy;
         Ay:= Mousey - Tempy - Cy - By;
         repeat
               T:= T + Increase;
               tSquared:= T * T;
               tCubed:= tSquared * T;
               Movex:= (Ax * tCubed) + (Bx * tSquared) + (Cx * t) + Tempx;
               Movey:= (Ay * tCubed) + (By * tSquared) + (Cy * t) + Tempy;
               MoveMouse(Round(Movex), Round(Movey));
               Wait(Random(MaxWait - MinWait) + MinWait);
         until(T >= 1)or
         (Movex = Mousex)and(Movey = Mousey);
         if (Movex <> Mousex) or (Movey <> Mousey) then
            MoveMouseSmooth(Mousex, Mousey);
         Wait(40 + Random(20));
        Case click Of
          1 : Clickhuman(Mousex, Mousey, true);
          2 : Clickhuman(Mousex, Mousey, false);
        End;
    end;
    
    
    Procedure Clicky;
    begin
      MouseC(X+random(40),Y+random(40),0);
      wait(70+random(40));
      MouseC(X,Y,1);
    end;
    
    begin
     repeat
      Clicky;
     until(false)
    end.

  5. #30
    Join Date
    Jun 2006
    Location
    California
    Posts
    14
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default Thnx for the help.

    Thanks for making this tutorial. It really helped me understand how scripts and scripting work. I'm looking forward to the next one.

  6. #31
    Join Date
    Feb 2006
    Location
    Pennsylvania
    Posts
    1,524
    Mentioned
    2 Post(s)
    Quoted
    1 Post(s)

    Default

    I have another tutorial almost finished, but I am busy lately and havn't been able to put the final touches on it.

    Glad you learned something from it.

  7. #32
    Join Date
    Jul 2006
    Location
    Michigan, USA
    Posts
    3
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Thanks for posting this, its helped
    New to scar scripting, but trying to learn :-P

  8. #33
    Join Date
    Jun 2006
    Posts
    43
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Thank you! I made my first working script

    SCAR Code:
    {
    In_Jeopardy's Autospammer!!
    }


    program Autotalker;

    const
    Spam='lololol';

    procedure Autospam;
    begin
     wait(5000)
     Writeln(Spam);
    end;

    begin
     repeat
     Autospam;
     until(false)
    end.
    Every time you macro, you kill a bunny...

    Kill all of the bunnies

  9. #34
    Join Date
    Sep 2006
    Posts
    1
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    this helps me alot

  10. #35
    Join Date
    Sep 2006
    Posts
    20
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    scar reminds me of delphi but with delphi there was an interface and vars, tho the rest look the same. can't wait till the tut continues. I wanna learn how to script for runescape.

  11. #36
    Join Date
    Feb 2006
    Location
    Pennsylvania
    Posts
    1,524
    Mentioned
    2 Post(s)
    Quoted
    1 Post(s)

    Default

    Quote Originally Posted by lizhang View Post
    scar reminds me of delphi but with delphi there was an interface and vars, tho the rest look the same. can't wait till the tut continues. I wanna learn how to script for runescape.
    SCAR was made in Delphi

  12. #37
    Join Date
    Jun 2006
    Posts
    17
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default yay!

    w00t! I worked! Thanks :-D Makes me wanna try my hand at somethin' more complex =)

  13. #38
    Join Date
    Sep 2006
    Posts
    25
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    try this: (my first script)

    SCAR Code:
    program script;

    procedure Hello;
    begin
      wait(70)
       writeln('H');
        Wait (70)
         Writeln('He')
          wait(70)
           writeln('Hel');
            wait(70)
             writeln('Hell');
              wait(70)
               writeln('Hello');
                wait(70)
                 writeln('Hello ');
                  wait(70)
                   writeln('Hello w');
                    wait(70)
                     writeln('Hello wo');
                      wait(70)
                       writeln('Hello wor');
                        wait(70)
                         writeln('Hello worl');
                          wait(70)
                           writeln('Hello world');
                            wait(70)
                             writeln('Hello world!');
    end;


    begin
     repeat
       hello;
     until(false)
    end.

  14. #39
    Join Date
    Sep 2006
    Location
    The Netherlands
    Posts
    9
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    you are my hero!!! (A) :P

    very helpful guide!

  15. #40
    Join Date
    Oct 2006
    Posts
    7
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Very nice i enjoyed working through this.

  16. #41
    Join Date
    Feb 2006
    Location
    Pennsylvania
    Posts
    1,524
    Mentioned
    2 Post(s)
    Quoted
    1 Post(s)

    Default

    wstephen4, lol you'll have to learn more, but you'll get there.

    Invisable, use standards.

    SCAR Code:
    program script;

    procedure Hello;
    begin
      wait(70)
      writeln('H');
      Wait (70)
      Writeln('He')
      wait(70)
      writeln('Hel');
      wait(70)
      writeln('Hell');
      wait(70)
      writeln('Hello');
      wait(70)
      writeln('Hello ');
      wait(70)
      writeln('Hello w');
      wait(70)
      writeln('Hello wo');
      wait(70)
      writeln('Hello wor');
      wait(70)
      writeln('Hello worl');
      wait(70)
      writeln('Hello world');
      wait(70)
      writeln('Hello world!');
    end;


    begin
     repeat
       hello;
     until(false)
    end.

    Also you might wana try somthing like this:
    SCAR Code:
    program script;

    procedure Hello;
    begin
      wait(70)
      cleardebug;
      writeln('H');
      Wait (70)
      cleardebug;
      Writeln('He')
      wait(70)
      cleardebug;
      writeln('Hel');
      wait(70)
      cleardebug;
      writeln('Hell');
      wait(70)
      cleardebug;
      writeln('Hello');
      wait(70)
      cleardebug;
      writeln('Hello ');
      wait(70)
      cleardebug;
      writeln('Hello w');
      wait(70)
      cleardebug;
      writeln('Hello wo');
      wait(70)
      cleardebug;
      writeln('Hello wor');
      wait(70)
      cleardebug;
      writeln('Hello worl');
      wait(70)
      cleardebug;
      writeln('Hello world');
      wait(70)
      cleardebug;
      writeln('Hello world!');
    end;


    begin
     repeat
       hello;
     until(false)
    end.

  17. #42
    Join Date
    Oct 2006
    Posts
    35
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    I've just read the first tut;

    Thanks... At first I thought it was WriteIn not Writeln...had to spend about 5 minutes on

    that one :O

    I've seen plenty of hello world scripts, but none that was as explained as yours Thanks

    for letting me make a script that I actually understand fully

  18. #43
    Join Date
    Oct 2006
    Posts
    35
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    this is one of the best tuts ve seen kinda confusing but i got it to work im gonna try to figure out how to make like auto fighters and stuff now tho.. if i can so i can apply as a srl member when i have a few more posts

  19. #44
    Join Date
    Oct 2006
    Posts
    7
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    sweet i got it to work thanks man im gonna start making some scripts..this is awesome

  20. #45
    Join Date
    Oct 2006
    Posts
    35
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    ahh! i just figured it out, (im such a n00b at this lol)

    i had this:

    program Hello;

    const
    Message1='Hello world!;

    there was my mistake..

    it was meant to be like this=

    program Hello;

    const
    Message1='Hello world';

    thanks guys, great tutorial!

  21. #46
    Join Date
    Oct 2006
    Posts
    35
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    this is an excellent beginners tutorial, im a complete n00b with no programming skillz what so ever and even i can understand it!

    much appreciated!

    PS really looking forward to the next tut guide bebe!! i am very keen to learn more

  22. #47
    Join Date
    Oct 2006
    Posts
    35
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default My first script

    its no autoer, but its a start s'pose

    SCAR Code:
    program tryit;

    const
    Message1='motherloverr';
    procedure tryit;
    begin
    wait(1500)
    writeln(message1);
    end;

    begin
    repeat
    tryit;
    until(true)
    end.

  23. #48
    Join Date
    Jun 2006
    Posts
    366
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Thx great tutorial.. I have one question.. with srl whts the difference.. I mean if i tell it to include srl does that mean I can use procedures or functions from the the file I uploaded. Also whats the difference between procedure and function... ANd wht tutorial would you recomend next for me.... And also :P If any1 here wants to help me out can they lemme noe and I pm them my email addresse, because I tried making scar scripts long time ago but no one really helped. It was on the forum rs-resources. I also tried making scripts for aryan, and when I finally got started, aryan was dead...

    And 1 last thing My past scripting experience is scripting in the program Turing (for school) I think turing is like java though, but you think it 'll be any help?.. And where can i get list of commands for scar...

  24. #49
    Join Date
    Oct 2006
    Posts
    1
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    help full

    hey this was good

  25. #50
    Join Date
    Oct 2006
    Posts
    21
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    This tutorial makes everything seem so easy...

Page 2 of 8 FirstFirst 1234 ... LastLast

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. create short script...
    By supersayian2224 in forum OSR Help
    Replies: 6
    Last Post: 01-16-2009, 03:30 AM
  2. For all that want to create a first script
    By Spiritualowl in forum OSR Help
    Replies: 3
    Last Post: 03-16-2008, 02:49 AM
  3. Someone help me create first script?
    By Immortal_DemiGod in forum OSR Help
    Replies: 13
    Last Post: 12-23-2007, 03: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
  •