So like many others, I’m having a problem making a command. This is my first time doing a more complicated one like this, so I’m still an idiot when it comes down to it.
What I was trying to do was create a command that said, “(User) used (random Pokemon move) on (other user). It’s (‘super effective’ or ‘not very effective’)!”
I got the “effectiveness” part to work, but it’s the moves I’m having hard time with. I want to pull a random move from a list of about 150 moves I have in a PasteBin. Here’s the command I tried using:
!commands add !battle $(user) used $(eval a=$(urlfetch json https://pastebin.com/raw/4KuKDHk1).split(,
);a[Math.floor(Math.random()*(a.length-1))]) on $(touser)! It’s $(eval const responses = [‘super effective!’, ‘not very effective…’]; responses[Math.floor(Math.random() * responses.length)]
Any help would be greatly appreciated! Thanks!