Page 2 of 4 FirstFirst 1234 LastLast
Results 26 to 50 of 98

Thread: Rucoy Online Script

  1. #26
    Join Date
    Dec 2013
    Posts
    11
    Mentioned
    0 Post(s)
    Quoted
    11 Post(s)

    Default

    I narrowed it down to finding out that it occurs when the NoxPlayer application gets minimized.

    I'm having trouble finding information about botting on Rucoy.

    Do you know if they do bot checks of any kind or check their logs by chance?
    If so, do they flag IPs to your knowledge or is it a simple account ban?

  2. #27
    Join Date
    May 2012
    Location
    Glorious Nippon
    Posts
    1,011
    Mentioned
    50 Post(s)
    Quoted
    505 Post(s)

    Default

    Quote Originally Posted by Malouy View Post
    I narrowed it down to finding out that it occurs when the NoxPlayer application gets minimized.

    I'm having trouble finding information about botting on Rucoy.

    Do you know if they do bot checks of any kind or check their logs by chance?
    If so, do they flag IPs to your knowledge or is it a simple account ban?
    Oh yeah, you can't minimize the window. You can move it off screen though.

    Players can report other players, but AFAIK there is only one person who can ban people, so it's really hard to get banned.
    There is an automatic system in place with training weapons, so I don't recommend using them. My first account was banned because I didn't know about it, but I had no problem making a new account.
    It's a really small game with only 2 people working on it, so I wouldn't worry too much about any kind of anti-bot measures.

  3. #28
    Join Date
    Dec 2013
    Posts
    11
    Mentioned
    0 Post(s)
    Quoted
    11 Post(s)

    Default

    Quote Originally Posted by Citrus View Post
    Oh yeah, you can't minimize the window. You can move it off screen though.

    Players can report other players, but AFAIK there is only one person who can ban people, so it's really hard to get banned.
    There is an automatic system in place with training weapons, so I don't recommend using them. My first account was banned because I didn't know about it, but I had no problem making a new account.
    It's a really small game with only 2 people working on it, so I wouldn't worry too much about any kind of anti-bot measures.
    That's good news for botters for now, if there truly is one person who can ban.
    I wonder what type of automatic system they have setup. (time delay, repetitive action, etc.)

    Your input is greatly appreciated.

    If you ever get a chance and want to, I would enjoy figuring out how to modify a few things the script does.

    EDIT:: watching 3 characters fly around Rucoy attacking and looting is just as exhilarating as it was back in 2003 on RS.
    Last edited by Malouy; 07-17-2017 at 05:59 AM.

  4. #29
    Join Date
    May 2012
    Location
    Glorious Nippon
    Posts
    1,011
    Mentioned
    50 Post(s)
    Quoted
    505 Post(s)

    Default

    Quote Originally Posted by Malouy View Post
    If you ever get a chance and want to, I would enjoy figuring out how to modify a few things the script does.
    Sure. You can post here, PM me here, or on Discord (you can direct message me): whichever works for you.

  5. #30
    Join Date
    Dec 2013
    Posts
    11
    Mentioned
    0 Post(s)
    Quoted
    11 Post(s)

    Default

    Quote Originally Posted by Citrus View Post
    Sure. You can post here, PM me here, or on Discord (you can direct message me): whichever works for you.
    Seeing as this is a community script and I only wish to add to it, we may as well do it here!
    I'm happy that you are willing to help.

    I've been trying to refresh myself on Simba and the basics before I ask questions that could easily be learned through other sources.

    Could you give me a quick break down of how this function works?
    Specifically how I would alter this to read the health bar? I know that the health bar uses a common color shared with many others objects and npcs in game, but couldn't the script be written in a way that uses location on the application to only read the color there? Isn't that what yours is guiding it to do?

    Code:
    function getManaPercent(): integer;
    var
      tpa: TPointArray;
    begin
      result := 100 * countColor(mana_blue, 5, 62, 249, 66) div 1225;
    end;

  6. #31
    Join Date
    May 2012
    Location
    Glorious Nippon
    Posts
    1,011
    Mentioned
    50 Post(s)
    Quoted
    505 Post(s)

    Default

    Quote Originally Posted by Malouy View Post
    Seeing as this is a community script and I only wish to add to it, we may as well do it here!
    I'm happy that you are willing to help.

    I've been trying to refresh myself on Simba and the basics before I ask questions that could easily be learned through other sources.

    Could you give me a quick break down of how this function works?
    Specifically how I would alter this to read the health bar? I know that the health bar uses a common color shared with many others objects and npcs in game, but couldn't the script be written in a way that uses location on the application to only read the color there? Isn't that what yours is guiding it to do?

    Code:
    function getManaPercent(): integer;
    var
      tpa: TPointArray;
    begin
      result := 100 * countColor(mana_blue, 5, 62, 249, 66) div 1225;
    end;
    Sure. First of all, the variable (tpa) shouldn't be there; it isn't used. I could have done a lot more cleanup of the script before I posted it. I've removed it in the OP.
    The getManaPercent function just counts (with countColor) all of the pixels of color "mana_blue," which is a constant defined at the top of the script. Once they are counted, divide by the maximum number of pixels (1225) and multiply by 100 to get an integer percent.

    The quick and dirty way to get health percent would be to do the exact same thing. The problem is the numbers inside the bar. They will change the pixel count by a little, so you might not get 100% accurate results. Honestly this method is perfectly adequate for this game.

    Another fairly simple way would be to compare the width of the bar, instead of the area. This solves the problem with the numbers.

    You could also read the numbers with Tesseract or create a custom font, but those are both overkill IMO.

  7. #32
    Join Date
    Dec 2013
    Posts
    11
    Mentioned
    0 Post(s)
    Quoted
    11 Post(s)

    Default

    Quote Originally Posted by Citrus View Post
    Sure. First of all, the variable (tpa) shouldn't be there; it isn't used. I could have done a lot more cleanup of the script before I posted it. I've removed it in the OP.
    The getManaPercent function just counts (with countColor) all of the pixels of color "mana_blue," which is a constant defined at the top of the script. Once they are counted, divide by the maximum number of pixels (1225) and multiply by 100 to get an integer percent.

    The quick and dirty way to get health percent would be to do the exact same thing. The problem is the numbers inside the bar. They will change the pixel count by a little, so you might not get 100% accurate results. Honestly this method is perfectly adequate for this game.

    Another fairly simple way would be to compare the width of the bar, instead of the area. This solves the problem with the numbers.

    You could also read the numbers with Tesseract or create a custom font, but those are both overkill IMO.
    I agree that this method is perfectly adquate, as long as it keeps me alive longer I'm happy.
    Is the maximum number 1225 for the specific resolution of 798x482?

    I'm not understanding the difference between the width of the bar and the area of the bar, could you expound on that?

    Code:
    function getManaPercent(): integer;
    begin
      result := 100 * countColor(mana_blue, 5, 62, 249, 66) div 1225;
    end;
    What are the numbers after "mana_blue"? I was under the impression they would be coordinates.

    Code:
    procedure clickMPot();
    begin
      mouse([39, 409]);
    end;
    This procedure works by clicking the coordinate, right?

  8. #33
    Join Date
    May 2012
    Location
    Glorious Nippon
    Posts
    1,011
    Mentioned
    50 Post(s)
    Quoted
    505 Post(s)

    Default

    Quote Originally Posted by Malouy View Post
    I agree that this method is perfectly adquate, as long as it keeps me alive longer I'm happy.
    Is the maximum number 1225 for the specific resolution of 798x482?
    Yes, all of the coordinates are specific to one resolution. It wouldn't be too hard to write it to be used at any resolution, but I'm way too lazy for that.

    I'm not understanding the difference between the width of the bar and the area of the bar, could you expound on that?
    Width is just width. Area is (width * height). The mana function uses area because countColor is given a box to search in. You could set the search box to have a height of 1, in which case you'd only be using width. i.e. (width * 1) = width

    Code:
    function getManaPercent(): integer;
    begin
      result := 100 * countColor(mana_blue, 5, 62, 249, 66) div 1225;
    end;
    What are the numbers after "mana_blue"? I was under the impression they would be coordinates.
    Here is the documentation for CountColor. After the color, you give it the bounds of the box to search in (so yes, they are coordinates). It returns the number of pixels found.

    Code:
    procedure clickMPot();
    begin
      mouse([39, 409]);
    end;
    This procedure works by clicking the coordinate, right?
    Yes, that procedure just clicks a static coordinate.

    I'm heading out now; I'll be able to respond again in ~8 hours. I recommend looking through the documentation and tutorials like this one to further your learning. Good luck!

  9. #34
    Join Date
    Dec 2013
    Posts
    11
    Mentioned
    0 Post(s)
    Quoted
    11 Post(s)

    Default

    Quote Originally Posted by Citrus View Post
    Yes, all of the coordinates are specific to one resolution. It wouldn't be too hard to write it to be used at any resolution, but I'm way too lazy for that.


    Width is just width. Area is (width * height). The mana function uses area because countColor is given a box to search in. You could set the search box to have a height of 1, in which case you'd only be using width. i.e. (width * 1) = width


    Here is the documentation for CountColor. After the color, you give it the bounds of the box to search in (so yes, they are coordinates). It returns the number of pixels found.


    Yes, that procedure just clicks a static coordinate.

    I'm heading out now; I'll be able to respond again in ~8 hours. I recommend looking through the documentation and tutorials like this one to further your learning. Good luck!
    I can't blame you on that note.

    I was specifically wondering how you got 1225 as a maximum number of pixels.
    Wouldn't 1225 be the maximum of the area you prescribed?
    Code:
    5, 62, 249, 66
    i.e. 245x4= 980

    My question regarding the difference in measuring area and width was not explained correctly on my end. I more so meant how that changes the code.
    Would it be something like the snippet below?
    Code:
    function getManaPercent(): integer;
    begin
      result := 100 * countColor(mana_blue, 5, 62, 249, 62) div 1225;
    end;
    Keeping it in a single line or would there be a simpler way that I am overlooking?

    I was able to set an area just beyond the text in the health bar.
    I set the area to count the grey and drink a health potion in the case that area reached > 90.
    I had to figure out that 1225 was the maximum pixels for the getManaPercent parameters and that the maximum was different for my static coordinates in order for it to work.

    I'm trying to figure out how to keep it from hopping around so much when it is in maze like areas.
    I'm supposing there could be a procedure specifically coded for mazes to recognize the wall colors and not cross them?

  10. #35
    Join Date
    May 2012
    Location
    Glorious Nippon
    Posts
    1,011
    Mentioned
    50 Post(s)
    Quoted
    505 Post(s)

    Default

    Quote Originally Posted by Malouy View Post
    I can't blame you on that note.

    I was specifically wondering how you got 1225 as a maximum number of pixels.
    Wouldn't 1225 be the maximum of the area you prescribed?
    Code:
    5, 62, 249, 66
    i.e. 245x4= 980
    Your math is inconsistent; you have the proper width, but the height should be 5.
    I just tested this, and it was off by a pixel. The correct bounds should be: [4, 62, 248, 66], but you can safely expand them by a couple pixels and the result won't change.

    My question regarding the difference in measuring area and width was not explained correctly on my end. I more so meant how that changes the code.
    Would it be something like the snippet below?
    Code:
    function getManaPercent(): integer;
    begin
      result := 100 * countColor(mana_blue, 5, 62, 249, 62) div 1225;
    end;
    Keeping it in a single line or would there be a simpler way that I am overlooking?
    The best way to find out is to test it yourself
    Yes, this is what I was thinking, although you'll need to figure out what the count is when your health is full, as well as which coordinates to search such that you avoid the white numbers (sounds like you did this below).

    I was able to set an area just beyond the text in the health bar.
    I set the area to count the grey and drink a health potion in the case that area reached > 90.
    I had to figure out that 1225 was the maximum pixels for the getManaPercent parameters and that the maximum was different for my static coordinates in order for it to work.

    I'm trying to figure out how to keep it from hopping around so much when it is in maze like areas.
    I'm supposing there could be a procedure specifically coded for mazes to recognize the wall colors and not cross them?
    Ahh.. that's a whole new can of worms. I may have messed around with this, but I probably decided to just skip the maze altogether. All of the tools are in the script already (validTile, etc.), but you'll need to figure out if there is an unbroken line of valid tiles between you and your destination. Should be a fun little problem to solve

  11. #36
    Join Date
    Dec 2013
    Posts
    11
    Mentioned
    0 Post(s)
    Quoted
    11 Post(s)

    Default

    Quote Originally Posted by Citrus View Post
    Your math is inconsistent; you have the proper width, but the height should be 5.
    I just tested this, and it was off by a pixel. The correct bounds should be: [4, 62, 248, 66], but you can safely expand them by a couple pixels and the result won't change.
    Yea I totally spaced on my math there, lol. I wondered why I couldn't get 1225 with any of my math! hah!


    Quote Originally Posted by Citrus View Post
    Ahh.. that's a whole new can of worms. I may have messed around with this, but I probably decided to just skip the maze altogether. All of the tools are in the script already (validTile, etc.), but you'll need to figure out if there is an unbroken line of valid tiles between you and your destination. Should be a fun little problem to solve
    I just have to figure out more so what each snippet is and how it works.
    Guides never have done it for me, I have to get my hands on the script and fittle with things until they work. I do best when I can break and fix already created code to figure out how I can go about making my own.

    It'll definitely be a problem to solve, if I make the time.

    Something I am interested in learning to do again would be to get a kill log or atleast a log on how many times it clicked a monster or the loot hand, etc.

    Any suggestions on where I would go to learn this? the guide touched on things similar but I couldn't make out how I would translate it to working with the current script.

  12. #37
    Join Date
    May 2012
    Location
    Glorious Nippon
    Posts
    1,011
    Mentioned
    50 Post(s)
    Quoted
    505 Post(s)

    Default

    Quote Originally Posted by Malouy View Post
    Something I am interested in learning to do again would be to get a kill log or atleast a log on how many times it clicked a monster or the loot hand, etc.

    Any suggestions on where I would go to learn this? the guide touched on things similar but I couldn't make out how I would translate it to working with the current script.
    Sure, that's pretty simple. You'll just need global variable for each thing you want to track. An integer is fine for kill/loot counts. Just increment the variable every time you do the thing (kill, loot, etc).

    Here is some simple pseudo-Simba-code:
    Simba Code:
    program Rucoy;

    var
      KillCount, LootCount: Int32;

    procedure KillStuff;
    begin
      //find monsters..
      ClickMonster;
      Inc(KillCount);
    end;

    procedure LootStuff;
    begin
      //check for loot hand
      ClickLootHand;
      Inc(LootCount);
    end;

    procedure UpdateProgress;
    begin
      ClearDebug;
      WriteLn('Killed ', KillCount, ' monsters and looted ', LootCount, ' loots in ', MsToTime(GetTimeRunning));
    end;
    Call UpdateProgess as often as you want. You could make a timer for it, or just call it every mainloop.

    Here is a butchered MsToTime from SRL-6:
    Simba Code:
    function msToTime(MS: Integer): string;
    var
      STA: array [0..5] of TVariantArray;
      Time: array of Integer;
      i, t, tl: Integer;
    begin
      Result := '';

      tl := 3;
      t := 2;
      SetLength(Time,tl);
      ConvertTime(MS, Time[0], Time[1], Time[2]);

      STA[3] := [':', ':', '', True, 2];

      for i := 0 to t do
        if (Time[i] > 0) or (STA[3][tl]) or (i = t) then
          Result := Result + PadZ(IntToStr(Time[i]), STA[3][tl+1]) + STA[3][i];
    end;

  13. #38
    Join Date
    Dec 2013
    Posts
    11
    Mentioned
    0 Post(s)
    Quoted
    11 Post(s)

    Default

    Quote Originally Posted by Citrus View Post
    Sure, that's pretty simple. You'll just need global variable for each thing you want to track. An integer is fine for kill/loot counts. Just increment the variable every time you do the thing (kill, loot, etc).

    Here is some simple pseudo-Simba-code:
    Simba Code:
    program Rucoy;

    var
      KillCount, LootCount: Int32;

    procedure KillStuff;
    begin
      //find monsters..
      ClickMonster;
      Inc(KillCount);
    end;

    procedure LootStuff;
    begin
      //check for loot hand
      ClickLootHand;
      Inc(LootCount);
    end;

    procedure UpdateProgress;
    begin
      ClearDebug;
      WriteLn('Killed ', KillCount, ' monsters and looted ', LootCount, ' loots in ', MsToTime(GetTimeRunning));
    end;
    Call UpdateProgess as often as you want. You could make a timer for it, or just call it every mainloop.

    Here is a butchered MsToTime from SRL-6:
    Simba Code:
    function msToTime(MS: Integer): string;
    var
      STA: array [0..5] of TVariantArray;
      Time: array of Integer;
      i, t, tl: Integer;
    begin
      Result := '';

      tl := 3;
      t := 2;
      SetLength(Time,tl);
      ConvertTime(MS, Time[0], Time[1], Time[2]);

      STA[3] := [':', ':', '', True, 2];

      for i := 0 to t do
        if (Time[i] > 0) or (STA[3][tl]) or (i = t) then
          Result := Result + PadZ(IntToStr(Time[i]), STA[3][tl+1]) + STA[3][i];
    end;
    I'll have to play with this when I get the chance.

    I'd like to see if I can get it to work and have it record how many pots it drank etc.

    One function I want to add asap is a recogniztion of monsters being used by other players. There is a red exclamation just like when looting items that don't belong to you.
    I believe I could use a static coordinate with the color and tell it to deviate from the area before attacking another monster or something of the sorts.

    Bleh, lots to learn!

    I appreciate you again, thank you very much.

  14. #39
    Join Date
    May 2012
    Location
    Glorious Nippon
    Posts
    1,011
    Mentioned
    50 Post(s)
    Quoted
    505 Post(s)

    Default

    Quote Originally Posted by Malouy View Post
    One function I want to add asap is a recogniztion of monsters being used by other players. There is a red exclamation just like when looting items that don't belong to you.
    I believe I could use a static coordinate with the color and tell it to deviate from the area before attacking another monster or something of the sorts.
    I thought that was already in the script, but maybe an update broke it. You're talking about training weapons right? The script should walk away if the training weapon message is on screen.

  15. #40
    Join Date
    Dec 2013
    Posts
    11
    Mentioned
    0 Post(s)
    Quoted
    11 Post(s)

    Default

    Quote Originally Posted by Citrus View Post
    I thought that was already in the script, but maybe an update broke it. You're talking about training weapons right? The script should walk away if the training weapon message is on screen.
    Where in the code is that?
    I haven't experienced it attempting to walk away once, it just gets stuck there attacking it.

    I've looked through the code entirely and either I am missing something or... it is missing. lol :P

  16. #41
    Join Date
    May 2012
    Location
    Glorious Nippon
    Posts
    1,011
    Mentioned
    50 Post(s)
    Quoted
    505 Post(s)

    Default

    Quote Originally Posted by Malouy View Post
    Where in the code is that?
    I haven't experienced it attempting to walk away once, it just gets stuck there attacking it.

    I've looked through the code entirely and either I am missing something or... it is missing. lol :P
    The isTraining function on line 505 in the OP.

  17. #42
    Join Date
    Jul 2017
    Posts
    1
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    So i finally got it to work but only on skeletons, and for some reason it only clicks right and no where else until it gets to a wall then just stops there

  18. #43
    Join Date
    Aug 2017
    Posts
    3
    Mentioned
    0 Post(s)
    Quoted
    2 Post(s)

    Default

    Need help i'm use range it stuck whenever enemy is out of range and it doesnt walk to enemy can you fix it ? sorry for my bad eng

    this example it doesnt move anyway
    bug.jpg
    Last edited by toa55toe; 08-11-2017 at 08:04 PM.

  19. #44
    Join Date
    May 2012
    Location
    Glorious Nippon
    Posts
    1,011
    Mentioned
    50 Post(s)
    Quoted
    505 Post(s)

    Default

    Quote Originally Posted by toa55toe View Post
    Need help i'm use range it stuck whenever enemy is out of range and it doesnt walk to enemy can you fix it ? sorry for my bad eng

    this example it doesnt move anyway
    bug.jpg
    It should walk next to the enemy. Does it always get stuck when the enemy is out of range?
    Either it isn't finding valid tiles, or the range calculation is off. You can change the number in the "isInRange" function and see if that helps.

  20. #45
    Join Date
    Aug 2017
    Posts
    3
    Mentioned
    0 Post(s)
    Quoted
    2 Post(s)

    Default

    Quote Originally Posted by Citrus View Post
    It should walk next to the enemy. Does it always get stuck when the enemy is out of range?
    Either it isn't finding valid tiles, or the range calculation is off. You can change the number in the "isInRange" function and see if that helps.
    I change the number in the isinrange but it dont help
    I try to change a warrior it is no problem at all.
    https://youtu.be/whMUtCUybIA

  21. #46
    Join Date
    May 2012
    Location
    Glorious Nippon
    Posts
    1,011
    Mentioned
    50 Post(s)
    Quoted
    505 Post(s)

    Default

    Quote Originally Posted by toa55toe View Post
    I change the number in the isinrange but it dont help
    I try to change a warrior it is no problem at all.
    https://youtu.be/whMUtCUybIA
    Try debugging "isInRange" with this:
    Simba Code:
    writeln(tileDist(player_tile, t));

  22. #47
    Join Date
    Aug 2017
    Posts
    3
    Mentioned
    0 Post(s)
    Quoted
    2 Post(s)

    Default

    Quote Originally Posted by Citrus View Post
    Try debugging "isInRange" with this:
    Simba Code:
    writeln(tileDist(player_tile, t));
    it doesnt work it's still stuck TT

  23. #48
    Join Date
    Aug 2017
    Posts
    23
    Mentioned
    1 Post(s)
    Quoted
    4 Post(s)

    Default

    Has anyone tried this in Bluestacks yet?

  24. #49
    Join Date
    Jan 2018
    Posts
    13
    Mentioned
    0 Post(s)
    Quoted
    3 Post(s)

    Default

    [deleted];
    Last edited by Relentless; 01-26-2018 at 12:40 AM.

  25. #50
    Join Date
    May 2012
    Location
    Glorious Nippon
    Posts
    1,011
    Mentioned
    50 Post(s)
    Quoted
    505 Post(s)

    Default

    Quote Originally Posted by MichaelFortis View Post
    Hey man. I need your help. I can't understand how does this part of your code work. I really hope you will help me. And I'm really appreciate it.
    Sure! I'll try to explain everything, but it sounds like you're pretty new to scripting, so I think you'll benefit more from reading a few beginner tutorials first.
    Here is a good place to start: https://villavu.com/forum/showthread.php?t=58935
    Also keep in mind that I wrote this a long time ago and haven't used it or even looked at it in a while

    Simba Code:
    1. function clickClosestNPC(): boolean;
    2. var
    3.   i, j, x, y: integer;
    4.   b: TBox;
    5.   p: TPoint;
    6.   tpa, tpa2: TPointArray;
    7.   atpa, temp: T2DPointArray;
    8. begin
    9.   if findColors(tpa, hp_green, msx1, msy1, msx2, msy2) then
    10.   begin
    11.     if findColors(tpa2, hp_yellow, msx1, msy1, msx2, msy2) then tpa := combineTPA(tpa, tpa2);
    12.     if findColors(tpa2, hp_gray, msx1, msy1, msx2, msy2) then tpa := combineTPA(tpa, tpa2);
    13.     if findColors(tpa2, red_square, msx1, msy1, msx2, msy2) then tpa := combineTPA(tpa, tpa2);
    14. //all of these 'findColors' are finding the various possible colors of the NPC HP bars and combining them
    15.     tpa.filterPointsBox([375, 240, 425, 250]); //exclude points in this box
    16.     atpa := clusterTPA(tpa, 1); //ideally we get a different cluster for each NPC
    17.     filterTPAsBetween(atpa, 222, 9000); //filter out TPAs that are too big
    18.     filterTPAsBetween(atpa, 0, 50); //filter out TPAs that are too small
    19.     for i := 0 to high(atpa) do
    20.     begin
    21.       b := getTPABounds(atpa[i]); //this just returns a TBox of the TPA's bounds
    22.       b.edit(+4, 0, -4, 0); //slightly edit the box
    23.       if (b.x1 >= b.x2) then continue(); //skip the box if the bounds are messed up for some reason
    24.       if (inRange((b.y2-b.y1), 2, 5)) then //check the the box is the right height
    25.         if ((countColor(text_white, b.x1, b.y1-12, b.x2, b.y2) > 88) or //check for white text of monster's name
    26.             (countColor(text_yellow, b.x1, b.y1-12, b.x2, b.y2) > 88)) then //check for yellow text of monster's name
    27.           temp := temp + atpa[i]; //assign all of the "good" monsters to a temporary variable
    28.     end;
    29.     if (length(temp) > 0) then //make sure we found at least one good monster
    30.     begin
    31.       sortATPAFromMidPoint(temp, player_point); //get the closest monster first
    32.       for i := 0 to high(temp) do //loop through each good monster in 'temp'
    33.       begin
    34.         p := middleTPA(temp[0]); //get the middle of the first point. this might be an error? should be 'temp[i]' maybe. idk
    35.         b := getTile(pointToTile(p)); //convert from point to tile box
    36.         for j := 0 to high(tile_colors) do //check each valid tile color
    37.         begin
    38.           if findColor(x, y, tile_colors[j], b.x1, b.y1, b.x2, b.y2) then //check if the color is found within the tile box
    39.           begin
    40.             p.y := min(p.y + random(10, 25), _h-7); //offset the Y coordinate, since the HP bar is above the NPC's head
    41.             p.x := p.x + random(-10, 10); //randomize the X a bit
    42.             mouse(p, mouse_left); wait(345);
    43.             exit(true);
    44.           end;
    45.         end;
    46.       end;
    47.     end;
    48.   end;
    49. end;

Page 2 of 4 FirstFirst 1234 LastLast

Thread Information

Users Browsing this Thread

There are currently 2 users browsing this thread. (0 members and 2 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
  •