Jump to content
Frequently Asked Questions
  • Are you not able to open the client? Try following our getting started guide
  • Still not working? Try downloading and running JarFix
  • Help! My bot doesn't do anything! Enable fresh start in client settings and restart the client
  • How to purchase with PayPal/OSRS/Crypto gold? You can purchase vouchers from other users
  • Try asking for help in the chatbox
  • Pest Control door problem


    kamilo
     Share

    Recommended Posts

    hey guys since the walk method automatically opens doors, 

    when you're in pest control, the door becomes damaged and so the bot tries to keep opening it

    To4vioV.jpg

    in this case, it can't. and if the door is coempletely gone it will still try that 'open' option

    is there a way around it? i was thinking filtering any doors that have the action ("repair") on them and not open them

    can i do that?

     

    Link to comment
    Share on other sites

    17 minutes ago, Pseudo said:

    Yes you can.

    whats the command for neglecting doors

    i know about addObstable  but i see nothing like IgnoreObstacle or somthing similar

    Link to comment
    Share on other sites

    28 minutes ago, kamilo said:

    whats the command for neglecting doors

    i know about addObstable  but i see nothing like IgnoreObstacle or somthing similar

    Something like this should work, maybe wrong format because I didn't do this in an IDE:

    Filter<GameObject> doorFilter = GameObject -> GameObject != null && GameObject.getName().equals("door") && !GameObject.hasOption("repair");

    Link to comment
    Share on other sites

    17 minutes ago, AsBakedAsCake said:

    Something like this should work, maybe wrong format because I didn't do this in an IDE:

    Filter<GameObject> doorFilter = GameObject -> GameObject != null && GameObject.getName().equals("door") && !GameObject.hasOption("repair");

     

    thats fine but how do i incorportate it with getWalking() because that method is autmatically opening doors

    or should i do

     Filter<GameObject> doorFilter = GameObject -> GameObject != null && GameObject.getName().equals("door") && !GameObject.hasOption("repair");

    addObstacle(doorFilter,) etc..?

    and this will automatically focus on doors without "repair" options 

    ^is that correct?

    Link to comment
    Share on other sites

    2 minutes ago, kamilo said:

    or should i do

     Filter<GameObject> doorFilter = GameObject -> GameObject != null && GameObject.getName().equals("door") && !GameObject.hasOption("repair");

    addObstacle(doorFilter,) etc..?

    and this will automatically focus on doors without "repair" options 

    ^is that correct?

    You'll have to do some experimenting, but you may be able to do it that way. You may be able to make a filter for the obstacle rather than the GameObject, this is just something I thought of off the top.

    Link to comment
    Share on other sites

    5 hours ago, AsBakedAsCake said:

    You'll have to do some experimenting, but you may be able to do it that way. You may be able to make a filter for the obstacle rather than the GameObject, this is just something I thought of off the top.

    okay but is there a way to disable opening doors from the getWalking() method???

    Link to comment
    Share on other sites

    5 hours ago, Pseudo said:

    Just simply check if a door with the repair option is nearby and if so recalculate path?

     

    okay ill add a boolean check in my walkTo() method; but how would i go about doing this recalculated method

    Link to comment
    Share on other sites

    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
     Share

    ×
    ×
    • Create New...

    Important Information

    We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.