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.

[Client] onLoop() Skipped?

Featured Replies

Here is my onLoop(): 
public int onLoop() throws InterruptedException {		
        switch(this.state) {
            case HOP_WORLD:
        	hopWorld();
        	break;
            case SEARCH:
            	search();
                break;
            case FOUND:
            	logout();
                break;
        }
        return random(400,600);
}

Script always start out with SEARCH. Here is search():

private void search() throws InterruptedException {
	if(client.getMyPlayer().isVisible()) {
		log("PLAYER IS VISIBLE!");
                //Prints ITEM ON FLOOR AND WORLD
	} else {
		log("PLAYER IS NOT VISIBLE!");
	}
}

So here are the console outputs:

 

[iNFO ][06/12/13 01:52:15 PM]: Activating random : World Hopping

[iNFO ][06/12/13 01:52:18 PM]: Exited random : World Hopping
 
[iNFO ][06/12/13 01:52:19 PM]: Activating random : Login
[iNFO ][06/12/13 01:52:27 PM]: Exited random : Login
[iNFO ][06/12/13 01:52:55 PM]: PLAYER IS NOT VISIBLE!
[iNFO ][06/12/13 01:52:55 PM]: Activating random : WelcomeScreen
[iNFO ][06/12/13 01:52:56 PM]: PLAYER IS NOT VISIBLE!
[iNFO ][06/12/13 01:53:03 PM]: Exited random : WelcomeScreen
[iNFO ][06/12/13 01:53:03 PM]: PLAYER IS VISIBLE!
[iNFO ][06/12/13 01:53:05 PM]: [iTEMONFLOOR:NULL]
[iNFO ][06/12/13 01:53:05 PM]: 327
[iNFO ][06/12/13 01:53:07 PM]: Activating random : World Hopping
[iNFO ][06/12/13 01:53:11 PM]: Exited random : World Hopping
 
[iNFO ][06/12/13 01:53:11 PM]: Activating random : Login
[iNFO ][06/12/13 01:53:19 PM]: Exited random : Login
[iNFO ][06/12/13 01:53:47 PM]: 328
[iNFO ][06/12/13 01:53:47 PM]: Activating random : WelcomeScreen
[iNFO ][06/12/13 01:53:52 PM]: Exited random : WelcomeScreen
[iNFO ][06/12/13 01:53:53 PM]: Activating random : World Hopping
[iNFO ][06/12/13 01:53:57 PM]: Exited random : World Hopping
 
[iNFO ][06/12/13 01:53:57 PM]: Activating random : Login
[iNFO ][06/12/13 01:54:05 PM]: Exited random : Login
 

 

Second time it happened:

 

[iNFO ][06/12/13 02:02:39 PM]: Activating random : Login

[iNFO ][06/12/13 02:02:48 PM]: Exited random : Login
[iNFO ][06/12/13 02:03:13 PM]: PLAYER IS NOT VISIBLE!
[iNFO ][06/12/13 02:03:13 PM]: Activating random : WelcomeScreen
[iNFO ][06/12/13 02:03:17 PM]: Exited random : WelcomeScreen
[iNFO ][06/12/13 02:03:18 PM]: PLAYER IS VISIBLE!
[iNFO ][06/12/13 02:03:20 PM]: [iTEMONFLOOR:NULL]
[iNFO ][06/12/13 02:03:20 PM]: 344
[iNFO ][06/12/13 02:03:22 PM]: Activating random : World Hopping
[iNFO ][06/12/13 02:03:25 PM]: Exited random : World Hopping
 
[iNFO ][06/12/13 02:03:26 PM]: Activating random : Login
[iNFO ][06/12/13 02:03:33 PM]: Exited random : Login
[iNFO ][06/12/13 02:04:03 PM]: 345
[iNFO ][06/12/13 02:04:03 PM]: Activating random : WelcomeScreen
[iNFO ][06/12/13 02:04:07 PM]: Exited random : WelcomeScreen
[iNFO ][06/12/13 02:04:08 PM]: Activating random : World Hopping
[iNFO ][06/12/13 02:04:11 PM]: Exited random : World Hopping
 
[iNFO ][06/12/13 02:04:12 PM]: Activating random : Login
[iNFO ][06/12/13 02:04:20 PM]: Exited random : Login

 

My question, is why is the onLoop() skipped sometimes?

Edited by BotRS123

  • Author

Go to Private Chat

Will do. Be there in a few seconds.

 

EDIT: You are not around sad.png

I changed the code a bit, and it is still funky.

 

EDIT2: The script I wrote seems to still hop worlds, but in order to do that, it must print some crap, but it never does and it still hops. Not sure if it has to do with the log or if it is something else.

 

Edited by BotRS123

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.