Jump to content

Script launches but does nothing [SOLVED]


Recommended Posts

Posted (edited)
import org.osbot.rs07.api.map.constants.Banks;
import org.osbot.rs07.script.Script;
import org.osbot.rs07.script.ScriptManifest;
import org.osbot.rs07.utility.ConditionalSleep;
import java.util.function.BooleanSupplier;
import java.awt.*;


@ScriptManifest(name = "Muler", author = "Nor3g", info = "Trynna holla at the m00le", version = 0.1, logo = "")
public final class Muler extends Script {

    @Override
    public final int onLoop() throws InterruptedException {
        bank();
        return random(150, 200);
    }

    private void bank() throws InterruptedException {
        if (!Banks.VARROCK_WEST.contains(myPosition())) {
            getWalking().webWalk(Banks.VARROCK_WEST);
            log("Walking to V WB");
        } else if (!getBank().isOpen()) {
            log("Opening bank");
            getBank().open();
        } else if (!getInventory().isEmptyExcept("Raw swordfish")) {
            getBank().depositAll();
        } else if (getBank().contains("Raw swordfish")) {
            getBank().withdrawAll("Raw swordfish");
        } else {
            stop(true);
        }
    }
}

 

I'm trying to make a script that walks to Varrock West Bank, but when I run it, starting in lumbridge, it doesn't do anything. Can someone explain what is wrong?

The log doesn't tell me anything other than that the script started.

Thanks

Edited by Nor3g

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