Hi all, I'm working on a Cribbage game (and have been for a while now!). I've got the majority of the game logic done, but what's really frustrating me is the GUI. I'm using Swing (probably not very well), and I'm not sure what the best way is for the user to click on cards - such as for discarding, playing a card during the "pegging" phase, etc.
Currently, I've got a very crude GUI that displays the players cards with a JRadioButton underneath each card. The user clicks the radiobuttons of the cards he/she wants to discard, then clicks a "discard" button. This works, but it looks a little amateurish. I've seen other card games where if you click the card, it actually moves. (some type of animation, I guess?) I'd even settle for the ability to just click the card and have the card "highlighted" in some fashion before clicking the discard button, rather than using radio buttons for the selection process.
Is there a class or classes in the Java library that I should take a peek at for this type of thing, or is there no easy way to do this?
I'm open to any suggestions!! thanks!
Currently, I've got a very crude GUI that displays the players cards with a JRadioButton underneath each card. The user clicks the radiobuttons of the cards he/she wants to discard, then clicks a "discard" button. This works, but it looks a little amateurish. I've seen other card games where if you click the card, it actually moves. (some type of animation, I guess?) I'd even settle for the ability to just click the card and have the card "highlighted" in some fashion before clicking the discard button, rather than using radio buttons for the selection process.
Is there a class or classes in the Java library that I should take a peek at for this type of thing, or is there no easy way to do this?
I'm open to any suggestions!! thanks!