Need help with this command. Im trying to do a random number generator. But i want to have a specif…

Asked Sep 20, 2020·4 replies·Last activity 5 years ago·Open in Discord ↗
Archived from the original community forum
Things may have changed since it was written. Still stuck? Ask the community on Discord.

$(touser), on a scale of 1 to 10, you’re like a $(eval "$(user)"=="princessmarvel "?"10":Math.floor(Math.random()*10+1))

4 replies

From what I can tell that should work unless the person name your checking has capitals in it. You can fix that by putting.toLowerCase() after "$(user)" like this:

$(eval "$(user)".toLowerCase()=="princessmarvel"?"10":Math.floor(Math.random()*10+1))

Also you had a space after the name before but I just deleted it. This should work as you want it to.

you know what, after seeing this, my first reaction was "lol" literally... sorry for the stupid reply. but yes

im thinking the problem was the space lol 😓