Dexter Bots 25 Share Posted May 16 (edited) Hi! I've put some thought into how we can quickly get farming accounts up and running, so I decided to share the code with you. The script opens a window where you can add all accounts as a list, as shown in the Quickstart/CLI tutorial. Each line corresponds to one account. Just click 'Run', and the scripts will start sequentially. However, be aware that they will all start immediately, depending on your GPU, CPU, and RAM performance. You might need to add a delayed line in the script to prevent crashing! import javax.swing.*; import java.awt.*; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.io.IOException; public class CommandRunner extends JFrame { private JTextArea commandArea; private JButton runButton; public CommandRunner() { System.out.println("Initializing UI"); setTitle("Command Runner"); setSize(600, 400); setDefaultCloseOperation(EXIT_ON_CLOSE); initUI(); System.out.println("UI initialized"); } private void initUI() { JPanel panel = new JPanel(new BorderLayout()); commandArea = new JTextArea(); JScrollPane scrollPane = new JScrollPane(commandArea); runButton = new JButton("Run"); runButton.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { runCommands(); } }); panel.add(scrollPane, BorderLayout.CENTER); panel.add(runButton, BorderLayout.SOUTH); setLocationRelativeTo(null); // Zentriert das Fenster auf dem Bildschirm setAlwaysOnTop(true); // Stellt das Fenster immer oben dar add(panel); } private void runCommands() { String[] commands = commandArea.getText().split("\n"); for (String command : commands) { try { // Start each command in a separate CMD window Runtime.getRuntime().exec("cmd /c start cmd.exe /K \"" + command + "\""); } catch (IOException ex) { ex.printStackTrace(); JOptionPane.showMessageDialog(this, "Fehler beim Ausführen des Befehls: " + command, "Fehler", JOptionPane.ERROR_MESSAGE); } } } public static void main(String[] args) { try { CommandRunner frame = new CommandRunner(); frame.setVisible(true); } catch (Exception e) { e.printStackTrace(); } } } Edited May 17 by Dexter Bots YUNGTHUGFATGP, Hashtag and Aeglen 2 1 Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now