@yipe/dice 0.2.5 → 0.2.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/builder/index.cjs
CHANGED
|
@@ -2785,7 +2785,17 @@ var RollBuilder = class _RollBuilder {
|
|
|
2785
2785
|
case "flat":
|
|
2786
2786
|
if (config.keep) {
|
|
2787
2787
|
const mode = config.keep.mode === "highest" ? "kh" : "kl";
|
|
2788
|
-
|
|
2788
|
+
const baseDieExpression = this.configToSingleExpressionWithoutModifier(
|
|
2789
|
+
{
|
|
2790
|
+
...config,
|
|
2791
|
+
count: config.count,
|
|
2792
|
+
modifier: 0,
|
|
2793
|
+
rollType: "flat",
|
|
2794
|
+
keep: void 0
|
|
2795
|
+
},
|
|
2796
|
+
false
|
|
2797
|
+
);
|
|
2798
|
+
mainExpression = `${config.keep.total}${mode}${config.keep.count}(${baseDieExpression})`;
|
|
2789
2799
|
} else {
|
|
2790
2800
|
const isComplex = baseDie.length > `d${config.sides}`.length;
|
|
2791
2801
|
const isHalflingShorthand = baseDie === "hd20";
|