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
  • Open source saltpetre script


    Hashtag
     Share

    Recommended Posts

    	private boolean weKnowWhereItIs () {
    		for (int i = 0; i < areaStatus.length; i++)
    			if (areaStatus[i] == 1)
    				return true;
    		return false;
    	}
    
    	private int indexOfWhereItIs () {
    		for (int i = 0; i < areaStatus.length; i++)
    			if (areaStatus[i] == 1)
    				return i;
    		return -1;
    	}
    

    this could just be 1 function, indexOfwhereItIs, you dont need the other 1

    Link to comment
    Share on other sites

    	private boolean weKnowWhereItIs () {
    		for (int i = 0; i < areaStatus.length; i++)
    			if (areaStatus[i] == 1)
    				return true;
    		return false;
    	}
    
    	private int indexOfWhereItIs () {
    		for (int i = 0; i < areaStatus.length; i++)
    			if (areaStatus[i] == 1)
    				return i;
    		return -1;
    	}
    

    this could just be 1 function, indexOfwhereItIs, you dont need the other 1

     

     

    Good point! I am not exactly sure why I ended up writing it like that. Anyone who uses this is free to modify and improve the code =)

    Link to comment
    Share on other sites

    I've been using this script and it is great ! I found just one problem, in a specific position of the saltpetre mine it gets stuck because its too far from the mine and then the camera angle can click on it. How do I make the player go closer to the saltpetre in order to prevent this ??

    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.