Jump to content

World Hop Not Working?


Recommended Posts

Posted

I have created a small test script to see how world hop function works. I have created the below script however when it is logged into world 308 and needs to swap to 316 it just picks random worlds, i.e. 504. Any advice?

 

@Override
public int onLoop() throws InterruptedException {

    if (worlds.getCurrentWorld() == 308){ //F2p world
        // complete action
        // after action is complete then world hop to the next world in the line
        worlds.hop(316); //F2p world
    } else {
        if (worlds.getCurrentWorld() == 316) { //F2p world
            // complete action 
            // after action is complete then world hop to the next world in the line
            worlds.hop(326); //F2p world

        }
    }




    return 0;
}
Posted (edited)

Given that apparently refreshing the scripts fixed your problem I'd still like to add a suggestion, you aren't sleeping or checking on the worlds.hop() method in any way. Although what you did can and does for the most part work fine assuming no lag it still can be problematic and be something you need to check on. 

Edited by luciuspragg

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...