Jump to content

mouseReleased not called for button 3 when human input enabled


dmmslaver

Recommended Posts

I made a thread about this in the bug report section, and it was DELETED, so I can only assume that must mean this in fact isnt a bug and I'm just bad. 

What happens is if you attach a mouse listener to the client:

 

Quote

bot.addMouseListener(new MouseAdapter() {



Then override mouse released:

 

Quote

            @Override
            public void mouseReleased(MouseEvent e) {
                log("Release " + e.getButton());
            }



With human input DISABLED the mouse listener works perfectly fine, EG it prints Release 3 when right click is released. 

However, with huma input ENABLED, mouse listener ONLY sends release events for mouse buttons one and two. I NEVER get a mouse released event for right click {mouse button 3} while human input is enabled. 

I came across this while writing a script to trace a manual users mouse. However, if the bot is actually not sending a mouse released command for button 3, and the client is seeing that, this could be the reason for almost all bans .. 

If it is sending the mouse released to the client, but not this mouse listener, then I am genuinely confused. 

Any help? Thanks!

Edited by dmmslaver
Link to comment
Share on other sites

16 minutes ago, Eagle Scripts said:

Please show us the code regarding these different logs/mouse events. 

It's in the OP. I'm literally just printing the button from a mouse event lol. Sec i will write a fully working script to display the bug

16 minutes ago, Token said:

Are those mouse events in your script generated by OSBot's ClickMouseEvent?

No, they are generated by the users mouse manually clicking. Not sure if this affects running scripts as well, that was the next thing to code.

Edited by dmmslaver
Link to comment
Share on other sites

12 minutes ago, Eagle Scripts said:

Please show us the code regarding these different logs/mouse events. 


Entire script

 


import java.awt.event.MouseAdapter;
import java.awt.event.MouseEvent;
import org.osbot.rs07.script.Script;
import org.osbot.rs07.script.ScriptManifest;

@ScriptManifest(name = "AATracer1.25", author = "Colby", version = 1.0, info = "", logo = "")
public class Bug extends Script {

    @Override
    public void onStart() {
        bot.addMouseListener(new MouseAdapter() {
            @Override
            public void mouseReleased(MouseEvent e) {
                log("Release " + e.getButton());
            }
        });
    }
    @Override
    public int onLoop() throws InterruptedException {
        return 20;
    }

    @Override
    public void onExit() throws InterruptedException {
    }
}



To replicate:
1. log in
2. run script, ensure human input is DISabled
3. left click, right click. Logger output:
 

Quote

[INFO][Bot #1][05/10 04:45:08 PM]: Release 1
[INFO][Bot #1][05/10 04:45:09 PM]: Release 3

4. ENable human input
5. Left click, right click. Logger output:
 

Quote

[INFO][Bot #1][05/10 04:45:13 PM]: Release 1



Problem: no mouseReleased sent for button 3 while human input enabled. Am i missing something?
 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...