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.

Oak & Bank

Featured Replies

Oak Woodcutter

- Cuts Oak's till full inventory and banks at Draynor Bank

- Will run away if attacked (Un-tested but should work)

- Informative paint 

 

To start script

- Have "Fixed mode" selected 

- Have zoom set to far left

- Axe in inventory OR wielding axe

- Start near Draynor (although not necessary as WebWalker should get you there)

- Enter Bank PIN prior to running so bot can Bank log's

 

Download

OaknBank

 

Source

Spoiler

import org.osbot.rs07.api.map.Area;
import org.osbot.rs07.api.map.constants.Banks;
import org.osbot.rs07.api.model.RS2Object;
import org.osbot.rs07.script.Script;
import org.osbot.rs07.script.ScriptManifest;
import org.osbot.rs07.utility.ConditionalSleep;


@ScriptManifest(author = "Imthabawse", info = "Chops and Banks Oak Logs", logo = "", name = "OaknBank", version = 1)

public class OaknBank extends Script {


    private Area oakArea = new Area(3085, 3305, 3077, 3291);



    @Override
    public int onLoop() throws InterruptedException {
        if(canCut()) {
            chopOaks();
        }else{
            bankLogs();
            underAttack();
        }
        return(random(500,550));
    }



    private void chopOaks() throws InterruptedException {
        RS2Object oakTree = getObjects().closest(oakArea, "Oak");

        if (readyToCut() && oakTree != null && oakTree.interact("Chop down")) {
                log("Chopping Oak!");
                sleep(random(750, 800));
                getMouse().moveOutsideScreen();
                new ConditionalSleep(5500) {
                    @Override
                    public boolean condition() {
                        return myPlayer().isAnimating();
                    }
                }.sleep();
            } else if (!oakArea.contains(myPlayer())) {
                log("Walking back to Oaks!");
                getWalking().webWalk(oakArea);
            }
        }



    private void bankLogs() throws InterruptedException {
        if(getInventory().isFull() && !myPlayer().isAnimating() && !Banks.DRAYNOR.contains(myPlayer())) {
            log("Walking to Bank!");
            getWalking().webWalk(Banks.DRAYNOR);
            new ConditionalSleep(2500) {
                @Override
                public boolean condition() {
                    return Banks.DRAYNOR.contains(myPlayer());
                }
            }.sleep();
        }else if(Banks.DRAYNOR.contains(myPlayer()) && getInventory().isFull() && !myPlayer().isUnderAttack() && !getBank().isOpen()) {
            log("Banking Logs!");
            getBank().open();
        }else if(getInventory().contains("Oak logs")) {
            getBank().depositAll("Oak logs");
        }else if(!getInventory().contains("Oak logs")) {
            getBank().close();
        }
    }


    private void underAttack() {
        if(myPlayer().isUnderAttack()) {
            log("Under attack! Running!");
            getWalking().webWalk(oakArea);
        }
    }


    private boolean canCut() {
        return !getInventory().isFull() && !getBank().isOpen();
    }
    private boolean readyToCut() {
        return !myPlayer().isAnimating() && !myPlayer().isUnderAttack() && oakArea.contains(myPlayer());
    }

}

 

Edited by Imthabawse
Fixed sloppy code

  • Author

Script will no longer STOP at 30 Woodcutting. Cleaned up code for more efficient reactions. Download updated :)

  • Author

Ran this for bout 6 hours straight last night 2k+ oak logs obtained and lvl 49 wc will see if I get the ban hammer or not.

Would be awesome if u combined both scripts. Leveled from 1-20(or 15) then swapped to oaks and suicides

  • Author
On 5/7/2019 at 12:35 PM, tmanowen said:

Would be awesome if u combined both scripts. Leveled from 1-20(or 15) then swapped to oaks and suicides

I can make this happen for sure.

Also no ban after running the 6 hours straight 🙂

Edit to above: Did receive perm ban couple days after suiciding account which was what I expected out of a test account (Fresh level 3 straight off tut island).

Edited by Imthabawse

  • Author

Should have time to update this tonight and make script cut tree's to lvl 15 then switch to oak's.

  • 1 year later...
  • 3 weeks later...

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.