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.

Explv

Scripter II
  • Joined

  • Last visited

Everything posted by Explv

  1. Just a heads up, I think the last person that tried to make a remote control type thing, wasn't allowed to do so.
  2. I don't really see how you are going to get that data without scripters integrating your API into their scripts. Which I think is unlikely. Nice idea though.
  3. You can still use WebWalkEvent. You just no longer need INodeRouteFinder. So just remove that from your code.
  4. You can only write to the data folder, the path of which is returned by: getDirectoryData()
  5. Your function definition is this: public void onMessage(String m) throws InterruptedException { } It should be: @Override public void onMessage(Message message) throws InterruptedException { } And now the Message variable is called message so: @Override public void onMessage(Message message) throws InterruptedException { String text = message.getMessage().toLowerCase(); }
  6. It is Java, not JavaScript. Two very different languages. Java: https://en.wikipedia.org/wiki/Java_(programming_language) JavaScript: https://en.wikipedia.org/wiki/JavaScript
  7. Use your own world hopper or Frostbug's. Or stop hopping so much
  8. No, this feature was removed. If you need to move the mouse instantly then you can use: final void moveMouseInstantly(final MouseDestination mouseDestination) { Rectangle boundingBox = mouseDestination.getBoundingBox(); moveMouseInstantly(random((int) boundingBox.getMinX(), (int) boundingBox.getMaxX()), random((int) boundingBox.getMinY(), (int) boundingBox.getMaxY())); } final void moveMouseInstantly(final int x, final int y) { getBot().getMouseEventHandler().generateBotMouseEvent(MouseEvent.MOUSE_MOVED, System.currentTimeMillis(), 0, x, y, 0, false, MouseEvent.NOBUTTON, true); } And I'm sure if you spent some time making your own MouseEvent then you could have it at whatever speed you want. However, the setMouseSpeed feature was removed for a reason.
  9. Using the OSBot API: final boolean itemIsInArea(final Area area, final String itemName) { return getGroundItems().filter(new AreaFilter<>(area), new NameFilter<>(itemName)).size() > 0; } Using the Java 8 Stream API : final boolean itemIsInArea(final Area area, final String itemName) { return getGroundItems().getAll().stream().anyMatch(groundItem -> groundItem.getName().equals(itemName) && area.contains(groundItem)); } Using a for loop: final boolean itemIsInArea(final Area area, final String itemName) { for(final GroundItem groundItem : getGroundItems().getAll()) { if(groundItem.getName().equals(itemName) && area.contains(groundItem)) { return true; } } return false; } If you want to get the closest matching item in the area you can do: With the OSBot API: final Optional<GroundItem> closestItemInArea(final Area area, final String itemName) { return Optional.ofNullable(getGroundItems().closest(new AreaFilter<>(area), new NameFilter<>(itemName))); } With the Java 8 Stream API: final Optional<GroundItem> closestItemInArea(final Area area, final String itemName) { return getGroundItems().getAll() .stream() .filter(groundItem -> groundItem.getName().equals(itemName) && area.contains(groundItem)) .min((g1, g2) -> Integer.compare(myPosition().distance(g1.getPosition()), myPosition().distance(g2.getPosition()))); } Or if you want to get any matching item in the area (not necessarily the closest) you can do: With the OSBot API: final Optional<GroundItem> getItemInArea(final Area area, final String itemName) { return Optional.ofNullable(getGroundItems().singleFilter(getGroundItems().getAll(), new AreaFilter<>(area), new NameFilter<>(itemName))); } With the Java 8 Stream API: final Optional<GroundItem> getItemInArea(final Area area, final String itemName) { return getGroundItems().getAll() .stream() .filter(groundItem -> groundItem.getName().equals(itemName) && area.contains(groundItem)) .findAny(); }
  10. I don't think there is a way of enabling mouse input any more. You could always try and do some hacky stuff like this: getBot().getCanvas().addMouseListener(new MouseAdapter() { @Override public void mouseClicked(MouseEvent e) { super.mouseClicked(e); getBot().getMouseEventHandler().generateBotMouseEvent( e.getID(), e.getWhen(), e.getModifiers(), e.getX(), e.getY(), e.getClickCount(), false, e.getButton(), true ); } });
  11. Why do you still need that feature?
  12. Yes. By the way, you say you want to learn how to program, if that is true then you should make some attempt to write the code yourself. This is the scripting help section not the scripting service section. Try and learn Java, look at the OSBot API, follow some tutorials, and then if you are still stuck request help here. Saying "I don't even know how to start this" is an indicator that you have not spent enough time trying to learn Java / scripting by yourself.
  13. I wrote that class a long time ago and it needs some improvement, sorry I do not have too much time to fix it up for you: In terms of using it, I recommend you follow some Java tutorials if you do not understand how classes work.
  14. This made my eyes bleed
  15. Nope Relax breh. There used to be a little notification on the main forum page that stated whether the client was down or not. It is not there any more though, maybe because the devs cba to update it every time / a lot of people didn't seem to notice it. Usually the client will be back up a few hours after an update, it happens most Thursdays too.
  16. Explv replied to Jonny's topic in Spam/Off Topic
    spam
  17. I'm just waiting for it to be uploaded to the SDN, then it will be open for testing
  18. You're welcome. If you don't find a reasonable solution such as Jar Launcher, you can always create a shell script to open OSBot for you: Step 1) Save this in a file called osbot.command: find ~/ -name "OSBot*.jar" -print0 | xargs -0 ls -t | head -n 1 | xargs -I{} java -jar {} Step 2) Make the file executable. To do this you will need to open up Terminal and type: chmod u+x /path/to/where/you/put/the/script/osbot.command Step 3) Double click the osbot.command file and it should open OSBot
  19. You will need to set the default application for .jar files as Java. If found this post on the internet, perhaps it will work for you (Sorry I do not use mac os) 1. Click once on the .jar file in the Finder. 2. From the menubar in the Finder select File -> Get Info". 3 Click on "Open with" and from the popup menu. 4. Select "Jar Launcher", which is built into OS X. 5. Whenever you double click on the .jar file the program will start.
  20. http://osbot.org/forum/topic/87717-fixing-osbot-not-starting/

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.