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

scripting_meme.jpg

Featured Replies

mouse.move(random(132.35, ), random(210.0112, ));
2 hours ago, Apaec said:

aren't all scripts state based?

Technically yes, if they ude the task/node framework. Some frameworks are Event based with break conditions and other crap.

boolean shouldExecute() {
return getObjects.getAll().get("ABC") != null
}

void execute() {
return getObjects.getAll().get("ABC").interact();
}

24 minutes ago, Alek said:

boolean shouldExecute() {
return getObjects.getAll().get("ABC") != null
}

void execute() {
return getObjects.getAll().get("ABC").interact();
}

Syntax error on line 2, missing ;

Just now, Vilius said:

Syntax error on line 2, missing ;

it makes the task node system faster, less characters to compute.

Just now, Alek said:

it makes the task node system faster, less characters to compute.

No need to compile when you are missing parameters on line 6 cause eitherway you wouldnt do an action

rollsafe.gif

14 minutes ago, Vilius said:

Syntax error on line 2, missing ;

Not even commenting on the fact that he's using a List like a Map :xboge:

public enum Task {

	OPEN_BANK("Open bankies") {

		@Override
		public boolean validate(Bot bot) {
			return !bot.bank.isOpen();
		}

		@Override
		public int execute(Bot bot) throws InterruptedException {
		
			if (bot.bank.open()) {
				bot.logger.debug("*YAY*");
			}
		
			return 250;
		}
		
	}
	
	;

	private final String name;

	private Task(String name) {
		this.name = name;
	}

	public abstract boolean validate(Bot bot);
	public abstract int execute(Bot bot) throws InterruptedException;

	@Override
	public String toString() {
		return name;
	}
}

 

1 hour ago, liverare said:

public enum Task {

	OPEN_BANK("Open bankies") {

		@Override
		public boolean validate(Bot bot) {
			return !bot.bank.isOpen();
		}

		@Override
		public int execute(Bot bot) throws InterruptedException {
		
			if (bot.bank.open()) {
				bot.logger.debug("*YAY*");
			}
		
			return 250;
		}
		
	}
	
	;

	private final String name;

	private Task(String name) {
		this.name = name;
	}

	public abstract boolean validate(Bot bot);
	public abstract int execute(Bot bot) throws InterruptedException;

	@Override
	public String toString() {
		return name;
	}
}

 

 

Bank open() checks if your bank is already open, so you're still calling the same code twice. Not like it matters much though ? 

Create an account or sign in to comment

Recently Browsing 0

  • No registered users viewing this page.

Account

Navigation

Search

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.