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
  • Script not eating


    Recommended Posts

    Hey guys I'm pretty stuck I've tried loads of different ways and each time I can't seem to get my script to eat.

    if (getCombat().getHealthPercent() <= Calculations.random(12, 37)) {
                            log("IT detects its low");

    So it detects the above and notices it's low, but it doesn't eat

        private void eat(){
            food = getInventory().get(item -> item != null && item.hasAction("Eat"));
            if (food != null && food.interact("Eat")) {
                log("Trying to eat");
                    state = 3;
                }else if(getCombat().getHealthPercent() <= Calculations.random(12, 37)){
                    state = 3;

    I'm not sure where i've gone wrong, any help would be great<3

    Link to comment
    Share on other sites


    Thats not the problem i'm having. Its detecting im low, its just no eating


    edit: it does work mb thanks alot bro

    Edited by veeniqqa
    Link to comment
    Share on other sites


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