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.

Avoiding Exploding rocks

Featured Replies

your rock id changes, make a constant check on what your player is interacting with.

  • Author

Does it turn into an NPC? Or does it giveout an animation?

 

I believe it has an animation, and I've noticed that it has a verticeCount > 128 (due to the added animation), while regular rocks have a verticeCount < 128, so I tried

while (client.getMyPlayer().isAnimating()) {
	if (closestRock.getModel().getVerticeCount() > 128) {
		walkMiniMap(new Position(client.getMyPlayer().getPosition().getX() + random(-1, 1), client.getMyPlayer().getPosition().getY() + random(-1, 1), 0));
		this.MRT = random(2048, 4096);
		sleep(this.MRT);
	}
}

, but it isn't working...

your rock id changes, make a constant check on what your player is interacting with.

 

Can you point me to the method that allows me to get the object that my character is interacting with?

It turns into an NPC. See the rock's name change to yellow as if you hover an NPC.

RS2Object rock = closestObjectForName("rock");
if(rock != null) {
if(rock.interact("mine") {
RS2Object temp = closestObjectForName("rock");

//basically scans if the closest object is the same object you interacted with
while(rock == temp && rock.exists()) {
sleep(500);
} 

}
}

Cheap method i use

As an example, when I successfully click on a tree and begin cutting, I set a global RS2Object named currentTree to the tree I just cut. Then I have it constantly check to see if the ID changes. When a tree turns into an ent my script changes to a different tree (automatic), or if there is none, walks away to stop cutting (extra method). I imagine you could do the same with exploding rock.

Edited by TheSaint

Guest
This topic is now closed to further replies.

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.