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
  • How to eat?


    Woflyz

    Recommended Posts

    Posted

    This might be a really stupid question, but I couldn't find the answer to it anywhere else, how do I make it consume something, what's the code for it? Thanks in advance!

    Posted

    there is this thing called a mouth funny little hole near the bottem of ur head

    you take some food and put it in this hole

    thats pretty much all there is to it

    Posted
    public void eatFood() {
    		if (!getScript().getTabs().isOpen(Tab.INVENTORY)) {
    			getScript().getTabs().open(Tab.INVENTORY);
    		} else {
    			Item food = getScript().getInventory().get(item -> item != null && item.hasAction("Eat"));
    			if (food != null) {
    				food.interact("Eat");
    				MethodProvider.sleepUntil(() -> getScript().getLocalPlayer().getHealthPercent() > 70, 1500);
    			}
    		}	
    	}

     

    Posted

    I have placed this into my script, but it errors on getScript(), how should I fix that? I'm really unexperienced with this :p

    Posted
    1 hour ago, Woflyz said:

    I have placed this into my script, but it errors on getScript(), how should I fix that? I'm really unexperienced with this 😛

    delete it as u prob only have 1 class

    Archived

    This topic is now archived and is closed to further replies.

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