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

    Popular Content

    Showing content with the highest reputation on 10/17/19 in all areas

    1. Hello Everyone! This is a simple but yet useful guide to Buying & Selling on the Grand Exchange! Why would you want to Buy & Sell on the Grand Exchange? You could add this functionality to your scripts allowing them to buy resources & sell end-products. More Automation = More Laziness on your end! __________ Let's start with the methods that are of use to us. getGrandExchange() - Gets the GrandExchange File to allow you to use its methods in your script. getArea(BankLocation.GRANDEXCHANGE).contains(getLocalPlayer()) - Detects if the bot/player is in a certain radius of the GrandExchange. getGrandExchange().open() - Opens the GrandExchange interface getGrandExchange().openBuyScreen(int slot) - Opens Buy slot (Slot has to return slotContainsItem(int slot) == false ) getGrandExchange().getFirstOpenSlot() - Checks for an open slot, and returns the first one it sees (Integer) getGrandExchange().getFirstOpenSlot() == -1 - Can be used in an if statement/switch to detect if there are no open slots getGrandExchange().isBuyOpen() - A simple boolean that detects if the buy screen is open. getGrandExchange().isSellOpen() - A simple boolean that detects if the sell screen is open. getGrandExchange().buy(String itemName, int Quantity, int Price) - Does the whole buying process when getGrandExchange().isBuyOpen() == true getGrandExchange().sell(String itemName, int Quantity, int Price) - Does the whole selling process when getGrandExchange().isSellOpen() == true getGrandExchange().cancelOffer(int slot) - If slot contains item, then cancel the offer. getGrandExchange().cancelAll() - Newly added method by @Nuclear Nezz's DB Update which allows for cancellation of all offers. Example Case: If your bot is currently doing a task, and you want it to go sell the end products of the task after reaching a certain threshold. - Add this when the task script is checking the inventory and/or bank: (explanation in code) Inventory: if(getInventory().count(String itemName or int itemNumber) == int itemQuantityWanted) { //Check if the task item has reached its threshold, if true it executes the startGE(); method startGE(); //Don't worry, we're going to be creating this method below! - Starts the GE Buying/Selling process } Bank: if(getBank().contains(String itemName or int itemNumber, int Quantity)) { //Check if the task item has reached its threshold, if true it executes the startGE(); method startGE(); //Don't worry, we're going to be creating this method below! - Starts the GE Buying/Selling process } Making the startGE() method requires us to make a couple of methods to accomplish what we need (You can stuff it all in one method or you can do it in Nodes): We need these variables & methods: Variables: BankLocation GEBank = BankLocation.GRAND_EXCHANGE; //Assigns our GEBank variable the GE Location private static final itemToSell = 0000; //Item ID //OR private static final itemToBuy = 0000; //Item ID private static final COINS = 995; //gets COINS Item ID int state; //We're going to be using this to set the state to Buying or Selling. int currentOpenBuySlot; //This variable will contain the slot that will be opened int currentOpenSellSlot; //This variable will contain the slot that will be opened Now some methods: Methods: private void walkToGE() { //Check if the player is at the GE (if false - walks there) if(!GEBank.getArea(5).contains(getLocalPlayer()) { // Checks if the player is in GE spreading 5 tiles getWalking().walk(GEBank.getCenter()); //walks to the center point of the GEBank //OR getWalking().walk(GEBank.getRandomTile()); //Randomizes point of arrival at the GEBank } private void fetchFunds() { //Only regarding the Buying state if(!getInventory().contains(COINS)) { //checks if the inventory contains COINS getBank().openClosest(); //Opens closest bank, you can set it to open(GEBank) if you want. getBank().withdrawAll(COINS); // withdraws all coins, you can set it to withdraw(COINS, int quantity) if you want. getBank().close(); //closes bank interface } } private void fetchItemsToSell() { if(!getInventory().count(itemToSell) == int itemQuantity) { getBank().openClosest(); //Opens closest bank, you can set it to open(GEBank) if you want. getBank().withdraw(itemToSell, itemQuantity); getBank().close(); //closes bank interface } } private void openBuyScreen() { if(!getGrandExchange().isBuyOpen()) { //check if buy isn't open currentOpenSlot = getGrandExchange().getFirstOpenSlot(); //set currentOpenSlot to a random non-occupied slot getGrandExchange().openBuyScreen(currentOpenBuySlot); //opens the slot sleep(1000); //sleeps for a sec } } private void openSellScreen() { if(!getGrandExchange().isSellOpen()) { //check if sell isn't open currentOpenSlot = getGrandExchange().getFirstOpenSlot(); //set currentOpenSlot to a random non-occupied slot getGrandExchange().openSellScreen(currentOpenSellSlot); //opens the slot sleep(1000); //sleeps for a sec } } private void collectAll() { if(getGrandExchange().isReadyToCollect()) { //check if there are bought/sold items getGrandExchange().collect(); //clicks the collect button on the ge interface sleep(2000); //sleeps 2 secs - calculated } } Now lets start with identifying what state of GE Trade you want: We'll set it to : If state = 1 then Buying is the state, if state = 2 then Selling is the state You can implement the states in your script GUI OR edit it manually! startGE() method will do the detection then execute the suitable method that we'll create after it! private void startGE() { switch(state) { // read what value state is set to case 1: //Buying state executeBuyer(): //method to start the buying process break; case 2: //Selling state executeSeller(); //method to start the selling process break; } } You can set the state using a setter: public void setState(String state) { this.state= state; } Let's start with the execution methods: ExecuteBuyer: private void executeBuyer() { walkToGE(); //if you're already at the GE, the script will ignore this line fetchFunds(); //if you already have coins in your inventory, the script will ignore this line collectAll(); //if there are successfully bought items, this will collect the items openBuyScreen(); //Detects if a buy screen isnt open and opens it getGrandExchange().buy(itemToBuy, int quantity, int price); //Buys the item /** This part is for canceling the order if the item isn't bought **/ sleep(2000); //sleeps for 2 secs because, it takes around 1.5 seconds for the item to return (Bought successfully or Still in the process) if(getGrandExchange().slotContainsItem(currentOpenSlot)) { //checks if the slot that we currently occupied contains an item/didn't sell getGrandExchange().cancelOffer(currentOpenSlot); //cancel the offer sleep(1000); //sleeps for 1 sec getGrandExchange().goBack(); } /** This part is stop the script from looping the buying process during the buying process. **/ if(getGrandExchange().isBuyOpen()) { // checks if buy screen is open sleepUntil(()-> getGrandExchange().isBuyOpen() == false, 2000); //sleeps/doesn't loop till the item is successfully bought and we're back to the main GE interface } } ExecuteSeller: private void executeSeller() { walkToGE(); //if you're already at the GE, the script will ignore this line fetchItemsToSell(); //if you already have the item(s) in your inventory, the script will ignore this line collectAll(); //if there are successfully sold items, this will collect the items openSellScreen(); //Detects if a sell screen isnt open and opens it getGrandExchange().sell(itemToSell, int quantity, int price); //sells the item /** This part is for canceling the order if the item isn't sold **/ sleep(2000); //sleeps for 2 secs because, it takes around 1.5 seconds for the item to return (Bought successfully or Still in the process) if(getGrandExchange().slotContainsItem(currentOpenSellSlot)) { //checks if the slot that we currently occupied contains an item/didn't sell getGrandExchange().cancelOffer(currentOpenSellSlot); //cancel the offer sleep(1000); //sleeps for 1 sec getGrandExchange().goBack(); } /** This part is stop the script from looping the selling process during the selling process. **/ if(getGrandExchange().isSellOpen()) { // checks if sell screen is open sleepUntil(()-> getGrandExchange().isSellOpen() == false, 2000); //sleeps/doesn't loop till the item is successfully sold and we're back to the main GE interface } } and There you go! The script will detect if the state is "Selling" or "Buying" then walks there, gets the coins/items, sells/buys, collects/cancels! Note: this guide is for single item buy/sell handling, although it does work for mass items, you just have to make a reader class, then read the items from a txt file.. then make a foreach loop/iterator to get the items then replace itemToSell/itemToBuy with the looped string .. EXTRA!! Example: ReadFile Methods: List<String> allItems = new ArrayList<String>(); List<String> item = new ArrayList<String>(); List<String> price = new ArrayList<String>(); List<String> quantity = new ArrayList<String>(); public BuyerReader(String path) { readFile(path); } public void readFile(String path) { File file = new File(path); if(file.exists()){ try { allItems = Files.readAllLines(file.toPath(),Charset.defaultCharset()); } catch (IOException ex) { ex.printStackTrace(); } if(allItems.isEmpty()) return; } for(String line : allItems){ String [] res = line.split(";"); item.add(res[0]); price.add(res[1]); quantity.add(res[2]); } } public List<String> getAllItems() { return allItems; } public List<String> getItem() { return item; } public List<String> getPrice() { return price; } public List<String> getQuantity() { return quantity; } GetValues Iterator Variable: itemNames = Reader.getItem().iterator(); ReadReader Method: private String getItemName() { //This is for the itemname, you can do the same for quantity/price just parse it to int. String itemn = null; if(itemNames.hasNext()) { String in = itemNames.next(); itemn = in; } else { stop(); log("No more items to read!"); } return itemn; } If I have written something wrong, please tell me! I'm a human, and humans make mistakes That's what we do best! 🖖 Peace!
      4 points
    2. Purchase using PayPal, OSRS GOLD, CRYPTO or OTHER Features Best combat experience per hour Rock cake support Prayer flicking support Supports potions Supports power ups Re-enters dream Supports special attacks Leave when max points are gained Active customer support Requirements 5 quests Preferably high combat stats Gallery @dariuss56 99 Strength! @Cj1010 168 hours! @Tjtheking1 @bhf http://i.imgur.com/yL5imKR.png @jangan http://i.imgur.com/buzkl0s.png http://i.imgur.com/qxkEKAI.png http://i.imgur.com/F1Nd9Ez.png@icheat1337 @Tjtheking1 http://image.prntscr.com/image/6733a64df08b40b9a006342f7cbf7fe9.png @redmaster16 http://image.prntscr.com/image/d6f402dc2def455fac6f23df0cedb6bc.png @Sappig http://i.imgur.com/qzkKnCV.png @Sonder http://i.imgur.com/dNoLUwu.png @theman55 @iJava http://i.imgur.com/OeKz0p1.png @juanrossi @juanrossi @Gains http://i.imgur.com/uvLMiHP.png Nightmare Zone guide
      1 point
    3. Purchase using PayPal, OSRS GOLD, CRYPTO or OTHER Click here for your 2 hour free trial! Features Supports custom locations Supports banking Supports item selling Supports pack opening Supports world hopping Active customer support Gallery Click here for your 2 hour free trial!
      1 point
    4. Roma

      RQuester [50+ Quests]

      Supported Quests: 1. Animal Magnetism 21. Knight's Sword 40. The Tourist Trap 2. Biohazard 22. Lost City 41. The Golem 3. Big Chompy Bird Hunting 23. Mountain Daughter 42. The Gnome Village 4. Client Of Kourend 24. Nature Spirit 43. Tutorial Island (Old) 5. Cook's Assistant 25. Plague City 44. Tutorial Island (New) 6. Death Plateau 26. Priest In Peril 45. Vampire Slayer 7. Demon Slayer 27. Prince Ali Rescue 46. Waterfall 8. Doric's Quest 28. RFD: Cook 47. Witch's House 9. Dragon Slayer 29. RFD: Evil Dave 48. Witch's Potion 10. Druidic Ritual 30. RFD: Dwarf 49. Miniquest: Varrock Museum Quiz 11. Dwarf Cannon 31. RFD: Goblin 50. Miniquest: Barcrawl 12. Eagle's Peak 32. RFD: Ogre 13. Ernest The Chicken 33. RFD: Pirate Pete 14. Fight Arena 34. Romeo & Juliet 15. Fishing Contest 35. Rune Mysteries 16. Gertrude's Cat 36. Sheep Shearer 17. Goblin Diplomacy 37. The Grand Tree 18. Imp Catcher 38. Shadow Of The Storm 19. Jungle Potion 39. The Restless Ghost You can modify the way the bot is grabbing the prices by editing the "rquester prices" file in your dreambot/scripts folder. Instructions can be found within the file. *Dragon slayer - melee only. *TGT, Fight arena - safe spot only. Case sensitive Profile name Example: java -Xmx512M -jar -Xbootclasspath/p:/YOUR_USER_PATH/DreamBot/BotData/client.jar /YOUR_USER_PATH/DreamBot/BotData/client.jar -username "forumsname" -password "forumspw" -account "savedacc1" -script "RQuester" -params "myprofilename"
      1 point
    5. Purchase using PayPal, OSRS GOLD, CRYPTO or OTHER Features Supports any bank location Supports mixing almost any items together Supports task system Active customer support
      1 point
    6. Purchase using PayPal, OSRS GOLD, CRYPTO or OTHER Click here for your 2 hour free trial! Features Supports Air, Mind, Water, Earth, Body, Fire and Nature runes Supports teleportation for some runes Supports essence runners Supports automated crafter to use with runners You can accept trades legit and let bots bring essence to you Active customer support Gallery Click here for your 2 hour free trial!
      1 point
    7. Automating the Install and Setup Process of DreamBot Thought I would throw a quick tutorial together about the approach I am taking to automatically install/setup/start the initial instance(s) of DreamBot for my newest farm. One major concern with my newest farm was time spent actually setting up VMs and bots. My previous farms all closed up shop eventually due to horrible time management on my part. So I am a major proponent for automation of repetitive task. I personally am using Docker instances and have scripts similar to the ones I have posted below run on creation of the docker instance so the farm is ready to go the moment I sign into the docker instance. *** Disclaimer *** Not saying this is the best way to do it, this is just what I ended up botching together to save me 10 minutes each time I spool a new instance up. What's it do tho? This will vary depending on your setup but the base command I will be showing will download the DreamBot launcher (DBLauncher.jar), run the first time setup/update, kill this launcher instance, then startup your bot instance(s). This script is using the built in windows commands this could also be done in PowerShell, and for other operating systems that I might make guides for in the future but my primary botting environment uses Windows so Windows it is. Going to breakdown the script section by section then show an example put together. Creating a place to store my DreamBot things For consistency sake I store any data output such as screenshots, accounts, reports, heatmaps, spreadsheets etc in a folder on my desktop called "DreamBot" across all my VMs. This is where I also store bot client launchers because I currently use multiple clients. Just keeps everything contained and clean. mkdir %HOMEPATH%\Desktop\DreamBot && cd %HOMEPATH%\Desktop\DreamBot I create the DreamBot folder to store my shit in using the mkdir %HOMEPATH%\Desktop\DreamBot this command creates the folder on the VMs desktop. Using && to execute the following cd command to change directories to the directory I just created. Ez Pz. Downloading the DreamBot Launcher The DreamBot launcher can be downloaded from this link -> https://dreambot.org/DBLauncher.jar (This can be checked by clicking the download link in the forum header). We will be using cURL a tool built into Windows to allowing us to grab the DBLauncher.jar from DreamBots website. curl -O https://dreambot.org/DBLauncher.jar Please note that -O is an UPPERCASE O. Using the uppercase -O will automatically name the downloaded file its original name. While using a lowercase -o you will need to provide your own output name. I wasted a lot of time not noticing that while debugging my initial test runs of this. This will download DBLauncher.jar to whatever the current directory is pointed at (ideally the DreamBot folder on the desktop I just made). First Time Launch/Update and kill So now that we have DBLauncher.jar on our system we need to execute it so we can pull the latest client.jar and other DreamBot resources. Once this is done we can use QuickStart functionality to launch bot instances via CLI or a bot manager. We need to use the "start" command so that the launching of the DBLauncher.jar does not suspend our script. Without the start command the remaining commands will not be executed until DBLauncher.jar is manually closed. Using start will allow execution of the script to continue while DBLauncher.jar does its thing. start java -jar DBLauncher.jar We want to assure we give the DreamBot launcher enough time to complete its setup/updates so we will call the timeout command to wait a few seconds before we kill the launcher instance. The length of the timeout will vary depending on your setup so adjust it how you see fit. timeout 5 && taskkill /f /im java.exe Using the timeout command we can wait X amount of seconds I generally just do 5. Hopefully within those 5 seconds the DreamBot launcher did whatever it needs to do because we then kill java.exe shutting anything Java related down. (again with probably not the best way to do this but nothing should be running on my VMs at this point so just killing Java isn't going to hurt anything else). Initial setup is complete! At this point DreamBot is ready for botting! Anything after this point is just using DreamBots QuickStart feature to create bot instances. Not going to rewrite Nezz's entire QuickStart tutorial so just take a glance at his original thread its a great tool. Signing into the client with QuickStart Like I said not going to redo Nezz's entire QuickStart tutorial but thought I would throw in a simple example of signing into the client once the setup is complete so you can run the command and come back to a ready to go botting environment. java -jar %homepath%\DreamBot/BotData/client.jar -username yourOwnUsername -password yourOwnPassword If you look into QuickStart you can do a LOOOOOT of cool things with it. Super useful tool to abuse when you are trying to save as much time as you can running a farm. Full command! You can add a lot of extra functionality to a command or script like this such as pulling resources your farm might need if you throw them on a local web server and use cURL to transfer them to the VMs during the execution of the script. Again with there are probably sections of this that are sub-optimal or botched to all hell but it was simple and quick for me to throw together and will save me time in the future. mkdir %HOMEPATH%\Desktop\DreamBot && cd %HOMEPATH%\Desktop\DreamBot && curl -O https://dreambot.org/DBLauncher.jar && start java -jar DBLauncher.jar && timeout 5 && taskkill /f /im java.exe && java -jar %homepath%\DreamBot/BotData/client.jar -username yourOwnUsername -password yourOwnPassword Any questions/issues/suggestions just shoot me a message. I do plan on making a version of this for Linux as well because at some point I would like to go back to using Linux OS's for botting. I just had Windows server keys so I have been using them. If anyone does this differently I would love to hear how you guys do this. I start and kill docker instances a lot due to my servers being used for more than just botting so depending on resource consumption I might have to nuke some docker instances for a bit then spin them back up later or spin up new ones.
      1 point
    8. You should probably look more into how switch statements work. switch(getBank().contains(String itemName or int itemNumber, int Quantity)) { //check the contains() boolean method case true: //if true startGE(); //start GE Process break; case false: //if false continueScript(); //continue the task break; } Error: You can't switch a boolean Also, looking at your use of switch statements, you say that it's better for readability, but in the instances you show it seems much harder to read. switch(state) { // read what value state is set to case 1: //Buying state executeBuyer(): //method to start the buying process break; case 2: //Selling state executeSeller(); //method to start the selling process break; } In this usage a simple if-else would be more readable or at least an enum with a BUY and SELL case. For the executeSeller/executeBuyer method, just have some if elses for the method for readability sake and overall logic of the script. As with the current logic you're ignoring whether one is not true and going onto the next. So you know that the character is not at the Grand Exchange and are currently walking towards it and you're going to ask: "do you have coins?", "even though the Grand Exchange is not open and you're not near it, is the buy screen open?", "Going to attempt to buy items and will return false as the bank is not open", etc. So pretty much just use if-else and else-ifs for some of the logic.
      1 point
    ×
    ×
    • 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.