Jump to content
View in the app

A better way to browse. Learn more.

OSBot :: 2007 OSRS Botting

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Webwalking error

Featured Replies

inventory.interact("Break", 8007);
getWalking().webWalk(Banks.VARROCK_EAST);

After the tab is clicked I get the following error in log:

WebWalkingEvent; Terminated! Exceeded attempt threshold.

How can I prevent this?

6 minutes ago, harrypotter said:

inventory.interact("Break", 8007);
getWalking().webWalk(Banks.VARROCK_EAST);

After the tab is clicked I get the following error in log:


WebWalkingEvent; Terminated! Exceeded attempt threshold.

How can I prevent this?

 

Perhaps you should try sleeping until the teleport has completed, for example sleeping until your player is in the destination area

24 minutes ago, Muffins said:

If im not mistaken doesn't webwalk already use the fastest method (i.e. teletabs etc) provided you have the materials in your inventory?

Yes but, you need to setup walking event and set teleports to true

  • Author
private Area varrockSquare = new Area(3205, 3436, 3221, 3421);
if (inventory.interact("Break", 8007)) {
    new util.Sleep(() -> !varrockSquare.contains(myPosition()), Script.random(1500, 2500)).sleep();
}
getWalking().webWalk(Banks.VARROCK_EAST);

Still gives me the same error, can someone confirm that is correct?

* Using @Explv Sleep class found here: https://osbot.org/forum/topic/115124-explvs-scripting-101/

Edited by harrypotter

13 minutes ago, harrypotter said:

private Area varrockSquare = new Area(3205, 3436, 3221, 3421);
if (inventory.interact("Break", 8007)) {
    new util.Sleep(() -> !varrockSquare.contains(myPosition()), Script.random(1500, 2500)).sleep();
}
getWalking().webWalk(Banks.VARROCK_EAST);

Still gives me the same error, can someone confirm that is correct?

* Using @Explv Sleep class found here: https://osbot.org/forum/topic/115124-explvs-scripting-101/

Don't you want to sleep until you are in Varrock square? I assume you are using a Varrock teleport. Currently you are sleeping until your player is not in Varrock square, which would mean it wouldn't sleep at all.

  • Author
1 minute ago, Explv said:

Don't you want to sleep until you are in Varrock square? I assume you are using a Varrock teleport. Currently you are sleeping until your player is not in Varrock square, which would mean it wouldn't sleep at all.

Yes you would be correct :facep:

I'll correct that and test, thanks again!

  • Author
6 minutes ago, Explv said:

Don't you want to sleep until you are in Varrock square? I assume you are using a Varrock teleport. Currently you are sleeping until your player is not in Varrock square, which would mean it wouldn't sleep at all.

new util.Sleep(() -> varrockSquare.contains(myPosition()), Script.random(1500, 2500)).sleep();

This gives me the same error as well :(

1 hour ago, harrypotter said:

new util.Sleep(() -> varrockSquare.contains(myPosition()), Script.random(1500, 2500)).sleep();

This gives me the same error as well :(

Change the sleep timeout to something longer, such as 10000 ms. There isn't much point using a random timeout like you are doing, and 1.5 seconds probably isn't long enough for the teleport to complete.

You should also not just call web walk straight after the teleport. The "Break" interaction could fail, and then your bot will attempt to web walk from wherever your player is standing.

What you should do is something like

If player is in location where you are teleporting from:

Teleport

Else:

Web walk to the bank

 

Alternatively, like other users have suggested you could create a WebWalkEvent which should handle the teleporting for you. Something like:

WebWalkEvent webWalkEvent = new WebWalkEvent(Banks.VARROCK_EAST);

PathPreferenceProfile profile = new PathPreferenceProfile();

profile.checkInventoryForItems(true);

profile.setAllowTeleports(true);

webWalkEvent.setPathPreferenceProfile(profile);

execute(webWalkEvent);

 

Apologies for any syntax errors and the formatting, I'm on my phone

Edited by Explv

  • Author
13 minutes ago, Explv said:

Change the sleep timeout to something longer, such as 10000 ms. There isn't much point using a random timeout like you are doing, and 1.5 seconds probably isn't long enough for the teleport to complete.

You should also not just call web walk straight after the teleport. The "Break" interaction could fail, and then your bot will attempt to web walk from wherever your player is standing.

What you should do is something like

If player is in location where you are teleporting from:

Teleport

Else:

Web walk to the bank

Thanks for your help!

I changed to the following which has resolved the issue:

private Area varrockSquare = new Area(3205, 3436, 3221, 3421);
private Area sawmill = new Area(3296, 3495, 3308, 3484);
if (sawmill.contains(myPosition())) {
    if (inventory.interact("Break", 8007)) {
        new util.Sleep(() -> varrockSquare.contains(myPosition()), 10000).sleep();
    }
} else {
    getWalking().webWalk(Banks.VARROCK_EAST);
}

 

Create an account or sign in to comment

Recently Browsing 0

  • No registered users viewing this page.

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.