Jump to content

How to blur/unfocus client


Recommended Posts

I have this snippet of code that will move the mouse offscreen. It works fine. See the code below:

private void antiBanMoveMouseOffscreen() {
    int myMouseOffscreenAverage = random(learningData.MOUSE_OFFSCREEN_START, learningData.MOUSE_OFFSCREEN_END);

    paint.state("[Anti-Ban] Moving mouse offscreen for " + myMouseOffscreenAverage + "ms to simulate AFK...");

    Sleep.sleepUntil(() -> false, myMouseOffscreenAverage);

    paint.state("[Anti-Ban] Complete!");

I want to unfocus the OSBuddy client after I do this. I see a method to check if the client is focused:


But I don't see an equivalent "getClient().setFocus()".

Anyone know how to do this in OSBot?


Edited by Lansana Camara
  • Like 1
Link to comment
Share on other sites

  • 2 years later...

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.

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...