Categories > Coding > Javascript >

Some pretty cool discord.js functions

Posts: 725

Threads: 58

Joined: Feb, 2021

Reputation: 3

Posted

I will be naming some cool discord.js functions

So the first one is one that the WeAreDevs discord bot has. It is called startTyping (this makes it so that it says at the bottom BotName is typing) Example:

channel.startTyping(5);

Than you can do like 

channel.stopTyping(true);

To stop it its pretty cool makes the bot have human feel

The next ones are customization

Custom status (Will say Playing a game than the custom game thingy)

So when you have this line (If you dont copy and paste)

client.on('ready', () => {
  console.log(`Logged in as ${client.user.tag}!`);
});

That part you can make a new line after the console.log(`Logged in as ${client.user.tag}!`)

And type the following:

client.user.setActivity("Replace this with the message")

The next one is statuses like do not disturb and idle

It is pretty easy start by making a new line (I already explained) and type this:

client.user.setStatus("dnd") or client.user.setStatus("idle")

Pretty cool function.

Thank you for reading! My hands hurt I might make a part 2 who knows.

  • 0

no

Error: The signature must be between 3-200 characters

Posts: 38

Threads: 2

Joined: Feb, 2021

Reputation: 0

Replied

vouch really good i learned much i am bigbrain now bump this thread :gun:

  • 0

Posts: 2099

Threads: 10

Joined: Sep, 2020

Reputation: 62

Replied

PareX is typing.....

  • 0

Discord : Doctor Doom#0550

Posts: 725

Threads: 58

Joined: Feb, 2021

Reputation: 3

Replied

@0x777_

Lmao

/chars

  • 0

no

Error: The signature must be between 3-200 characters

Users viewing this thread:

( Members: 0, Guests: 1, Total: 1 )