Jump to content

Wilderness ditch


rjames94

Recommended Posts

I'm making a script for new accounts that requires walking into the wilderness. I'm using webwalk to get to that location, however the wilderness ditch warning stops it. I have code to click Enter wilderness but will not run because web walk hasn't reached the destination. Is there a more optimal solution than making two Areas and web walking to ditch and then web walking to wilderness location? Anything to interrupt the one webwalk method? or something similar

Link to comment
Share on other sites

47 minutes ago, rjames94 said:

I'm making a script for new accounts that requires walking into the wilderness. I'm using webwalk to get to that location, however the wilderness ditch warning stops it. I have code to click Enter wilderness but will not run because web walk hasn't reached the destination. Is there a more optimal solution than making two Areas and web walking to ditch and then web walking to wilderness location? Anything to interrupt the one webwalk method? or something similar

WebWalkEvent and set break condition
https://osbot.org/api/org/osbot/rs07/event/WebWalkEvent.html

  • Like 1
Link to comment
Share on other sites

1 hour ago, Gunman said:

So I have it working, but there's quite a big delay before clicking. I found some other threads on this about setting the event mode to async, I did that but the mouse moves rapidly and double clicks and not very reliable. Here's the code I have so far.

if (state == 1 && !isMyWidgetWorking()) {
            WebWalkEvent webWalkEvent = new WebWalkEvent(obeliskArea);
            webWalkEvent.setBreakCondition(new Condition() {
                @Override
                public boolean evaluate() {
                    return isMyWidgetWorking();
                }
            });
            execute(webWalkEvent);

        } else {
                getMyWidget().interact();
            }

https://imgur.com/afyCFDL

Link to comment
Share on other sites

21 minutes ago, rjames94 said:

So I have it working, but there's quite a big delay before clicking. I found some other threads on this about setting the event mode to async, I did that but the mouse moves rapidly and double clicks and not very reliable. Here's the code I have so far.

if (state == 1 && !isMyWidgetWorking()) {
            WebWalkEvent webWalkEvent = new WebWalkEvent(obeliskArea);
            webWalkEvent.setBreakCondition(new Condition() {
                @Override
                public boolean evaluate() {
                    return isMyWidgetWorking();
                }
            });
            execute(webWalkEvent);

        } else {
                getMyWidget().interact();
            }

https://imgur.com/afyCFDL

https://osbot.org/api/org/osbot/rs07/event/WebWalkEvent.html#setHighBreakPriority-boolean-

  • Like 1
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...