#i see so i would have to get User Option
1 messages · Page 1 of 1 (latest)
looking at the message history of what you are asking is pretty hard to follow
for whatever button you are watching and catching events on
are you familar with the dank memer fight command?
check if the event for click was created by one of the two people you want to be able to use the button
it's a turn based attack mini-game
how would i check if for the id of the user who initiated the command?
is it interaction.user?
and how would i check for the id of the person who clicked the button then?
the collector collects the user
have you created the collector?
yep
im just wondering how would i get the id of the user who clicks the button
and the id of the user who inititated the slash command
you should send source files
source files?
like the .js files
instead of screenshots
or paste the whole file inside tags like
ok
you can change it back to i if you want, i dont know why the docs show it being i but it will be easier to follow if it matches docs
ok
what you are catching with
collector.on('collect', async (i) =>{
if(i.customId === 'button'){
}
})
is
that will show you all the properties on the object that is being assigned to "i" in your function
that object has a user property
so
in your case
i.user
i see, and interaction.user.id is for those who initiate the slash command
tysm