Jump to content

OSBot GUI User Input


Stando

Recommended Posts

Hello everyone.

Stando here. I am looking for someone to assist me/give me a tutorial in allowing user input for a GUI. I would like this GUI to accept any monster id so the user will automatically attack the monster. I know how to do this with JCombobox, but not with JTextField. Would anyone with this sort of knowledge be able to assist me?

Link to comment
Share on other sites

7 hours ago, BravoTaco said:

If you are not needing an entire GUI, you could use the JOptionPane class, it allows you to bring up a modal input dialog box with just one line of code.

 

String monsterID = JOptionPane.showInputDialog("Please enter the monster ID.");

Wow, this seems like a good idea. I am going to test this line and see how it looks within the GUI.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...