Jump to content

Loot GroundItem?


Huz

Recommended Posts

item.interact("Take");

If you want to actually find a GroundItem then you could try

GroundItem item = groundItems.closest(new Filter<GroundItem>() {
    @Override
    public boolean match(GroundItem item) {
        return item.getName().equals(ITEMNAME);
    }
});
if (item != null) {
    item.interact("Take");
}
  • Like 1
Link to comment
Share on other sites

http://osbot.org/api/org/osbot/rs07/api/model/GroundItem.html

I'm sure that from there you'll be able to figure it out :)

I found that but still don't understand how to implement it. Was getting some errors. Can I get a sample of a looting method?

item.interact("Take");
If you want to actually find a GroundItem then you could try
GroundItem item = groundItems.closest(new Filter<GroundItem>() {    @Override    public boolean match(GroundItem item) {        return item.getName().equals(ITEMNAME);    }});if (item != null) {    item.interact("Take");}
Wow was so close, will try this after I get home from class tomorrow. Thanks
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...