Jump to content

Super new to Java, bot works but won't pick up items.


Recommended Posts

Posted (edited)
        if (npcs.closest(npcChompyBirdAlive) != null){
            return State.KILL_CHOMPY;

How do i make it so that it checks when there is an item on the ground, return to state KILL_CHOMPY; ?

 

if(getGroundItems().closest("whatever") != null){
    return State.PICK_UP_ITEM;
} else if(getNPCs().closest(npcChompBirdAlive) != null){
    return State.KILL_CHOMPY;
}
Edited by Explv
  • Like 1

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...