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.

The hopToF2PWorld() method attempts to connect to a P2P world

Featured Replies

Calling the following method sometimes causes the client to attempt to switch to a P2P world, is this a bug or am I switching worlds incorrectly?

getMap().worlds.hopToF2PWorld();

 

You can do getWorlds().hopToF2PWorld();
What world is it trying to hop to ?

  • Author
59 minutes ago, FuryShark said:

You can do getWorlds().hopToF2PWorld();
What world is it trying to hop to ?

Isn't that a different way to access the same method?

I will need to monitor the members world(s) it is trying to hop to as it only happens occasionally. I was just wondering if I was doing something wrong before investigating.

This is because of twisted league world that's why. Make a custom world hopper if you want to solve this

  • Author
27 minutes ago, Malcolm said:

I have reported this to Patrick already. He is aware of it.

Yes it tries to hop to Twisted League worlds. 

Yeah, you and @Kramnik are correct, it's because of Twisted League worlds! Thanks for confirming

You could make a list of worlds yourself.

 

Here is a snippet of what you could do (Nothing in here has to be static).

public static ArrayList<Integer> worlds = new ArrayList<Integer>();
public static ArrayList<Integer> blockedWorlds = new ArrayList<Integer>();
  
@Override
	public void onStart() throws InterruptedException {
  
  		blockWorlds();
  
		getWorlds().getAvailableWorlds(false).forEach(w -> {
			if (!w.isMembers() && !w.isPvpWorld() && !blockedWorlds.contains(w.getId()) && getWorlds().isWorldAllowedForHop(w)) {
				worlds.add(w.getId());
			}
		});
		log(worlds.size() + " worlds added to hop list.");
	}
  
  //To block worlds you just add to the array of integers called b
  static int[] b = {318, 400, 402, 403, 404, 405, 406, 407, 408, 409, 410, 411, 412, 443, 462, 463, 512, 535, 536};
	public static void blockWorlds() {
		for (int i : b) {
			blockedWorlds.add(i);
		}
	}

Then you could make a custom method to get a random world etc.

Not quite sure which worlds are blocked here, but it blocks league worlds (So they won't be added to worlds arraylist)

Edited by Medusa

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.