5punk BeardyRoller
Moderator: Forum Moderators
-
- Berk
- Posts: 10353
- Joined: December 7th, 2004, 17:02
- Location: Oklahoma City, OK, USA
- Contact:
5punk BeardyRoller
Download the latest version here: http://www.apathymachine.com/beardz/
Java GitHub respository here: https://github.com/deject/BeardyRoller
NOW IN C#/Windows Forms FLAVOR! If you hate Java Swing like I do, check out this version!
BeardyRoller! Sharp Edition v0.9b
-Equivalent functionality as Java version, but with more efficient and better written code!
-Java Swing is terrible and I wish it died!
Version 0.93:
- Fixed the lack of NaN handling for Shadowrun
- Added batch rolling/text output support
- Reorganized the code a bit so that it's easier to work with
Version 0.92:
- Changed layout to a tabbed pane
- Added support for Eclipse Phase RPG
- Cleaned up some comments
Version 0.91:
- BEARDZ! is now fixed for great justice!
Version 0.9:
- Added BEARDZ!
- Changed unecessary usage of ArrayList to int[] arrays
- Fixed About message
Version 0.85:
- Added notification when snake eyes are rolled in SLA
- Added menu bar
- Added informational About dialog
- Fixed window size so the GUI doesn't go pearshaped
Version 0.80:
- Initial Release
TODO:
- Add Warhammer 40,000 Death Watch RPG
Original post:
Well, the alpha version is done! The dice rolling code is piss easy of course and took me all of like 5 minutes to write code for any number of d6, d10, and d20 dice rolls.
Constructing the GUI for a a GUI noob like me is the hard part. I still have issues with it, most notably the Shadowrun sidelt: label gets pushed off if the dice pool rolled is fairly big (>5). Still, the basic layout is there and the functionality is all there. I can provide the source code (just the files or as an Eclipse project archive) to anyone if they so desire and.or can help with GUIs.
Old W-I-P demo video is here (not very informative anymore):
http://www.screencast.com/users/deject/ ... daa637bb87
Java GitHub respository here: https://github.com/deject/BeardyRoller
NOW IN C#/Windows Forms FLAVOR! If you hate Java Swing like I do, check out this version!
BeardyRoller! Sharp Edition v0.9b
-Equivalent functionality as Java version, but with more efficient and better written code!
-Java Swing is terrible and I wish it died!
Version 0.93:
- Fixed the lack of NaN handling for Shadowrun
- Added batch rolling/text output support
- Reorganized the code a bit so that it's easier to work with
Version 0.92:
- Changed layout to a tabbed pane
- Added support for Eclipse Phase RPG
- Cleaned up some comments
Version 0.91:
- BEARDZ! is now fixed for great justice!
Version 0.9:
- Added BEARDZ!
- Changed unecessary usage of ArrayList to int[] arrays
- Fixed About message
Version 0.85:
- Added notification when snake eyes are rolled in SLA
- Added menu bar
- Added informational About dialog
- Fixed window size so the GUI doesn't go pearshaped
Version 0.80:
- Initial Release
TODO:
- Add Warhammer 40,000 Death Watch RPG
Original post:
Well, the alpha version is done! The dice rolling code is piss easy of course and took me all of like 5 minutes to write code for any number of d6, d10, and d20 dice rolls.
Constructing the GUI for a a GUI noob like me is the hard part. I still have issues with it, most notably the Shadowrun sidelt: label gets pushed off if the dice pool rolled is fairly big (>5). Still, the basic layout is there and the functionality is all there. I can provide the source code (just the files or as an Eclipse project archive) to anyone if they so desire and.or can help with GUIs.
Old W-I-P demo video is here (not very informative anymore):
http://www.screencast.com/users/deject/ ... daa637bb87
Last edited by deject on January 22nd, 2012, 6:56, edited 11 times in total.
I'm not sure if there's a better way to do it but I usually just stick a load of spaces on the end of the smaller string to push the size of the text box to the length of the longer string. Try setting the initial value of the dice pool result box to alot of spaces.
Also, are you using grid layout for those two buttons? that's what I'd use, the overlapping after clicking thing is a bit strange.
Also, are you using grid layout for those two buttons? that's what I'd use, the overlapping after clicking thing is a bit strange.
-
- Throbbing Cupcake
- Posts: 10249
- Joined: February 17th, 2007, 23:05
- Location: The maleboge

