diff options
Diffstat (limited to 'src/dice.rs')
-rw-r--r-- | src/dice.rs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/dice.rs b/src/dice.rs index 1293a6f..ffec3b8 100644 --- a/src/dice.rs +++ b/src/dice.rs @@ -38,7 +38,10 @@ impl RollResult { impl fmt::Display for RollResult { fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { - write!(f, "{}", self.total()) + write!(f, "{} ({})", self.total(), self.rolls.iter() + .map(|dr| dr.face.to_string()) + .collect::<Vec<String>>() + .join(", ")) } } |