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.

Weird fishing bug?

Featured Replies

Hey guys, so I've been trying to make a fishing bot recently and I keep getting a weird bug.
Usually when you fish using a small fishing net, the player casts the fishing net and doesn't stop fishing until the inventory is full or until there is no more fish.

But my bot instead casts the fishing net, fishes for 10 seconds and then the animation stops.
Does anyone have any idea why my player animation stops after 10 seconds?

No, my bot doesn't click on the fishing spot after 10 seconds, the conditional sleep makes it so the bot waits for the animation to stop, or clicks on the fishing spot every 4 minutes.

here is my code:
image.png.373c0338abfeb68f711aee6808b2dbcc.png

Thanks in advance!

Animations reset after a couple seconds so the !isAnimating() will return true and stop the conditionalsleep. Do getInteracting() != null instead of isAnimating and fish exists, should work better. Will trigger sometimes on dialogue (level-up) so be sure to check getDialogues().inDialogue() too

  • Didn't nullcheck fishing spot
  • You can check !myPlayer().isAnimating() before fishing
  • Don't need to have the condition on the else if statement because you already check it with the first condition.
  • conditional sleeps that last 250_000 is generally bad practice. I'd do 10-20 seconds max.
  • To clean up your sleep you can check out the ConditionalSleep2 class https://osbot.org/api/org/osbot/rs07/utility/ConditionalSleep2.html

Edited by Malcolm

  • Author
4 hours ago, Malcolm said:
  • Didn't nullcheck fishing spot
  • You can check !myPlayer().isAnimating() before fishing
  • Don't need to have the condition on the else if statement because you already check it with the first condition.
  • conditional sleeps that last 250_000 is generally bad practice. I'd do 10-20 seconds max.
  • To clean up your sleep you can check out the ConditionalSleep2 class https://osbot.org/api/org/osbot/rs07/utility/ConditionalSleep2.html

 

5 hours ago, Czar said:

Animations reset after a couple seconds so the !isAnimating() will return true and stop the conditionalsleep. Do getInteracting() != null instead of isAnimating and fish exists, should work better. Will trigger sometimes on dialogue (level-up) so be sure to check getDialogues().inDialogue() too

Thank you fellas

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.