Shorter dice format.

This commit is contained in:
Mayhem 2013-08-10 15:05:44 +02:00
parent 6f6c1be3b1
commit a12d50981b

View File

@ -8,4 +8,4 @@ Dice =
return if @isClone or not dicestats = @info.email?.match /dice[+\s](\d+)d(\d+)/
# Use the text node directly, as the <b> has two <br>.
roll = $('b', @nodes.comment).firstChild
roll.data = "Rolled #{dicestats[1]}d#{dicestats[2]} and got #{roll.data.slice 7}"
roll.data = "Rolled #{dicestats[1]}d#{dicestats[2]}: #{roll.data.slice 7}"