dicebot


dice is a bot which I run on the official xkcd IRC channel, intended as a spiritual successor to flyingferret. (Note: dice's pronouns are canonically "she/her" or "they/them".)

Dice rolling

As the name suggests, you can generate random numbers with /me rolls XdY in channel, where X and Y are positive decimal integers and X is between zero and twenty. If X is not specified, it defaults to one. (Y is not bounded, but please try to avoid being spammy with this.)

* multiplexd rolls 8d5+3 
<dice> multiplexd got: 2, 1, 4, 1, 1, 4, 4, 5, for a total of 22+3=25

You can also tell dice to only take the highest or lowest n dice from a roll (yes, you can use dice to create your Dungeons & Dragons characters now).

* Kalium rolls 4d6h3
<dice> Kalium got: 5, 5, 3, 6; taking highest 3 gives 16

(For those who are interested, dice's regex for parsing dice rolls is (\d+)?d(\d+)([hl]\d+)?([+-]\d+)?)

Making choices

You can ask dice to decide between two or more options, separated by the word "or". You can optionally prepend the options with the word "choose", append a question mark, or both.

<multiplexd> dice: choose apples or oranges 
<dice> apples

<Kalium> dice: oranges or bananas?
<dice> bananas

Yes/no questions

If you address dice with a line which ends in a question mark, and which doesn't contain the word "or", then dice will treat it as a yes/no question, and give an answer (though no guarantee can be made about the usefulness of this answer).

<multiplexd> dice: are my documentation page examples silly? 
<dice> Yeah...


home