trocar-dice-js

1.0.1 • Public • Published

README

Trocar Dice

npm install trocar-dice-js

Usage:

import dice from 'trocar-dice-js';

console.log(dice.d20());

console.log(dice.dice(4,6));

Possible outputs:


5
[2,5]

Functions:

d2,d3,d4,d6,d8,d10,d12,d20,d100

These take no parameters and return a number from 1 to and including the number after d in the function name. These call the function "die" which takes a parameter of number of sides.

dice(sides, count)

This returns an array of roll results.

Readme

Keywords

Package Sidebar

Install

npm i trocar-dice-js

Weekly Downloads

1

Version

1.0.1

License

AGPL-3.0-or-later

Unpacked Size

36.8 kB

Total Files

4

Last publish

Collaborators

  • trocar