quacky
March 23, 2018, 8:31am
1
so I am trying to make a command (like the 8ball one) where nightbot responds with one of the following locations:
!commands add !wherewelanding $(eval const responses = [‘Anarachy Acres’, ‘Dusty Depot’, ‘Fatal Fields’, ‘Flush Factory’, ‘Greasy Grove’, ‘Haunted Hills’, ‘Junk Junction’, ‘Loot Lake’, ‘Lonely Lodge’, ‘Lucky Landing’, ‘Moisty Mire’, ‘Motel’, ‘Pleasant Park’, ’Prison’, ‘Retail Row’, ‘Ruins’, ‘Salty Springs’, ‘Shifty Shafts’, ‘Snobby Shores’, ‘Stadium’, ‘Tilted Towers’, ‘Tomato Town’, ‘Wailing Woods’ ]; responses[Math.floor(Math.random() * responses.length)]
but i get this response “Right-hand side of ‘instanceof’ is not an object”
any ideas?
am_1
March 23, 2018, 8:57am
2
Your command is too long (over 500 characters) and uses ‘
and ’
for quotes, which are not valid. You must use "
or '
. Also, your command is missing a )
at the end of the eval
variable. Here is a shortened (no responses were removed) and corrected version of your command:
!commands add !wherewelanding 🔎 $(eval r="Anarachy Acres,Dusty Depot,Fatal Fields,Flush Factory,Greasy Grove,Haunted Hills,Junk Junction,Loot Lake,Lonely Lodge,Lucky Landing,Moisty Mire,Motel,Pleasant Park,Prison,Retail Row,Ruins,Salty Springs,Shifty Shafts,Snobby Shores,Stadium,Tilted Towers,Tomato Town,Wailing Woods".split(",");r[Math.floor(Math.random()*r.length)]) 😉
1 Like
system
Closed
April 6, 2018, 9:09am
4
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.