I'm kinda new to moding and don't really understand the more complicated mods like generating a random number. I want to add a command that says. (@user) is 0-100% smart. and I don't know how the random number generation works
Random number generator command
3 replies
based on "big" and "small" i'm guessing u wouldn't want a zero, so the random statement would be a little different... something like this...
js$(user) is $(eval let r=Math.floor(Math.random()*100)+1;`${r}% ${r>50?`big`:`small`}!`)
p.s. this will say "<username> is <number>% big!" if the number is above 50 and "<username> is <number>% small!" if 50 and below