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.

Explv

Scripter II
  • Joined

  • Last visited

Everything posted by Explv

  1. I believe this is a general issue with Local scripts at the moment. However, I will be uploading a new version of this script later today, so hopefully that will work for you. Thanks
  2. Something like this should do it: // Set colour to white g.setColor(Color.white); // Get current mouse position Point mousePoint = getMouse().getPosition(); // Draw a rectangle starting at x-10, y-10, with width and height of 20 g.drawRect(mousePoint.x - 10, mousePoint.y - 10, 20, 20); // Draw a line from top of screen (0), to bottom (500), with mouse x coordinate g.drawLine(mousePoint.x, 0, mousePoint.x, 500); // Draw a line from left of screen (0), to right (800), with mouse y coordinate g.drawLine(0, mousePoint.y, 800, mousePoint.y);
  3. In the case of Tutorial Island, every interaction with an NPC is followed by the user selecting continue. So you can use: final ConditionalSleep dialogSleep = new ConditionalSleep(5000) { @Override public boolean condition() throws InterruptedException { return script.getDialogues().isPendingContinuation(); } };
  4. Problem was he had some other files in his .jar other than 'compiled output' .
  5. Try deleting the OSBot folder, restarting OSBot, and then re-building your script.
  6. Couldn't that be simplified to: boolean isMining = false; if(clayRock1 != null && (!myPlayer().isAnimating() || !isMining)){ clayRock1.interact("Mine"); isMining = true; sleep(random(2000, 2200)); } else if (clayRock1 == null){ isMining = false; } So that when isMining == false it ignores the fact that the player is animating, and tries to mine anyway?
  7. I think the problem is your PATH got fucked up somehow. Go to the Chat Box, and i'll try and help
  8. Maybe you need to update the Java path in Eclipse now that you have updated Java? Edit: http://bfy.tw/2p2K
  9. Entity clayRock1 = objects.closest(ID_CLAY1); if(clayRock1 != null && !myPlayer().isAnimating()){ clayRock1.interact("Mine"); sleep(random(2000, 2200)); } else if(clayRock1 == null){ // Do something else }
  10. Method 1) The rock will have a different ID when there is no ore Method 2) If the rock no longer has the "Mine" action, when there is no ore (i cant remember if it does or not) then you could check that
  11. That is probably because I didn't put in anything for bones.interact(); You need to specifiy the pick up action like bones.interact("Take"); To prevent it from clicking other stuff Edit: I fixed it Edit2: I also didn't really think about it, the bones when on the ground wont have the action "Bury", so I changed the filter
  12. No problem ^_^
  13. I have commented it to maybe help you understand
  14. Maybe something like import org.osbot.rs07.api.filter.Filter; import org.osbot.rs07.api.model.GroundItem; import org.osbot.rs07.api.model.Item; import org.osbot.rs07.script.Script; @ScriptManifest(author = "Noob", name = "Noob Script", version = -15.0, logo = "", info = "Does some noob shit") public class Burier extends Script { private enum STATE{ PICKING, BURYING } // Enum for our two script states private STATE getState(){ if(!getInventory().isFull()) return STATE.PICKING; // When the inventory is not full, pick bones else return STATE.BURYING; // When the inventory is full, bury bones } @Override public int onLoop() throws InterruptedException { switch (getState()){ // Get the current state case PICKING: pick(); // If we are picking, call the pick method break; case BURYING: bury(); // If we are burying, call the bury method break; } return 0; } private void pick(){ /* Get the closest ground item that matches our filter, in this case items which name contains "bones". This could be simplified by storing the names of all bones in a String[] */ GroundItem bones = getGroundItems().closest(new Filter<GroundItem>() { @Override public boolean match(GroundItem groundItem) { return groundItem.getName().toLowerCase().contains("bones"); } }); if(bones != null){ // Check that we found bones on the ground bones.interact("Take"); // If we did, pick them up try{ sleep(random(1000, 1200)); // Sleep for between 1 and 1.2 seconds after clicking on the bones } catch(InterruptedException e){ log(e); } } } private void bury(){ for(Item item : getInventory().getItems()){ // Iterate over each inventory item if(item.hasAction("Bury")) { // If it has the "Bury" action item.interact("Bury"); // Bury it try{ sleep(random(1000, 1200)); // Sleep for between 1 and 1.2 seconds after burying } catch(InterruptedException e){ log(e); } } } } }
  15. Fill inventory from what? your bank?
  16. wtf is that Observer Arrays.stream(getInventory().getItems()) .filter(item -> item.hasAction("Bury")) .foreach(bones -> bones.interact("Bury")); or for(Item item : getInventory().getItems()){ if(item.hasAction("Bury")) item.interact("Bury"); }
  17. Why are you trying to do that
  18. I just need a release that has it and i'll do the rest. steal the rest.
  19. This isn't really a "scripting help" question, you can enable cursor trail in Options -> Debug -> Mouse trail Edit: I didn't even read your question apparently. Although i'm fairly sure Mouse trail in settings == Bot's mouse trail
  20. Explv replied to Keven's topic in Archive
    They are all awesome games. Fallout 3 has 9/10 on Steam, 9.6 / 10 on IGN, got game of the year etc. Fallout New Vegas has 10/10 on Steam and 8.5/10 on IGN. Fallout 4 also doesn't continue on from the previous games so you don't ned to have played them. Bugs are pretty irrelevant.
  21. For walking just use getLocalWalker().walk() and getLocalWalker().walkPath() This: Entity essence = getObjects().closest(essenceID); if (essence != null && essence.interact("Mine")) { if (essence.isVisible()) { essence.interact("Mine"); log("Mining some essence"); } } Is also wrong you are calling essence.interact("Mine") in your if statement??? Should be more like: RS2Object essence = getObjects().closest(essenceId); if(essence != null) essence.interact("Mine"); I also suggest you add more states to your script. For example, WALK_TO_BANK and WALK_TO_ESSENCE and update your getState method to something like: private State getState() { if (getInventory().isFull()) { if(BANK_AREA.contains(myPosition())) return State.BANK; else return State.WALK_TO_BANK; } else { if(MINE_AREA.contains(myPosition()) return State.MINE: else return State.WALK_TO_ESSENCE; } } For banking you are doing: if (bankBooth != null && bankBooth.interact("Bank")) { if (bankBooth.isVisible()) { log("Opening Bank"); bankBooth.interact("Bank"); sleep(random(1500, 2000)); } else { camera.toEntity(bankBooth); } } But there are methods that already do this in the API: getBank() getBank().open() getBank().isOpen() getBank().close() etc. For walking to an entity or area you can use: getLocalWalker().walk(entity.getPosition()); and getLocalWalker().walk(area.getRandomPosition()); For moving camera to the portal: getCamera().toEntity(getObjects().closest("Portal")); For interacting with the portal why not make a path to the portal, then click on the portal, then follow another path to the essence. For detecting when you are at the Essence you could potentially use a nearby object e.g. if(getObjects().closest("Essence") != null) return State.MINING;
  22. Most of these bugs should be fixed now, update to latest and let me know if there are any more problems These bugs should be fixed now. Thanks
  23. I have been made aware that there are bugs in the script. Haven't gotten around to fixing them yet, as i've been busy doing other things. I will patch it up later :P
  24. Oops didn't even notice. Corrected my post, thanks for pointing it out.

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.