Results 1 to 4 of 4

Thread: clicking on an npc

  1. #1
    Join Date
    May 2008
    Posts
    52
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default clicking on an npc

    I'm kinda a noob scripter, and I've started on a thieving script because there aren't many of them, and it will help me learn scripting. I'm to the point where I need to right click on an npc, and choose the pickpocketing option from the drop menu. However, I don't know how to do this due to my lack of experience of scripting. I'm guessing that this will need a procedure that incorporates DTM's or TPA's and have glanced at tutorials for both, but I didn't really understand either and how to incorporate it into a script like this. If someone could help me with this problem and possibly help with creating a procedure and explaining it, I would greatly appreciate it. Credit will be given in these procedures to whoever contributes with them. Thanks again.

  2. #2
    Join Date
    Apr 2007
    Location
    The Netherlands
    Posts
    5,553
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Hmm,

    Easy would be,
    SCAR Code:
    if SomeThingThatFindsTheNPcAndResultsTrue then
    Begin
      MMouse(X, Y, 3, 3);
      Wait(10+Random(20));
      If IsUpText('oblin') then//'oblin' is from Goblin
      Mouse(X,Y, 3,3, False);//Right Click so we see the option Pick-Pocket
      wait(10+random(20));
      If ChooseOption('pick-pocket') then writeln('Stole from goblin');
    End;


    Note: Wrote without scar out of scratch be aware of bugs
    ~Hermen

  3. #3
    Join Date
    Jul 2007
    Location
    Missouri
    Posts
    318
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Lol, i love the "SomeThingThatFindsTheNPcAndResultsTrue".

    if you want something that finds the npc try something easy like a FindColorsSpiralTolerance(depending if you know TPAs).

  4. #4
    Join Date
    May 2008
    Posts
    52
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by Hermpie View Post
    Hmm,

    Easy would be,
    SCAR Code:
    if SomeThingThatFindsTheNPcAndResultsTrue then
    Begin
      MMouse(X, Y, 3, 3);
      Wait(10+Random(20));
      If IsUpText('oblin') then//'oblin' is from Goblin
      Mouse(X,Y, 3,3, False);//Right Click so we see the option Pick-Pocket
      wait(10+random(20));
      If ChooseOption('pick-pocket') then writeln('Stole from goblin');
    End;


    Note: Wrote without scar out of scratch be aware of bugs
    Quote Originally Posted by Illkillutill View Post
    Lol, i love the "SomeThingThatFindsTheNPcAndResultsTrue".

    if you want something that finds the npc try something easy like a FindColorsSpiralTolerance(depending if you know TPAs).
    thanks hermpie, and illkillutill, I don't know how to use TPA's, but I'll take a closer look at the tutorials and FindColorsSpiralTolerance

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Help with clicking?
    By Kyle Undefined in forum OSR Help
    Replies: 20
    Last Post: 11-12-2008, 07:17 AM
  2. Dmt clicking help
    By MetalancA in forum OSR Help
    Replies: 7
    Last Post: 06-11-2008, 04:06 AM
  3. Not Clicking :(
    By skilld u in forum OSR Help
    Replies: 23
    Last Post: 06-09-2008, 10:20 PM
  4. Clicking
    By axel23 in forum OSR Help
    Replies: 3
    Last Post: 04-17-2007, 06:58 PM
  5. clicking on a NPC
    By legendaryhero90 in forum OSR Help
    Replies: 9
    Last Post: 02-25-2007, 10:53 PM

Posting Permissions

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