You'll need edge modifiers on the shadowrun one. You could probably squash the whole thing up a bit and have more space for the stuff disappearing off the side too. I say probably, I don't know this because I'm no code monkey. Still, makes a lot more sense than that web based sr4 roller that is over at that dashifen place. I think he broke his, because it delivers terribly low results all the time now.
-
- Berk
- Posts: 10353
- Joined: December 7th, 2004, 17:02
- Location: Oklahoma City, OK, USA
- Contact:
Well it's more complex than that. Both sides are their own JPanels for compartmentalization. The overall layout is using BorderLayout, and then the subsequent panels use GridLayout to align everything vertically.Lee wrote:I'm not sure if there's a better way to do it but I usually just stick a load of spaces on the end of the smaller string to push the size of the text box to the length of the longer string. Try setting the initial value of the dice pool result box to alot of spaces.
Also, are you using grid layout for those two buttons? that's what I'd use, the overlapping after clicking thing is a bit strange.
I'm pretty sure what I need to do to solve the result problem is to change the layout for that bottom part because as it is now the text area and the result label are confined to being the same width, so I need to figure out how to stop that from happening. Once I do that it won't be a problem.
Oh and I forgot about Edge. I'll have to add that.
-
- Weighted Storage Cube
- Posts: 7167
- Joined: February 26th, 2007, 17:26
- Location: Middle England, nearish Cov
You could, although it's not "recommended" java programming ethos, is simply set the layoutcontrol to null then position everything manually.
It means that obviously, they won't resize or move around if you play with the size of the window at runtime, but by fuckery it means you don't have to dick around with the quite frankly badly thought out java layout code methods.
It means that obviously, they won't resize or move around if you play with the size of the window at runtime, but by fuckery it means you don't have to dick around with the quite frankly badly thought out java layout code methods.
-
- Berk
- Posts: 10353
- Joined: December 7th, 2004, 17:02
- Location: Oklahoma City, OK, USA
- Contact:
Yeah I am not going to position shit manually. That is just asking for pain.buzzmong wrote:You could, although it's not "recommended" java programming ethos, is simply set the layoutcontrol to null then position everything manually.
It means that obviously, they won't resize or move around if you play with the size of the window at runtime, but by fuckery it means you don't have to dick around with the quite frankly badly thought out java layout code methods.
I need to find more advanced tutorials online or something because I've got most of it set up. I expanded the box so it can handle 14 dice before fucking up. I know it's not the ideal way to handle this though.
-
- Berk
- Posts: 10353
- Joined: December 7th, 2004, 17:02
- Location: Oklahoma City, OK, USA
- Contact:
It's definitely a bug. I think it's not taking into account the extra dice from the Edge. I have to fix that, should be easy enough. I added in the Edge dice without changing anything else so that's not unexpected.Joose wrote:nicely!
Seems to have a bit of a bug regarding edge and glitches though: At one point a roll of 6, 6, 1 comes up glitch. Is it something to do with the fact it would have been a glitch, were it not for the extra edge dice?
-
- Berk
- Posts: 10353
- Joined: December 7th, 2004, 17:02
- Location: Oklahoma City, OK, USA
- Contact:
Right, I've fixed the glitch detection bug, and I have a rough version available for people to try. It's an executable .jar file. I'm certain my PC is 100% virus, trojan, and spyware free, but as always you should check out all executable stuff you run on your PC.
download it here:
http://www.apathymachine.com/BeardyRoller.jar
download it here:
http://www.apathymachine.com/BeardyRoller.jar
Java is evil. I've put one together in something a little more friendly.
http://www.mediafire.com/?sharekey=97ab ... f6e8ebb871
(Yes, you can crash it if you don't use it properly. No, I won't fix it
)
http://www.mediafire.com/?sharekey=97ab ... f6e8ebb871
(Yes, you can crash it if you don't use it properly. No, I won't fix it

-
- Berk
- Posts: 10353
- Joined: December 7th, 2004, 17:02
- Location: Oklahoma City, OK, USA
- Contact:
Java isn't evil btw, it's just misunderstood. I think all of the problems people have with Java is due to botched VM installs. I can honestly say I have not had a Java program fail or fuck up on me in years.
Edit I bet I could adapt my code to C# pretty easily. I should install Visual Studio and try it out.
Edit I bet I could adapt my code to C# pretty easily. I should install Visual Studio and try it out.
-
- Throbbing Cupcake
- Posts: 10249
- Joined: February 17th, 2007, 23:05
- Location: The maleboge