Custom 4 stats

hello, good evening everyone, I was programming my discord bot, and I wanted to know how custom 4 works, which is from {emoji} {state} , I appreciate your attention
18 Replies
d.js toolkit
d.js toolkit2y ago
- What's your exact discord.js npm list discord.js and node node -v version? - Not a discord.js issue? Check out #other-js-ts. - Consider reading #how-to-get-help to improve your question! - Explain what exactly your issue is. - Post the full error stack trace, not just the top part! - Show your code! - Issue solved? Press the button!
chewie
chewie2y ago
You mean setting a custom status?
TitoJr
TitoJrOP2y ago
yes
chewie
chewie2y ago
That is not yet possible, there is still an open pr for it
TitoJr
TitoJrOP2y ago
Is one equal to this, is that what you mean right?
Nwero
Nwero2y ago
its available in latest dev build of djs, also bot's custom status dont support emojis
TitoJr
TitoJrOP2y ago
So let's say you could just put lyrics? Where is that?
chewie
chewie2y ago
Actually, its merged, its possible in the dev version, but not on the latest version
d.js docs
d.js docs2y ago
method ClientUser#setActivity() Sets the activity the client user is playing.
TitoJr
TitoJrOP2y ago
I understand so it is not yet available for version 14 but it is working?
chewie
chewie2y ago
Correct
TitoJr
TitoJrOP2y ago
sorry for the question but how can i do it?
Nwero
Nwero2y ago
#djs-in-dev-version has a pinned message to show how to switch to dev build, also wouldnt recommend switching to it anyways as it can be unstable at times.
TitoJr
TitoJrOP2y ago
I understand, I'll find out, thanks to both of you. Forgive me again, but will there be some example structure to follow?
Nwero
Nwero2y ago
if you want to set a custom status, i believe the "name" property needs to be "Custom Status" and state property would be the message that would display on your bot's status activity message
chewie
chewie2y ago
Name is required but the value isnt relevant, the text of the custom status is in state and emojis are not yet possible from what I tried
client.user.setActivity({ name: "activity name", state: "custom status" })
client.user.setActivity({ name: "activity name", state: "custom status" })
TitoJr
TitoJrOP2y ago
oh okay, then I'll take it into account, thanks to both of you again
Nwero
Nwero2y ago
yw

Did you find this page helpful?