July 12, 201510 yr NEW TITE: Are you interested to work with me? Al Kharid Warrior Hello i am working on my Al kharid warrior bot but i need someone who knows how to use STATES and making a form where you can type food you would like to eat and get from bank. Right now my bot is a bit slower then kwarrior and i would like to improve that My bot can: Attack Warrior Open doors if there is a warrior inside. Show info about Time,Xp and so on... I Wish to: Go to Bank for food Having a form for the kind of food you would like to get in bank Faster or as fast as Kwarrior Edited July 12, 201510 yr by hajar424
July 12, 201510 yr So are you asking for someone to do the work for you? Look up how to use window builder/whatever jframe builder you prefer. Check to see if a warrior is around, and if he is, check if he's reachable, and if he's not reachable open the nearest door. Look at pugs guide for learning paint, it's on the scripting help section, and I'm sure you can find a snippet on te scripting help forum for banking and walking a path.
July 12, 201510 yr For your GUI, look up JFrame. For states: public enum States { ATTACK, RUN, BANK }; public States getState() { if (....) { return States.ATTACK; } return States.RUN; } public void onLoop() throws InterruptedException { switch (getState()) { case ATTACK: //Attack //code break; case RUN: //Run //code break; // repeat etc } }
July 12, 201510 yr Author For your GUI, look up JFrame. For states: public enum States { ATTACK, RUN, BANK }; public States getState() { if (....) { return States.ATTACK; } return States.RUN; } public void onLoop() throws InterruptedException { switch (getState()) { case ATTACK: //Attack //code break; case RUN: //Run //code break; // repeat etc } } I have already made a STAT but i have to improve it, i am not so good at Java And i know JFrame i just dont know how to start with adding a button and implement it to my bot. What i need is someone who have time to just show me how to begin Edited July 12, 201510 yr by hajar424
July 12, 201510 yr I have already made a STAT but i have to improve it, i am not so good at Java And i know JFrame i just dont know how to start with adding a button Just about every IDE has a form designer, so you can drag and drop buttons. Just look up "JFrame add components" or something
July 12, 201510 yr Author Just about every IDE has a form designer, so you can drag and drop buttons. Just look up "JFrame add components" or something i have used JFrame alot but the problem is how do i start.. Edited July 12, 201510 yr by hajar424
July 12, 201510 yr i have used JFrame alot but the problem is how do i start.. You make the JFrame class, and then in the designer you literally drop the components you want on to the form. It's not that hard dude.
July 12, 201510 yr for GUI aka form its simple create a seperate class just for GUI which extends JFrame public class GUI extends JFrame { //fields go here //constructor public GUI() { } } ////on main script class in start method envoke the GUI class
July 20, 201510 yr An alternative to using a built in form designer is also creating your GUI from scratch using Java Swing components. Doing it this way allows a lot of room for customization, design, and teaches you how to build a Java Swing GUI. Look up "A visual guide to Swing Components" for reference/tuts
Create an account or sign in to comment