diff --git a/src/cljc/orcpub/dice.cljc b/src/cljc/orcpub/dice.cljc index ffd702c2b..9628f17e1 100644 --- a/src/cljc/orcpub/dice.cljc +++ b/src/cljc/orcpub/dice.cljc @@ -60,8 +60,8 @@ sides (or (parse-int sides-str)) plus-minus (if (= "-" plus-minus-str) -1 - 1) - raw-mod (or (parse-int mod-str) 0) + +1) + raw-mod (or (parse-int mod-str) +0) mod (* raw-mod plus-minus) rolls (roll-n num sides) total (apply + mod rolls)] diff --git a/src/cljs/orcpub/dnd/e5/views.cljs b/src/cljs/orcpub/dnd/e5/views.cljs index bb159849e..5155d6105 100644 --- a/src/cljs/orcpub/dnd/e5/views.cljs +++ b/src/cljs/orcpub/dnd/e5/views.cljs @@ -2239,7 +2239,7 @@ (if (boolean show-button) (roll-button (str title " check: ") - (str "1d20" v) + (str "1d20" (common/mod-str v)) :text v :style {:font-size "24px" :padding "2px 8px"}) v)]]]) @@ -2809,7 +2809,7 @@ [:td (roll-button (str name " attack: ") (str "1d20" (common/mod-str (weapon-attack-modifier weapon))) - :text (str "1d20" (common/bonus-str (weapon-attack-modifier weapon))))] + :text (str "1d20" (common/mod-str (weapon-attack-modifier weapon))))] [:td (roll-button (str name " damage: ") (str damage-die-count "d" damage-die (common/mod-str (weapon-damage-modifier weapon)))