Jump to content
Frequently Asked Questions
  • Are you not able to open the client? Try following our getting started guide
  • Still not working? Try downloading and running JarFix
  • Help! My bot doesn't do anything! Enable fresh start in client settings and restart the client
  • How to purchase with PayPal/OSRS/Crypto gold? You can purchase vouchers from other users
  • Walking to a Tile does not wait for completion


    DtohhM8

    Recommended Posts

    My walking method looks like this:

    public void walkToTile(Tile area) {
        getWalking().walk(area);
        sleepUntil(() -> !getLocalPlayer().isMoving() && !getLocalPlayer().isAnimating(), 60000 * 60); // 1 Hour time limit of travel
    }

    Inside of Rellekka, there is the Rock Crab area. The sleeping Rock Crabs do not wake up after a certain length of time of you being there unless you run out of the area and back in. When I try to use my method like so:

    walkToTile(new Tile(2659, 3677, 0)); // Walk out of area
    walkToTile(new Tile(2673, 3716, 0)); // Walk back into area

    It clicks to the first Tile, then clicks straight to the second one without waiting to arrive at the first Tile. I tried to change my method to:

    public void walkToTile(Tile area) {
        getWalking().walk(area);
        sleepUntil(() -> getLocalPlayer().getTile().equals(area), 60000 * 60); // 1 Hour time limit of travel
    }

    But this causes no click to be made to the Tile what so ever and the player to just stand still.

    How can I get my script to wait until the player has arrived at the Tile it is walking to?

    Link to comment
    Share on other sites

    Archived

    This topic is now archived and is closed to further replies.

    ×
    ×
    • Create New...

    Important Information

    We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.