Results 1 to 10 of 10

Thread: Detect Mobile NPCs

  1. #1
    Join Date
    Oct 2012
    Posts
    25
    Mentioned
    0 Post(s)
    Quoted
    3 Post(s)

    Default Detect Mobile NPCs

    Bit of a vague question, but I am curious to know what methods exist and which are the most successful in detecting (and clicking on) mobile NPCs.

    I've tried several different strategies myself with little success.

    Any help will be appreciated.

  2. #2
    Join Date
    Oct 2012
    Posts
    25
    Mentioned
    0 Post(s)
    Quoted
    3 Post(s)

    Default

    To clarify this is for EOC RS, NOT 2007 RS

  3. #3
    Join Date
    Dec 2011
    Location
    Hyrule
    Posts
    8,662
    Mentioned
    179 Post(s)
    Quoted
    1870 Post(s)

    Default

    I just loop through my object finding functions quickly, sorting the atpa nearest to my mouse position. What are you trying to click on? If I can get butterfly's, I'm sure we can find a way for whatever you are looking to do

  4. #4
    Join Date
    Oct 2012
    Posts
    25
    Mentioned
    0 Post(s)
    Quoted
    3 Post(s)

    Default

    Currently working on attacking Goblins, nothing too complicated.

    I've been trying ACA and basic object finding with little success.

  5. #5
    Join Date
    Mar 2012
    Location
    Canada
    Posts
    442
    Mentioned
    4 Post(s)
    Quoted
    67 Post(s)

    Default

    can you post your attack procedure?

  6. #6
    Join Date
    Oct 2012
    Posts
    25
    Mentioned
    0 Post(s)
    Quoted
    3 Post(s)

    Default

    *Auto-Color Function*

    function GoblinColor: Integer;
    var
    arP: TPointArray;
    arC: TIntegerArray;
    tmpCTS, i, arL: Integer;
    begin
    tmpCTS := GetColorToleranceSpeed;
    ColorToleranceSpeed(2);
    SetColorSpeed2Modifiers(0.33, 0.09);

    if not (FindColorsTolerance(arP, 4619386, MSX1, MSY1, MSX2, MSY2, 7)) then
    begin
    Writeln('Failed to find the color, no result.');
    ColorToleranceSpeed(tmpCTS);
    SetColorSpeed2Modifiers(0.2, 0.2);
    Exit;
    end;

    arC := GetColors(arP);
    ClearSameIntegers(arC);
    arL := High(arC);

    for i := 0 to arL do
    begin
    Result := arC[i];
    Writeln('AutoColor = ' + IntToStr(arC[i]));
    Break;
    end;

    ColorToleranceSpeed(tmpCTS);
    SetColorSpeed2Modifiers(0.2, 0.2);

    if (i = arL + 1) then
    Writeln('AutoColor failed in finding the color.');
    end;




    *Attack Function*

    If FindObjTPA (x, y, GoblinColor, 2, 1, 1, 1, 1, [('ttack'), ('alk')]) then
    begin
    MMouse (x, y, 3, 3);
    Wait(60 + Random(30));
    If IsUpText ('ttack Goblin') then ClickMouse2(Mouse_Left);
    Wait(50 + Random(50));
    Wait (250 + random (100));
    Result := true;
    Exit;
    end else

    Rest is just failsafes that don't hinder NPC detection

  7. #7
    Join Date
    Oct 2012
    Posts
    25
    Mentioned
    0 Post(s)
    Quoted
    3 Post(s)

    Default

    When it detects the Goblin I have no problem clicking and fight it.

    I only have issues in detecting it (I will either find nothing when the color is present or the program will scan the uptext on completely wrong colors)

  8. #8
    Join Date
    Jan 2009
    Location
    Turlock/LA, California
    Posts
    1,494
    Mentioned
    3 Post(s)
    Quoted
    66 Post(s)

    Default

    though this might not be the easy answer out, i would recommend u switch to manually creating ATPAs for this. you will have far more control over your code and probably will increase the accuracy.

  9. #9
    Join Date
    Oct 2012
    Posts
    25
    Mentioned
    0 Post(s)
    Quoted
    3 Post(s)

    Default

    Quote Originally Posted by x[Warrior]x3500 View Post
    though this might not be the easy answer out, i would recommend u switch to manually creating ATPAs for this. you will have far more control over your code and probably will increase the accuracy.

    Alright, don't have much experience with TPAs / ATPAs but it can't hurt to try something new. Thanks

  10. #10
    Join Date
    Jan 2009
    Location
    Turlock/LA, California
    Posts
    1,494
    Mentioned
    3 Post(s)
    Quoted
    66 Post(s)

    Default

    Quote Originally Posted by ekips88 View Post
    Alright, don't have much experience with TPAs / ATPAs but it can't hurt to try something new. Thanks
    i've started making this to help out someone im tutoring in scripting (and others). only a few days in, and needs work, but i believe i did an ok job on the TPA/ATPA sections. check it out if u want, i havnt gotten into too much detail on how to use them for specific object finding yet, just the basics.

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
  •