Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public static void output(String text)
- {
- System.out.println(text);
- }
- public static void BotAppletInit()
- {
- isApplet = true;
- setLoadingText("Bot is starting up...");
- runBot();
- }
- public static void setLoadingText(String text)
- {
- if(isApplet)
- BotApplet.statusText.setText(text);
- }
- public static void appletStop()
- {
- if(Active)
- StopBot();
- }
- public static void main(String args[])
- {
- for(int i = 0; i < args.length; i++)
- {
- String arg = args[i];
- }
- runBot();
- }
- public static void runBot()
- {
- NewBotGUI.createAndShowGUI();
- botGUI = new BotGUI();
- BotGUI _tmp = botGUI;
- BotGUI.displayGUI();
- do
- try
- {
- if(Active)
- {
- ClientHandler _tmp2 = clientHandler;
- ClientHandler.Process();
- }
- Thread.sleep(500L);
- }
- catch(InterruptedException ex) { }
- while(true);
- }
- public static void processCommand(String Command)
- {
- String CommandL = Command.toLowerCase();
- if(CommandL.startsWith("say "))
- {
- String textToSay = Command.substring(4);
- ClientHandler.allClientsSay(textToSay);
- }
- if(CommandL.startsWith("yell "))
- {
- String textToSay = Command.substring(5);
- ClientHandler.allClientsYell(textToSay);
- }
- if(CommandL.startsWith("command "))
- {
- String theCommand = Command.substring(8);
- ClientHandler.allClientsCommand(theCommand);
- }
- if(CommandL.startsWith("ab "))
- {
- String abID = Command.substring(3);
- ClientHandler.actionButton(abID);
- }
- if(CommandL.startsWith("bb "))
- {
- String boneID = Command.substring(3, 7);
- String boneSlot = Command.substring(8);
- ClientHandler.buryBones(boneID, boneSlot);
- }
- if(CommandL.startsWith("click"))
- {
- ClientHandler.sendMouseClick();
- }
- if(CommandL.startsWith("atobject "))
- {
- String objectID = Command.substring(9, 13);
- String objectY = Command.substring(14, 18);
- String objectX = Command.substring(19);
- System.out.println(objectID + " " + objectY + " " + objectX);
- ClientHandler.atObject(objectID, objectY, objectX);
- }
- if(CommandL.startsWith("atobject2 "))
- {
- String objectID = Command.substring(10, 14);
- String objectY = Command.substring(15, 19);
- String objectX = Command.substring(20);
- System.out.println(objectID + " " + objectY + " " + objectX);
- ClientHandler.atObject2(objectID, objectY, objectX);
- }
- if(CommandL.startsWith("depositall "))
- {
- String itemSlot = Command.substring(16);
- String itemID = Command.substring(11, 15);
- ClientHandler.depositAll(itemSlot, itemID);
- }
- if(CommandL.startsWith("withdrawall "))
- {
- String itemSlot = Command.substring(17);
- String itemID = Command.substring(12, 16);
- ClientHandler.withdrawAll(itemSlot, itemID);
- }
- if(CommandL.startsWith("drop "))
- {
- String dropID = Command.substring(5, 9);
- String dropSlot = Command.substring(10);
- System.out.println("Drop: " + dropID + " Slot: " + dropSlot);
- ClientHandler.dropItem(dropSlot, dropID);
- }
- }
Add Comment
Please, Sign In to add comment