Taytot 4 Share Posted April 6 Why isnt my script looking at items that are on the ground? List<GroundItem> lootableItems = GroundItems.all(item -> item != null && goblinArea.contains(item) && item.exists() && item.distance(Players.getLocal()) < 5); if (!lootableItems.isEmpty()) { for (GroundItem item : lootableItems) { // Check if the item is either coins or bones if (item.getName().equals("Coins") || item.getName().equals("Bones")) { // Attempt to loot coins or bones if (item.interact("Take")) { log("Looting " + item.getName() + "..."); sleep(Calculations.random(2000, 4000)); return Calculations.random(2000, 3000); } else { log("Failed to loot " + item.getName() + "!"); } } } } Link to comment Share on other sites More sharing options...
Taytot 4 Author Share Posted April 7 (edited) Interesting. I had it after something else in my onloop order and it was not executing. I am looting now. I am learning so much Edited April 7 by Taytot Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now