Rolisteam/DiceParser

Savage Worlds !1dX;1d6mK1

ganzuul opened this issue · 7 comments

In Savage Worlds you roll a 'Wild Die' of 1d6 in addition to your skill die and keep the highest. It is also important to keep track of critical failures; if both die come up 1.

In the discord bot !1dX;1d6mK1 does not seem to work, or there is no way of telling which die came up lower. Is there something obvious I am overlooking?

Let's try this command:

!1d8;1d6;[$1,$2]k1;"Score: $3 - Rolled: [@1, @2]"

It should be the thing you want.


Alternatively, you may try this:

!1d8;1d6;[$1,$2]k1;$1*$2;$4i:[=1]{"Critical failure [@1,@2]"}{"Score $3 - details [@1,@2]"}

Thank you. but it doesn't seem to work with explode-and-keep though. Is there a bug?

!1d8e8;1d6e6;[$1,$2]k1;$1*$2;$4i:[=1]{"Critical failure [@1,@2]"}{"Score $3 - details [@1,@2]"}

Oooh!

Thank you! :D

If you need to create a macro in order to type a short text:

Define macro

!macro add ([0-9]+)S "1d\1e\1;1d6e6;[$1,$2]k1;$1*$2;$4i:[=1]{\"Critical failure [@1,@2]\"}{\"Score $3 - details [@1,@2]\"}" True

use it

!8S

It will run this !1d8e8;1d6e6;[$1,$2]k1;$1*$2;$4i:[=1]{"Critical failure [@1,@2]"}{"Score $3 - details [@1,@2]"}

hmmmm... if i write:

!1d8e8;1d6e6;[$1,$2]k1;$1*$2;$4i:[=1]{"Critical failure [@1,@2]"}{"Score $3 - details [@1,@2]"}

it runs as it should (example output)

Score 18 - details [18 [8,8,2],1]

but if i do

!macro add ([0-9]+)S "1d\1e\1;1d6e6;[$1,$2]k1;$1*$2;$4i:[=1]{"Critical failure [@1,@2]"}{"Score $3 - details [@1,@2]"}" True

then if i run

!8S

it returns

No valid value at index: $3

what did i do wrong?

The macro definition command has changed. It is no longer needed to put the command part inside quote.

!macro add ([0-9]+)S 1d\1e\1;1d6e6;[$1,$2]k1;$1*$2;$4i:[=1]{"Critical failure [@1,@2]"}{"Score $3 - details [@1,@2]"} True

image