The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Games::Die - Program that simulates ADVANCED die rolls using a grammar.

VERSION

version 0.1

SYNOPSIS

To roll a six sided dice

roll 'd6'

rolls three six faces dices and adds 3

roll '3d6+3'

rolls four six faces dices and remove the lowest one

roll '4d{1}6'

(Note. This is useful for D&D player character generator)

roll '1d4;1d6'

returns two dice result in a string separated by ';' (It may change in future, it may return a different structure)

roll 'd6x2'

returns two different result of a d6 separated by '\n' (It may change in future, it may return a different structure)

i.e. "2\n4"

METHODS

roll

This method return result of specified dice.

AUTHOR

Valerio Crini <vcrini@gmail.com>

COPYRIGHT AND LICENSE

This software is copyright (c) 2010 by Valerio Crini.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.