#no lmao
1 messages ยท Page 1 of 1 (latest)
Kiter i just want to tell you they already got all informations they need twice ๐
oh okay just wanted to say before this thread ends in 1 year ๐ sorry dont wanted to interrupt
xdddd
is fine i got time
starting off isnt always easy
if(!ButtonInteraction.isButton()) return
if (ButtonInteraction.customId === 'test')
{
const wait = require('util').promisify(setTimeout)
await wait(1000) // Every 1000 ms = 1 second
await ButtonInteraction.reply({ content: 'e <ping userhere>' })
}```
and im too dumb to make it ping user here i was trying to make it work for like 2 hours and i didnt manage to do that...
theres many more issues here
you are requiring something in your handler
take that out of your code block and put it at the top of the file
const wait
everything is ok rn wen i press button it actually says "e <ping userhere>" as in content:
if(!ButtonInteraction.isButton()) return
if (ButtonInteraction.customId === 'test')
{
await wait(1000) // Every 1000 ms = 1 second
await ButtonInteraction.reply({ content: 'e <ping userhere>' })
}
ok put that to the top
you want to make it mention them
in place of <ping userhere> i want it to actually mention them
like with simple ping like that: @pastel dome
what you can do is take their id and enclose it by <@ >
or you use interaction.user.toString() like mexi said
yes i was told that many times but im not able to take their id from interaction because im stupid at interactions
Also for your information, if you type ping user discord js in google you get
this whole page of search results
you can research
and try your code, to see what solution solves your problem
log interaction
see what it is made up of, and what properties you could use to get the information you want
Have you ever worked with js before?
discord.py long time ago when interactions didnt even exist
so thats a no, since i asked if you have JS experience xd
try the steps i sent and learn from those
more like 5 times
and now one time more xD
You can ask anything you want
you see every time i try ANY solution i get "this interaction failed"
you are not replying to the interaction then
interaction.reply
it is required to always reply to an interaction
but why start with buttons
why not first learn about djs, building from what you do know
you dont throw a baby in the pool and expect it to swim ๐
i hope
cuz i need that for my friends server
many ppl do to test their and they actually float
to test their reflexes
and the djs guide hasnt helped you?
what does your code look like now