Jump to content

World Hopping isn't working (Updates)


PlumpRump

Recommended Posts

I was testing a new script and I found world hopping isn't working anymore. The bot opens the world hopping interface where the list of worlds is and then just does nothing. I just tested this on an older script that I know worked and there was the same issue. I don't know when this problem started because I haven't tested a script with world hop in a couple days. I think this is a client bug, but I can't be sure. Has anyone else had this issue?

Edited by PlumpRump
Link to comment
Share on other sites

I created a bare bones script to isolate this issue

package script;

import org.osbot.rs07.script.Script;
import org.osbot.rs07.script.ScriptManifest;
import util.Sleep;

import java.util.Arrays;

@ScriptManifest(author = "PlumpRump", name = "HopTest", info = "", version = 0.1, logo = "")
public class HopTest extends Script {

    private static final Integer[] F2P_WORLDS = new Integer[]{301, 308, 316, 326, 335, 379, 380,
            382, 383, 384, 393, 394, 397, 398, 399, 417, 418, 425, 426, 430, 431,
            433, 434, 435, 436, 437, 438, 439, 440, 451, 452, 453, 454, 455, 456,
            457, 458, 459, 469, 470, 471, 472, 473, 474, 475, 476, 477, 497, 498,
            499, 500, 501, 502, 503, 504};

    @Override
    public int onLoop() throws InterruptedException {
        int worldToHop = nextF2pWorld();
        log("HopWorld: Attempting to hop to world " + worldToHop);
        getWorlds().hop(worldToHop);
        new Sleep(() -> getWorlds().getCurrentWorld() == worldToHop
                && myPlayer().isVisible(), 5000).sleep();
        if (getWorlds().getCurrentWorld() == worldToHop) {
            log("HopTest: Successfully hopped to world " + worldToHop);
        } else {
            log("HopTest ERROR: Unable to hop to world " + worldToHop);
        }

        return 1000;
    }

    private int nextF2pWorld() {
        int currentWorldIndex = Arrays.binarySearch(F2P_WORLDS, getWorlds().getCurrentWorld());
        int nextIndex = (currentWorldIndex + 1) % F2P_WORLDS.length;
        return F2P_WORLDS[nextIndex];
    }
}

This produces output

Quote

[INFO][Bot #1][04/09 07:02:40 AM]: Loaded 3 built-in random solvers!
[INFO][Bot #1][04/09 07:02:40 AM]: Started script : HopTest
[INFO][Bot #1][04/09 07:02:40 AM]: HopWorld: Attempting to hop to world 475
[INFO][Bot #1][04/09 07:02:42 AM]: Terminating script HopTest...
[INFO][Bot #1][04/09 07:02:42 AM]: HopTest ERROR: Unable to hop to world 475
[INFO][Bot #1][04/09 07:02:42 AM]: Script HopTest has exited!
[INFO][Bot #1][04/09 07:02:47 AM]: Loaded 3 built-in random solvers!
[INFO][Bot #1][04/09 07:02:50 AM]: Started random solver : Auto Login
[INFO][Bot #1][04/09 07:02:56 AM]: Successfully logged in, waiting for welcome screen.
[INFO][Bot #1][04/09 07:02:56 AM]: Random solver exited : Auto Login
[INFO][Bot #1][04/09 07:03:00 AM]: Started random solver : Welcome Screen
[INFO][Bot #1][04/09 07:03:03 AM]: Random solver exited : Welcome Screen
[INFO][Bot #1][04/09 07:03:04 AM]: Started script : HopTest
[INFO][Bot #1][04/09 07:03:04 AM]: HopWorld: Attempting to hop to world 475
[INFO][Bot #1][04/09 07:03:11 AM]: HopTest ERROR: Unable to hop to world 475
[INFO][Bot #1][04/09 07:03:12 AM]: HopWorld: Attempting to hop to world 475
[INFO][Bot #1][04/09 07:03:17 AM]: HopTest ERROR: Unable to hop to world 475
[INFO][Bot #1][04/09 07:03:18 AM]: HopWorld: Attempting to hop to world 475
[INFO][Bot #1][04/09 07:03:23 AM]: HopTest ERROR: Unable to hop to world 475
[INFO][Bot #1][04/09 07:03:24 AM]: HopWorld: Attempting to hop to world 475
[INFO][Bot #1][04/09 07:03:29 AM]: HopTest ERROR: Unable to hop to world 475
[INFO][Bot #1][04/09 07:03:30 AM]: HopWorld: Attempting to hop to world 475
[INFO][Bot #1][04/09 07:03:35 AM]: HopTest ERROR: Unable to hop to world 475
[INFO][Bot #1][04/09 07:03:36 AM]: HopWorld: Attempting to hop to world 475
[INFO][Bot #1][04/09 07:03:41 AM]: HopTest ERROR: Unable to hop to world 475
[INFO][Bot #1][04/09 07:03:42 AM]: HopWorld: Attempting to hop to world 475
[INFO][Bot #1][04/09 07:03:47 AM]: HopTest ERROR: Unable to hop to world 475
[INFO][Bot #1][04/09 07:03:48 AM]: HopWorld: Attempting to hop to world 475
[INFO][Bot #1][04/09 07:03:49 AM]: Terminating script HopTest...
[INFO][Bot #1][04/09 07:03:49 AM]: HopTest ERROR: Unable to hop to world 475
[INFO][Bot #1][04/09 07:03:49 AM]: Script HopTest has exited!
 

Please, can anyone help? This is really a show stopper for me...

Link to comment
Share on other sites

3 minutes ago, Thiccboi said:

Why not just use worlds.hopToF2PWorld() then return if hopped world?

For certain scripts you need to hop to a specific world. I guess this would be a workaround if you didn't need to do that.

 

I just noticed this same issue when I got home from work today, hopefully its something the developers can resolve in good time.  @Patrick :) 

edit:

From my brief testing, it doesn't look like the problem specifically affects certain worlds, seems to be broken across the board.

Edited by rawtech
Added testing notes.
Link to comment
Share on other sites

I just tried my exact same HopTest script I wrote earlier and it works this time. This morning when I experienced the problem, I restarted the client numerous times and even ran it on two different operating systems. I wonder if it's due to some weird widget ID shenanigans in the OSRS client. I can't think of anything else that's changed

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...