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.

senpai jinkusu

Members
  • Joined

  • Last visited

  1. noob question, i thought you couldn't instantiate interfaces, so why is this allowed? edit: nvm it's an anon class so im guessing java understands it's a class and not a filter, i did not know this functionality was possible as my understanding of anon class is somehwat limited
  2. Im still pretty new when it comes to osbot scripts ( and rs bots in general) but I'll definitely keep that in mind
  3. if i instantiate it like so ent= getObjects().closest(new Area(...,tree id); and it is not null, i chop it, it respawns, will this still be valid
  4. this is off topic but i also have another question and i dont want to make another topic, are references to entities still valid after the entity changes (ie. when you chop down a tree and becomes a tree stump that entity changes) , so basically if i could still interact with the same tree instance after it respawns
  5. this was driving me nuts lol, i could not get the bot to find my script, until i figured out it only allows up to 1 local script, so i just deleted the other jar i had in there
  6. Nifty, I will look further into this when I get the chance
  7. i don't know where this was discussed, also not even this seems to work so i think all hope is lost for this method lol. for now i will stick with the following code mouse.move(260,410); mouse.click(true); mouse.click(253,460,false); isSmelting = true;
  8. is that what i type as the argument then?
  9. I am almost sure im using the correct one https://gyazo.com/3283400a03e61ea57100240ab3cd20c1
  10. ill give that a try, however the widget doesn't seem to be working, this is my code for steel bars RS2Widget smeltMenu = widgets.get(311,30); if(smeltMenu != null && smeltMenu.isVisible()) smeltMenu.interact("Smelt 10"); i can successfully interact with the furnace, however it doesn't interact with the steel bar widget, is there anything I could be missing?
  11. thanks! one more question, how do i check if the player is currently performing the action stated by the widget, ie. if i smelt 10 bars how can i check if the action was completed?, or if the player is currently smelting ( i could simply make a routine to count for the items created in the inventory but is there an easier way?) edit: ill just store in a boolean to see if the player is currently smelting for now
  12. i know how to do simple interaction with entity.interact(); however how would you interact with entities such as a furnace that bring up a menu afterwards?
  13. you know im glad you mentioned the getInventory function, whenever i use just "inventory" it will return the correct number of ores on the first cycle then the next 3 it returns 0, either way here is the final code minus the removal of generics <T extends ItemContainer>int getOreCount ( T itemContainer, int... IDs) { if (itemContainer != null) return (int)itemContainer.getAmount(IDs); return 0; } public int onLoop() throws InterruptedException { log(Integer.toString(getOreCount(getInventory(),IDs[0],IDs[1]))); return random(200, 300); } which so far is working fine and ended up being way more efficient than the old code, although Im not sure if checking for a null ItemContainer reference is necessary since that never seems to be the case, tho i suppose if i don't need to check if it's null i could just narrow it down to log(Long.toString(getInventory().getAmount(IDs[0],IDs[1])));
  14. I think my misunderstanding was thinking of the ItemContainer as an interface rather than a class, so I was only limited to those methods explicitly stated by the API under a given child class, so does this mean I can call any ItemContainer method and expect a relevant result?, also that link cleared a lot of things up for me as well
  15. http://osbot.org/api/org/osbot/rs07/api/Inventory.html the Inventory subclass doesn't override the ItemContainer's "getItemInSlot" abstract method, meaning it's always gonna use the same method definedd in the parent class

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.