Jump to content

getInventory.contains problems


Recommended Posts

Posted

Hello,

For some reason this keeps logging 2 while I'm 100% sure I got a Wooden shield in my inventory...

Quote

public boolean woodenShieldInBotInv() {        
        if (phreeBot.getInventory().contains("Wooden shield")) {
            phreeBot.log("1");
            return true;
        } else {
            phreeBot.log("2");
        }
        return false;
    }

 

What am I doing wrong? When I create a new project with the same code it just works however in my existin project it doesn't when it used to work just right. Before asking what all my other code is, does that matter? 

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

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