Hi, I’m trying to figure out how to generate random numbers using Nightbot a certain amount of times based off the number put in after the command.
What I want to type:
!d20 4
What I want it to do:
Generate 4 random numbers between 1 and 20
I’ve scoured the internet and have not quite found what I need. I currently use the following code for generating a random number between 1 and 20:
$(eval Math.floor((Math.random() * 20) + 1))
I’d like to be able to generate more than one number, separated by commas, while using only one command