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.

[Scripter Noob] Help again :P

Featured Replies

ohmy.png

I want to to select the talisman and interact with the ruins

but it only returns the option for tiaras aka "Enter"

 Entity ruins = s.objects.closest("Mysterious ruins");
        if (ruins != null) {
            s.sleep(s.random(3000)+500);
            if (s.getInventory().contains("Air talisman")) {
                if (s.getInventory().getSelectedItemName().equals("Air talisman")) {
                    ruins.interact("Use");
                    s.sleep(s.random(300) + 600);
                } else {
                    s.inventory.getItem("Air talisman").interact("Use"); //if first statement is not true it will select it again (Hoping )
                }
            } else {
                ruins.interact("Enter"); //if you are using a tiara it will just call 'enter' and go inside
                s.sleep(s.random(300) + 1000);
            }
        }

 

ohmy.png

I want to to select the talisman and interact with the ruins

but it only returns the option for tiaras aka "Enter"

 Entity ruins = s.objects.closest("Mysterious ruins");
        if (ruins != null) {
            s.sleep(s.random(3000)+500);
            if (s.getInventory().contains("Air talisman")) {
                if (s.getInventory().getSelectedItemName().equals("Air talisman")) {
                    ruins.interact("Use");
                    s.sleep(s.random(300) + 600);
                } else {
                    s.inventory.getItem("Air talisman").interact("Use"); //if first statement is not true it will select it again (Hoping :))
                }
            } else {
                ruins.interact("Enter"); //if you are using a tiara it will just call 'enter' and go inside
                s.sleep(s.random(300) + 1000);
            }
        }

 

Can't help you if you're making a runecrafter ... QwPha8E.png

 

Tip:

Make sure to do inventory.isItemSelected() && s.getInventory().getSelectedItemName().equals("Air talisman")

 

Khaleesi

Edited by Khaleesi


public boolean usePleb(String action, String action2) { // action == the item it is going to select,  action2 == in this case, is the ruins      

     Entity ruins = objects.closest(action2);

     if (inventory.isItemSelected()) { // IF ITEM IS SELECTED
     if (inventory.getSelectedItemName() == action) { // IF THE SELECTED ITEM IS == action
     ruins.interact("Use");
     } else {
     inventory.deselectItem();
     }
     } else {
     inventory.interact("Use", action); // THIS ONE WILL SELECT THE ITEM IF ITEM IS NOT SELECTED
     }
     return true;
     }

to use this just use;

usePleb("Air talisman", "Mysterious Ruins");

Edited by iJodix


public boolean usePleb(String action, String action2) { // action == the item it is going to select,  action2 == in this case, is the ruins      

     Entity ruins = objects.closest(action2);

     if (inventory.isItemSelected()) { // IF ITEM IS SELECTED
     if (inventory.getSelectedItemName() == action) { // IF THE SELECTED ITEM IS == action
     ruins.interact("Use");
     } else {
     inventory.deselectItem();
     }
     } else {
     inventory.interact("Use", action); // THIS ONE WILL SELECT THE ITEM IF ITEM IS NOT SELECTED
     }
     return true;
     }

to use this just use;

usePleb("Air talisman", "Mysterious Ruins");

 

 

Here's a nicer version ;)

public boolean usePleb(String itemName, String objectName) {
	if (objectName.isEmpty() || itemName.isEmpty() || !getInventory().contains(itemName)) return false;
	
	Entity localEntity = getObjects().closest(objectName);
	if (localEntity == null || !localEntity.exists()) return false;
	
	if (!localEntity.isVisible()) getCamera().toEntity(localEntity);
	
	if (getInventory().isItemSelected() && !getInventory().getSelectedItemName().equalsIgnoreCase(itemName)) getInventory().deselectItem();
	
	getInventory().interact("Use", itemName);
	localEntity.interact("Use");
	
	return true;
}

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.