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.

Hovering over Table Item - currently hovering on ground tile below object

Featured Replies

public static Position pos = new Position(3018, 5013, 0);

public void grabWine() {
    if ((System.currentTimeMillis() - wineTimer) > 3000) {
        if (getMagic().isSpellSelected()) {
            GroundItem wine = getGroundItems().closest("Wine of zamorak");
            if (wine != null && wine.isVisible()) {
                winePosition = wine.getPosition();
                if (wine.interact("Cast")) {
                    wineTimer = System.currentTimeMillis();
                    amountOfWines++;
                }
            } else if (winePosition.isVisible(getBot())) {
                Rectangle rect = pos.getPolygon(getBot()).getBounds();
                getMouse().move(rect.x + (rect.width / 2), rect.y);
            } else {
                log("Moving camera to wine");
                getCamera().toEntity(wine);
            }


        } else {
            log("Spell not selected, Select telegrab");
            getMagic().castSpell(Spells.NormalSpells.TELEKINETIC_GRAB);
        }
    } else {
        if (getMagic().isSpellSelected()) {
            GroundItem wine = getGroundItems().closest("Wine of zamorak");

            if (wine != null && wine.isVisible()) {
                winePosition = wine.getPosition();

                log("Wine is visible and spell selected");
            } else if (winePosition.isVisible(getBot())) {

                Rectangle rect = pos.getPolygon(getBot()).getBounds();
                getMouse().move(rect.x + (rect.width / 2), rect.y);
            } else {
                log("Moving camera to wine");
                getCamera().toEntity(wine);
            }
        } else if (!getMagic().isSpellSelected()) {
            log("Spell not selected, Select telegrab");
            getMagic().castSpell(Spells.NormalSpells.TELEKINETIC_GRAB);
        }
    }
}

Hi guys, Trying to hover over a table item. However, with the code above hovers on the tile below the table as the wine is considered a ground item. Any way around this? Thanks for any help

after you interact with the wine (cast) you could probaly get your mouse position and save that (this is a realllllly bad way of doing things though so only use that option if nothing else works for you) 

  • Author
27 minutes ago, Camaro said:

I actually hover over the position above it in mine

How do you go about doing that lol

21 minutes ago, TheMcPker said:

after you interact with the wine (cast) you could probaly get your mouse position and save that (this is a realllllly bad way of doing things though so only use that option if nothing else works for you) 

Interesting idea, may try that if cant think of anything else, Thanks!

 

21 minutes ago, Titan Rs said:

How do you go about doing that lol

you could probaly get the position of the mouse as Point (this would be inacurate if the screen rotates since it takes the exact mouse position )

1 hour ago, Titan Rs said:

How do you go about doing that lol

 

say the wine is on position(x, y, z)

hover over position(x, y + 1, z)

 

and why did you post this in the market section lol

Edited by Camaro

  • Author
10 hours ago, TheMcPker said:

you could probaly get the position of the mouse as Point (this would be inacurate if the screen rotates since it takes the exact mouse position )

I did this in the end and works well, Thanks!

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.