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.

Help with a chest

Featured Replies

No i dont want to be spoonfed but i have been trying trial and error on how to make it right click search for traps at the ardounge nature rune chest, not sure if i need to make it entity chest or entity stall = objects.closest("chest"); 

 

also on my state would it be SEARCH_FOR_TRAPS or is their a different way to do that? 

 

This is my first script and I am just trying to learn and this seems like an extremely easy script to start with! Any help or guidance would be appreciated thanks!

post-210432-0-51507600-1456931887_thumb.png

Did you try without those underscores?

this, i believe it searches for the literal string

Just a few bits of advice:

 

1. I would use RS2Object instead of Entity because Objects extends EntityAPI<RS2Object>. 
2. You are searching for the chest twice between your getState() and onLoop() which is a bit inefficient. If your getState() found the object, you should pass that object to your onLoop() without having to find it all over again.

 

But yes, no underscores. You are interacting with the action exactly as you see it in-game (with color tags being stripped).

  • Author

Is there any tips you could give me on programming bots? I do have some basic java knowledge and I am just trying to make simple scripts until learning how to do it efficiently.

Is there any tips you could give me on programming bots? I do have some basic java knowledge and I am just trying to make simple scripts until learning how to do it efficiently.

I also need this :/

Is there any tips you could give me on programming bots? I do have some basic java knowledge and I am just trying to make simple scripts until learning how to do it efficiently.

Just write whatever you want. You'll learn from that. Take something a bit harder than you think you can do. This will stimulate you to actually think about solutions to your problem.

Eventually your experience writing scripts and hopefully your Java knowledge will grow.

EDIT: Also, you should get rit of that framework as soon as possible!

Edited by Psvxe

  • Author

Just write whatever you want. You'll learn from that. Take something a bit harder than you think you can do. This will stimulate you to actually think about solutions to your problem.

Eventually your experience writing scripts and hopefully your Java knowledge will grow.

EDIT: Also, you should get rit of that framework as soon as possible!

why is that?

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.