Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dNxN ? #29

Open
ericscheid opened this issue May 11, 2022 · 3 comments
Open

dNxN ? #29

ericscheid opened this issue May 11, 2022 · 3 comments

Comments

@ericscheid
Copy link

I've seen an odd syntax in some indie games, being dNxN, like d6x6 or d4x8. (Sometimes also written as d66, which is syntacally ambiguous).

The way this syntax works is that it rolls two dice and then concatenates them, producing results like 11, 12, 13, 14, 21, 22, (etc) for d4x4. Thus d6x6 produces 36 results, usually presented as a list (and not a 6 by 6 matrix).

It's more a way of generating an index into a table, and less of generating a numerical value. (So, unlikely/unable to have any further modifies like +4 or kh etc). I would recommend using x (and ×) as the syntax symbol and not *, since we'd want to continue supporting 3d6*10 expressions.

Of course, with purely digital generation one might as well write d36 and be done .. unless one needs to reference existing resources that were written with the assumption of rolling actual dice.

@ericscheid
Copy link
Author

I have no pressing need for this, but thought it'd be an interesting addition.

@lordnull
Copy link
Owner

lordnull commented Oct 6, 2022

Sorry for the late response. You do point out a difficulty where the list of results from dNxN is a list of tuples (essentially) rather than the list of integers the other two syntaxes (d and w). Essentially the syntax doesn't fit nicely with the rest of the language. Without introducing a bunch of other support for tuples or arrayed results, I'm not sure how well it would integrate in.

I'll leave it open for a bit and see if any ideas, either from myself, you, or the world at large, come up.

@ericscheid
Copy link
Author

Another possible syntax could be d6 & d6, with & being a concatenation operator.

Or finally d6*10 + d6 which produces results like 11, 12 ... 36, 41, etc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants