Results 1 to 15 of 15

Thread: Auto-clicker Randomizer?

  1. #1
    Join Date
    Dec 2011
    Posts
    266
    Mentioned
    16 Post(s)
    Quoted
    185 Post(s)

    Default Auto-clicker Randomizer?

    Hey all. I've been training Herblore in RS3, and I've come up with an idea. Probably not a new or original idea, but an idea nonetheless.

    I've been getting by with Ghostmouse to train herb, but I'm sure it's only a matter of time before they drop the hammer on my obvious auto clicking. No matter how long of a session you record before clicking playback, each time the bot loops you're always going to be clicking that same series of pixels in the same exact order. I've been thinking wouldn't it be just grand if instead of telling the bot which pixel to click each instance, if I could give it a block of pixels to pick from each time it clicks. This would also negate the need for hour-long recording sessions to maximize the randomness.

    As I said before, I'm sure this isn't a new idea, but I'm not exactly script savvy. I barely know the difference between a bitmap and a minimap. I'm willing to learn and do all the work myself but I don't know where to begin, and the sea of information here (as complete as it is) is just too overwhelming for me to try and find the pieces I need. Especially since I'm sure this particular script would consist of about 30 lines.

    So if there's anyone willing to lend a helping hand to a noob, it would be greatly appreciated.

    It goes without saying that once I get a few good test runs in, I would post the shell for you guys to use.

    Thanks in advance!

    inb4l2scriptunewb

    tl;dr - i haz idea, too dumb make wurk.

  2. #2
    Join Date
    Jun 2012
    Posts
    4,867
    Mentioned
    74 Post(s)
    Quoted
    1663 Post(s)

    Default

    I think this task is more suited to Simba then Ghostmouse, even if you didn't want to use Simba's color capabilities.

    For example, you can use
    Simba Code:
    mouseBox(IntToBox(0, 0, 10, 10), MOUSE_LEFT, MOUSE_HUMAN);
    which will click in the box that you set with randomness weighted to the centre of the box.

    Here's an example of the sort of gaussian distribution that gaussbox will have:

  3. #3
    Join Date
    Dec 2011
    Posts
    266
    Mentioned
    16 Post(s)
    Quoted
    185 Post(s)

    Default

    Quote Originally Posted by BMWxi View Post
    I think this task is more suited to Simba then Ghostmouse, even if you didn't want to use Simba's color capabilities.

    For example, you can use
    Simba Code:
    mouseBox(IntToBox(0, 0, 10, 10), MOUSE_LEFT, MOUSE_HUMAN);
    which will click in the box that you set with randomness weighted to the centre of the box.

    Here's an example of the sort of gaussian distribution that gaussbox will have:
    I agree, Simba is better, but ghostmouse was a little more in my capability range as far as getting it to work lol. I've written a couple scripts using Simba before for non-RS related computer stuff, but only "click "here", wait X ms, scroll "here", click "here".

    What you posted is exactly what I had in mind actually. Without asking you to write the whole script for me, what would just one instance in this script look like? I have no idea how to implement what you posted, and also mimic mouse movement. If I only used what you posted, wouldn't that just make it jump from location to location instantly?
    Last edited by Gunner; 11-29-2013 at 09:25 PM.

  4. #4
    Join Date
    Jun 2012
    Posts
    4,867
    Mentioned
    74 Post(s)
    Quoted
    1663 Post(s)

    Default

    Quote Originally Posted by Gunner View Post
    I agree, Simba is better, but ghostmouse was a little more in my capability range as far as getting it to work lol. I've written a couple scripts using Simba before for non-RS related computer stuff, but only "click "here", wait X ms, scroll "here", click "here".

    What you posted is exactly what I had in mind actually. Without asking you to write the whole script for me, what would just one instance in this script look like? I have no idea how to implement what you posted, and also mimic mouse movement. If I only used what you posted, wouldn't that just make it jump from location to location instantly?
    MouseBox uses simba's mouse movement, so if you wanted it to humanlikely move to and left click in a box you would just use the mousebox function.

    See the image here:


    if you used the coordinates shown in the image with mousebox like this:
    Simba Code:
    mouseBox(IntToBox(592, 334, 620, 335), MOUSE_LEFT, MOUSE_HUMAN);
    then simba will move the mouse to somewhere in that highlighted green area and left click.

  5. #5
    Join Date
    Dec 2011
    Posts
    266
    Mentioned
    16 Post(s)
    Quoted
    185 Post(s)

    Default

    Quote Originally Posted by BMWxi View Post
    MouseBox uses simba's mouse movement, so if you wanted it to humanlikely move to and left click in a box you would just use the mousebox function.

    See the image here:

    if you used the coordinates shown in the image with mousebox like this:
    Simba Code:
    mouseBox(IntToBox(592, 334, 620, 335), MOUSE_LEFT, MOUSE_HUMAN);
    then simba will move the mouse to somewhere in that highlighted green area and left click.
    Oh awesome. This will be a shorter script than I thought lol. I'm also going to try to add a "verify" protocol. Like when it opens the bank it first checks to see that "herb x" and "vial" are actually there, but that will be a secondary function.

    I'm gonna get to work on setting this up. I may have another question or ten, but I think you pretty much answered everything I needed. If I get this ironed out to the point of actually posting the shell, I'll be sure to give you the credit. Thanks a lot for your help!

  6. #6
    Join Date
    Jun 2012
    Posts
    4,867
    Mentioned
    74 Post(s)
    Quoted
    1663 Post(s)

    Default

    Quote Originally Posted by Gunner View Post
    Oh awesome. This will be a shorter script than I thought lol. I'm also going to try to add a "verify" protocol. Like when it opens the bank it first checks to see that "herb x" and "vial" are actually there, but that will be a secondary function.

    I'm gonna get to work on setting this up. I may have another question or ten, but I think you pretty much answered everything I needed. If I get this ironed out to the point of actually posting the shell, I'll be sure to give you the credit. Thanks a lot for your help!
    No problem! If you want to check on the mouseover text of something before clicking on it you can use
    Simba Code:
    mouseBox(IntToBox(592, 334, 620, 335), MOUSE_MOVE, MOUSE_HUMAN); //Moves the mouse to the designated area
    if isMouseOverText(['vial'], 300) then                           //Checks for uptext
      fastclick(MOUSE_LEFT);                                         //Clicks using the left mouse button if the uptext is correct

  7. #7
    Join Date
    Dec 2011
    Posts
    266
    Mentioned
    16 Post(s)
    Quoted
    185 Post(s)

    Default

    Quote Originally Posted by BMWxi View Post
    No problem! If you want to check on the mouseover text of something before clicking on it you can use
    Simba Code:
    mouseBox(IntToBox(592, 334, 620, 335), MOUSE_MOVE, MOUSE_HUMAN); //Moves the mouse to the designated area
    if isMouseOverText(['vial'], 300) then                           //Checks for uptext
      fastclick(MOUSE_LEFT);                                         //Clicks using the left mouse button if the uptext is correct
    Kickass man. That'll be a big help.

    One problem though, When I click compile, it's compiling ok with no errors, but it's not actually taking control of my mouse and moving to the specified coordinates? What would be the procedure for the mousebox code you listed above?
    Last edited by Gunner; 11-30-2013 at 12:51 AM.

  8. #8
    Join Date
    Jun 2012
    Posts
    4,867
    Mentioned
    74 Post(s)
    Quoted
    1663 Post(s)

    Default

    Quote Originally Posted by Gunner View Post
    Kickass man. That'll be a big help.

    One problem though, When I click compile, it's compiling ok with no errors, but it's not actually taking control of my mouse and moving to the specified coordinates? What would be the procedure for the mousebox code you listed above?
    I'd recommend using SMART, as that allows you to keep control of your mouse. Also I haven't tested anything not using SMART so I can't guarantee things to work otherwise.

    To use SMART (and srl6), put this at the top of your script (right below where it says program)
    Simba Code:
    {$DEFINE SMART}
    {$i srl-6/srl.simba}

    Also make sure you have SMART 8.3, but I think it comes with simba now.

  9. #9
    Join Date
    Dec 2011
    Posts
    266
    Mentioned
    16 Post(s)
    Quoted
    185 Post(s)

    Default

    Quote Originally Posted by BMWxi View Post
    I'd recommend using SMART, as that allows you to keep control of your mouse. Also I haven't tested anything not using SMART so I can't guarantee things to work otherwise.

    To use SMART (and srl6), put this at the top of your script (right below where it says program)
    Simba Code:
    {$DEFINE SMART}
    {$i srl-6/srl.simba}

    Also make sure you have SMART 8.3, but I think it comes with simba now.
    I'm not to the point yet of writing a SMART script, for now I would just be happy if the script would take over control of my mouse and move it where I ask it too. Sadly though, I may have been putting a little too much faith in my ability to pick it back up, not to mention my patience, and I've lost all the old scripts I had written so I don't even have anything to go on as a template. I've been going at this for about 5hrs now and I haven't even managed to make the mouse move. I do have one less drinking glass to wash tomorrow.

    Thanks for your help anyway.

  10. #10
    Join Date
    Jun 2012
    Posts
    4,867
    Mentioned
    74 Post(s)
    Quoted
    1663 Post(s)

    Default

    Quote Originally Posted by Gunner View Post
    I'm not to the point yet of writing a SMART script, for now I would just be happy if the script would take over control of my mouse and move it where I ask it too. Sadly though, I may have been putting a little too much faith in my ability to pick it back up, not to mention my patience, and I've lost all the old scripts I had written so I don't even have anything to go on as a template. I've been going at this for about 5hrs now and I haven't even managed to make the mouse move. I do have one less drinking glass to wash tomorrow.

    Thanks for your help anyway.
    putting the line I gave you is all you have to put in the script to use SMART, everything else is the same.

  11. #11
    Join Date
    Dec 2011
    Posts
    266
    Mentioned
    16 Post(s)
    Quoted
    185 Post(s)

    Default

    Quote Originally Posted by BMWxi View Post
    putting the line I gave you is all you have to put in the script to use SMART, everything else is the same.
    Well son of a...I just assumed that using the DEFINE SMART would try to launch the client and I knew I didn't have enough coded to launch the client properly. Wow. Can't imagine how hard the lurkers must be laughing.

    Sorry I made you hang around this silly thread for 5hrs, your single line of code in the very beginning gave me all I needed, if only I had been smart enough to implement it. Your If/Then code will prove a nice bonus as well.

    I really appreciate your help.

  12. #12
    Join Date
    Jun 2012
    Posts
    4,867
    Mentioned
    74 Post(s)
    Quoted
    1663 Post(s)

    Default

    Quote Originally Posted by Gunner View Post
    Well son of a...I just assumed that using the DEFINE SMART would try to launch the client and I knew I didn't have enough coded to launch the client properly. Wow. Can't imagine how hard the lurkers must be laughing.

    Sorry I made you hang around this silly thread for 5hrs, your single line of code in the very beginning gave me all I needed, if only I had been smart enough to implement it. Your If/Then code will prove a nice bonus as well.

    I really appreciate your help.
    Not a problem, I'd be on anyway so it's nothing extra really

    Good luck on the script!

  13. #13
    Join Date
    Dec 2011
    Posts
    266
    Mentioned
    16 Post(s)
    Quoted
    185 Post(s)

    Default

    Quote Originally Posted by BMWxi View Post
    Not a problem, I'd be on anyway so it's nothing extra really

    Good luck on the script!
    Now that you mention it...lol. Is there a function to move the mouse down in the same way? With the same gaussian distribution as before? I can get it to right click on the banker, but I'm not sure how to move the mouse down to the Bank Banker option. I can't just use color, and I can't give it a coordinate because the coordinates of Bank Banker would be different in every instance. This will be needed for the Withdraw option as well.

    Thanks in advance.

  14. #14
    Join Date
    Jun 2012
    Posts
    4,867
    Mentioned
    74 Post(s)
    Quoted
    1663 Post(s)

    Default

    Quote Originally Posted by Gunner View Post
    Now that you mention it...lol. Is there a function to move the mouse down in the same way? With the same gaussian distribution as before? I can get it to right click on the banker, but I'm not sure how to move the mouse down to the Bank Banker option. I can't just use color, and I can't give it a coordinate because the coordinates of Bank Banker would be different in every instance. This will be needed for the Withdraw option as well.

    Thanks in advance.
    Simba Code:
    chooseOption.select(['ank']);
    should work

  15. #15
    Join Date
    Dec 2011
    Posts
    266
    Mentioned
    16 Post(s)
    Quoted
    185 Post(s)

    Default

    Quote Originally Posted by BMWxi View Post
    Simba Code:
    chooseOption.select(['ank']);
    should work
    Works great. I now have a simple script that will never stop unless the withdraw options are wrong. As time goes on I'll see about adding support where it actually waits for the bank to open instead of just wait(650); and looks for Done instead of wait(17000); but for now it's exactly what I wanted it to be in my first post.

    Thanks for all your help.

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
  •