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
  • [OPEN SOURCE] CLI Bot Manager by Xerifios


    Xerifios

    Recommended Posts

    I finished my CLI Bot Manager. This will do just like it sounds what it does. It uses the CLI of DreamBot and runs 1 bot/client. This does not work with scripts that use parameters. Scroll below for the source code. If you'd like to help out on this project just post snippets below :).

     

    Features:

    - Runs your bots with ease

    - Can fill in an infinite amount of bots

     

    Planned features:

    - Randomized Worlds split by F2P and P2P.

    - More slick UI.

    - Adding parameters.

     

    How to use:

    - Download the Jar file: http://www.mediafire.com/file/ase49uydk4xqtah/CLIManager.jar

    - Open the jar file something like this will Pop up

    59345972e3bcec1724a37803b22f5c39.png

    - Fill in the fields. Your bot account name, password, pin (if no pin just type 0000), world and script. Example below

    c430b1a3f190881c5857a889a5741411.png NOTE: The script may not contain spacing also make sure you spell it correctly.

     

    - Now press "Add Bot". The fields will be empty again and where you see "Bots added: " there will be the amount of bots added. Example below

    e55fe69b067f36647f4f3937e7bb81bf.gif

     

    - Now press "Add jar file". To do this step correctly you will go to the DreamBot client.jar file. Follow the GIF below.

    9cae95d03749d6d5887a2e5fbebc0c70.gif

    1a6ca6ee786414679083c5dd4c7f6a8d.gif

     

    - Now you can press Start and notice the magic happen as your client will start.

     

    SOURCE

     

    Main class:

    import javax.swing.*;
    import java.awt.*;
    import java.awt.event.ActionEvent;
    import java.awt.event.ActionListener;
    import java.io.*;
    import java.util.ArrayList;
    import java.util.List;
    
    public class CLIManager {
    private JPanel panelMain;
    private JButton buttonStart;
    private JTabbedPane tabbedPane1;
    private JTextField username;
    private JTextField password;
    private JTextField pin;
    private JTextField world;
    private JTextField scriptBox;
    private JFileChooser browse;
    private JButton addAccount;
    private JLabel bots;
    private JButton addJarFileButton;
    public List<String> cmdList = new ArrayList<>();
    public Process process;
    List<String> bUsername = new ArrayList<>();
    List<String> bPassword = new ArrayList<>();
    List<String> bPin = new ArrayList<>();
    List<String> bWorld = new ArrayList<>();
    List<String> bScript = new ArrayList<>();
    String user;
    String pass;
    String dir;
    String p;
    String w;
    String script;
    int botAmount;
    
    public CLIManager() {
    buttonStart.addActionListener(new ActionListener() {
    @Override
    public void actionPerformed(ActionEvent e) {
    for(int i = 0; i < bUsername.size(); i++){
    cmdList.add("java");
    cmdList.add("-jar");
    cmdList.add(dir);
    cmdList.add("-script");
    cmdList.add(bScript.get(i));
    cmdList.add("-world");
    cmdList.add(bWorld.get(i));
    cmdList.add("-accountUsernames");
    cmdList.add(bUsername.get(i));
    cmdList.add("-accountPasswords");
    cmdList.add(bPassword.get(i));
    
    try {
    ProcessBuilder processBuilder = new ProcessBuilder(cmdList);
    processBuilder.redirectErrorStream(true);
    process = processBuilder.start();
    } catch (IOException d) {
    d.printStackTrace();
    }
    }
    }
    });
    addAccount.addActionListener(new ActionListener() {
    @Override
    public void actionPerformed(ActionEvent e) {
    user = username.getText();
    pass = password.getText();
    p = pin.getText();
    w = world.getText();
    script = scriptBox.getText();
    
    if (username.getText().isEmpty())
    JOptionPane.showMessageDialog(new Frame(), "Fill in the username");
    if (password.getText().isEmpty())
    JOptionPane.showMessageDialog(new Frame(), "Fill in the password");
    if(pin.getText().isEmpty())
    JOptionPane.showMessageDialog(new Frame(), "Fill in the pin, if none type in 0000");
    if(world.getText().isEmpty())
    JOptionPane.showMessageDialog(new Frame(), "Fill in a world, random feature will be added later");
    if(scriptBox.getText().isEmpty())
    JOptionPane.showMessageDialog(new Frame(), "Fill in the script name");
    if(!username.getText().isEmpty() && !password.getText().isEmpty() && !pin.getText().isEmpty() && !world.getText().isEmpty() && !scriptBox.getText().isEmpty()){
    bUsername.add(user);
    bPassword.add(pass);
    bPin.add(p);
    bWorld.add(w);
    bScript.add(script);
    botAmount++;
    bots.setText("Bots added: " + String.valueOf(botAmount));
    
    username.setText("");
    password.setText("");
    pin.setText("");
    world.setText("");
    scriptBox.setText("");
    
    user = "";
    pass = "";
    p = "";
    w = "";
    script = "";
    }
    }
    });
    addJarFileButton.addActionListener(new ActionListener() {
    @Override
    public void actionPerformed(ActionEvent e) {
    browse = new JFileChooser();
    browse.showOpenDialog(panelMain);
    // browse.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY);
    File url = browse.getSelectedFile();
    dir = url.toString();
    System.out.println(dir);
    }
    });
    }
    public static void main(String[] args){
    JFrame frame = new JFrame();
    frame.setContentPane(new CLIManager().panelMain);
    frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    frame.pack();
    frame.setVisible(true);
    }
    }
    

    GUI Form:

    <?xml version="1.0" encoding="UTF-8"?>
    <form xmlns="http://www.intellij.com/uidesigner/form/" version="1" bind-to-class="CLIManager">
    <grid id="27dc6" binding="panelMain" layout-manager="GridLayoutManager" row-count="2" column-count="1" same-size-horizontally="false" same-size-vertically="false" hgap="-1" vgap="-1">
    <margin top="0" left="0" bottom="0" right="0"/>
    <constraints>
    <xy x="20" y="20" width="800" height="250"/>
    </constraints>
    <properties>
    <background color="-15587775"/>
    <foreground color="-15587775"/>
    <minimumSize width="800" height="250"/>
    <preferredSize width="800" height="250"/>
    </properties>
    <border type="none">
    <title-color color="-4473925"/>
    </border>
    <children>
    <tabbedpane id="f32c" binding="tabbedPane1" default-binding="true">
    <constraints>
    <grid row="0" column="0" row-span="1" col-span="1" vsize-policy="3" hsize-policy="3" anchor="0" fill="3" indent="0" use-parent-layout="false">
    <preferred-size width="200" height="200"/>
    </grid>
    </constraints>
    <properties>
    <autoscrolls value="false"/>
    <background color="-15587775"/>
    <foreground color="-1"/>
    </properties>
    <border type="none"/>
    <children>
    <grid id="28715" layout-manager="GridLayoutManager" row-count="3" column-count="4" same-size-horizontally="false" same-size-vertically="false" hgap="-1" vgap="-1">
    <margin top="0" left="0" bottom="0" right="0"/>
    <constraints>
    <tabbedpane title="Accounts"/>
    </constraints>
    <properties>
    <background color="-15587775"/>
    </properties>
    <border type="none"/>
    <children>
    <grid id="a47c8" layout-manager="GridLayoutManager" row-count="2" column-count="5" same-size-horizontally="false" same-size-vertically="false" hgap="-1" vgap="-1">
    <margin top="0" left="0" bottom="0" right="0"/>
    <constraints>
    <grid row="0" column="0" row-span="1" col-span="4" vsize-policy="3" hsize-policy="3" anchor="1" fill="1" indent="0" use-parent-layout="false"/>
    </constraints>
    <properties>
    <background color="-15587775"/>
    </properties>
    <border type="none"/>
    <children>
    <component id="20816" class="javax.swing.JLabel">
    <constraints>
    <grid row="0" column="0" row-span="1" col-span="1" vsize-policy="0" hsize-policy="0" anchor="8" fill="0" indent="0" use-parent-layout="false">
    <preferred-size width="101" height="16"/>
    </grid>
    </constraints>
    <properties>
    <foreground color="-5"/>
    <text value="Bot Username"/>
    </properties>
    </component>
    <component id="79ec9" class="javax.swing.JLabel">
    <constraints>
    <grid row="0" column="1" row-span="1" col-span="1" vsize-policy="0" hsize-policy="0" anchor="8" fill="0" indent="0" use-parent-layout="false"/>
    </constraints>
    <properties>
    <foreground color="-1"/>
    <text value="Bot Password"/>
    </properties>
    </component>
    <component id="18074" class="javax.swing.JLabel">
    <constraints>
    <grid row="0" column="2" row-span="1" col-span="1" vsize-policy="0" hsize-policy="0" anchor="8" fill="0" indent="0" use-parent-layout="false"/>
    </constraints>
    <properties>
    <foreground color="-1"/>
    <text value="Bot Pin"/>
    </properties>
    </component>
    <component id="d5a12" class="javax.swing.JLabel">
    <constraints>
    <grid row="0" column="3" row-span="1" col-span="1" vsize-policy="0" hsize-policy="0" anchor="8" fill="0" indent="0" use-parent-layout="false">
    <preferred-size width="98" height="16"/>
    </grid>
    </constraints>
    <properties>
    <foreground color="-1"/>
    <text value="World"/>
    </properties>
    </component>
    <component id="b15c7" class="javax.swing.JTextField" binding="username">
    <constraints>
    <grid row="1" column="0" row-span="1" col-span="1" vsize-policy="0" hsize-policy="6" anchor="9" fill="1" indent="0" use-parent-layout="false">
    <preferred-size width="101" height="24"/>
    </grid>
    </constraints>
    <properties>
    <foreground color="-16777216"/>
    </properties>
    </component>
    <component id="da55" class="javax.swing.JTextField" binding="pin">
    <constraints>
    <grid row="1" column="2" row-span="1" col-span="1" vsize-policy="0" hsize-policy="6" anchor="9" fill="1" indent="0" use-parent-layout="false">
    <preferred-size width="150" height="-1"/>
    </grid>
    </constraints>
    <properties>
    <foreground color="-16777216"/>
    </properties>
    </component>
    <component id="1f323" class="javax.swing.JTextField" binding="world">
    <constraints>
    <grid row="1" column="3" row-span="1" col-span="1" vsize-policy="0" hsize-policy="6" anchor="9" fill="1" indent="0" use-parent-layout="false">
    <preferred-size width="98" height="24"/>
    </grid>
    </constraints>
    <properties>
    <foreground color="-16777216"/>
    </properties>
    </component>
    <component id="be36f" class="javax.swing.JLabel">
    <constraints>
    <grid row="0" column="4" row-span="1" col-span="1" vsize-policy="0" hsize-policy="0" anchor="8" fill="0" indent="0" use-parent-layout="false"/>
    </constraints>
    <properties>
    <foreground color="-1"/>
    <text value="Script"/>
    </properties>
    </component>
    <component id="7d9a3" class="javax.swing.JTextField" binding="scriptBox">
    <constraints>
    <grid row="1" column="4" row-span="1" col-span="1" vsize-policy="0" hsize-policy="6" anchor="8" fill="1" indent="0" use-parent-layout="false">
    <preferred-size width="150" height="-1"/>
    </grid>
    </constraints>
    <properties/>
    </component>
    <component id="b4e9b" class="javax.swing.JTextField" binding="password">
    <constraints>
    <grid row="1" column="1" row-span="1" col-span="1" vsize-policy="0" hsize-policy="6" anchor="8" fill="1" indent="0" use-parent-layout="false">
    <preferred-size width="150" height="-1"/>
    </grid>
    </constraints>
    <properties>
    <foreground color="-16777216"/>
    </properties>
    </component>
    </children>
    </grid>
    <component id="9dd86" class="javax.swing.JButton" binding="addAccount">
    <constraints>
    <grid row="2" column="1" row-span="1" col-span="3" vsize-policy="3" hsize-policy="3" anchor="0" fill="0" indent="0" use-parent-layout="false">
    <minimum-size width="100" height="50"/>
    <preferred-size width="100" height="50"/>
    <maximum-size width="100" height="50"/>
    </grid>
    </constraints>
    <properties>
    <actionCommand value="Button"/>
    <background color="-12566210"/>
    <foreground color="-1"/>
    <label value="Add Bot"/>
    <text value="Add Bot"/>
    </properties>
    </component>
    <component id="e592a" class="javax.swing.JLabel" binding="bots">
    <constraints>
    <grid row="1" column="0" row-span="1" col-span="2" vsize-policy="0" hsize-policy="0" anchor="8" fill="0" indent="0" use-parent-layout="false"/>
    </constraints>
    <properties>
    <foreground color="-1"/>
    <labelFor value=""/>
    <name value="accLabel"/>
    <text value="Bots added:"/>
    </properties>
    </component>
    <component id="87b06" class="javax.swing.JButton" binding="addJarFileButton" default-binding="true">
    <constraints>
    <grid row="2" column="0" row-span="1" col-span="1" vsize-policy="0" hsize-policy="3" anchor="0" fill="0" indent="0" use-parent-layout="false">
    <preferred-size width="20" height="20"/>
    </grid>
    </constraints>
    <properties>
    <text value="Add jar file"/>
    </properties>
    </component>
    </children>
    </grid>
    </children>
    </tabbedpane>
    <component id="4de75" class="javax.swing.JButton" binding="buttonStart">
    <constraints>
    <grid row="1" column="0" row-span="1" col-span="1" vsize-policy="0" hsize-policy="0" anchor="0" fill="2" indent="0" use-parent-layout="false">
    <minimum-size width="200" height="50"/>
    <preferred-size width="200" height="50"/>
    <maximum-size width="200" height="100"/>
    </grid>
    </constraints>
    <properties>
    <actionCommand value="Button"/>
    <background color="-12566210"/>
    <borderPainted value="false"/>
    <foreground color="-1"/>
    <label value="Start"/>
    <text value="Start"/>
    </properties>
    </component>
    </children>
    </grid>
    </form>
    
    
    

     

     

    Link to comment
    Share on other sites

    Not bad, gonna try it out sometime, well done !

    If you encounter a problem hit me up on this thread also forgot to add proxy support will update tomorrow 

    Link to comment
    Share on other sites

    What benefit do I get from using this since quickstart does almost the exact same thing?

    This is for those who do have trouble setting up Quickstart and this saves you from needing to make extra bat files for your accounts

    Link to comment
    Share on other sites

    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.