/AZDice

A tool of generating and viewing dice roll success distributions.

Primary LanguageRustGNU General Public License v3.0GPL-3.0

AZDice

A GUI tool for generating and visualising dice roll probability distributions.

Aims

Intended to help people trying to get game balance just right in homebrewed tabletop games.

Current State

CLI

The refactored original cli version is now up.

GUI

Uses conrod for a simple GUI that which can be used to enter an input and display a graphical output.

Supported Rolls

Generates roll distributions over a full range of bonuses. Eg for an opposed 1d20 vs 1d20 roll, the full range of meaningful relative bonuses is -20 to +20. Supports symmetrical roll distributions. (eg 3d6 vs 3d6 can be generates with "3d6 vs" or "3d6 vs 3d6", 1d100 vs 1d100 can be generated with "1d100 vs 1d100" or "d100 vs d100") Supports additive roll distributions. (eg 3d6+1d20 vs 3d6+1d20 can be generated with "3d6+1d20" or "3d6+1d20 vs 3d6+1d20") Supports asymmetrical rolls. (eg 3d6 vs 1d20 can be generated by "3d6 vs 1d20")

Now can also generate probability distributions for "non versus" rolls. Thus "3d20dl1dh1" will generate a simple probability distribution for "roll 3d20 drop the highest, drop the lowest" types of rolls.

The rolls are powered by libazdice. Thus the README for libazdice should be consulted for more detailed description of the supported roll functions.

Output

Creates a full .csv output file, for each unique distribution. Displays the generated distribution as a graph. Displays distribution in terminal window.

Distribution generation algorithm

Currently rolls virtual dice (using rand crate) lots of times. Then compares the answer.

ToDo

-Make an algebraic calculator to supplement the brute force statistical calculator.

Compiling

Compiles on rust 1.28.0 with cargo build --release --features="winit glium libc"

Compiles on rust 1.43.0 with cargo build or cargo build --release. NB: Lastest version is not compatible with older versions of rust.

Update 2018-10-24: Now builds on travis without doing silly things to conrod.

Update 2020-06-22: Now builds on travis again (did not build after incorporation of libazdice, possibly due to update to toolchain.)

Feedback

Please let me know why this sucks might suck and how it should be made better.