Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

787
Views
El tipo de actividad setPresence en discord.js v14 solo se puede configurar en "JUGAR"

Cuando trato de configurar el estado del bot, no sé el tipo, básicamente, hay 4 formas: PLAYING , WATCHING , LISTENING y STREAMING . Pero no puedo configurar nada más, solo puedo usar el PLAYING predeterminado.

¿Estoy distraído o realmente no puedo ser así en la actualización más reciente?

 client.user.setPresence({ activities: [{ name: `discord.js v14`, type: `WATCHING` }], status: 'dnd' })
about 4 years ago · Santiago Trujillo
1 answers
Answer question

0

En v14, deberá usar las enumeraciones o números de ActivityType .

Puedes importarlo desde discord.js :

 const { Client, GatewayIntentBits, ActivityType } = require('discord.js');

Y utilízalo así:

 client.user.setPresence({ activities: [{ name: `discord.js v14`, type: ActivityType.Watching }], status: 'dnd', });

Lista de tipos de ActivityType :

v13 v14 valor v14
"COMPETING" ActivityType.Competing 5
"LISTENING" ActivityType.Listening 2
"PLAYING" ActivityType.Playing 0
"STREAMING" ActivityType.Streaming 1
"WATCHING" ActivityType.Watching 3
about 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!