From 46cb61e9f90a480b0277816ae8d42e5b0c91fe0c Mon Sep 17 00:00:00 2001 From: Renaud Guezennec Date: Sat, 25 Oct 2025 19:06:37 +0000 Subject: Update file HelpMe.md --- HelpMe.md | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/HelpMe.md b/HelpMe.md index a9786da..a3893c1 100644 --- a/HelpMe.md +++ b/HelpMe.md @@ -26,6 +26,7 @@ * [Spread](#spread) * [Unique](#unique) * [Comment](#comment) + * [Transform](#transform) * [Functions](#functions) * [Managing the output](#the-output) * [Shortcuts](#shortcuts) @@ -634,6 +635,27 @@ So DiceParser can answer the question: yes +### Transform + +Transform dice accordingly to a condition into another value. + +``` +5d10T[>5]{15} +``` +Roll 5 dice of 10 faces, then replace all values greater than 5 with 15 and the others with 0. + +> (6,9,7,5,2) => (15,15,15,5,2) + +This operator accepts several conditions: `T[=5]{15}[=6]{16}` + +> (6,9,7,5,2) => (16,9,7,15,2) + +You can also add a final expression to change the value of all dice which don't fit an condition: `T[>5]{15}{0}` + +> (6,9,7,5,2) => (15,15,15,0,0) + + + ## Functions DiceParser provides function to deal with instructions. -- cgit v1.2.3-70-g09d2