Хотел сделать custom status presence, но выбывает ошибку, можете помочь с ошибкой?
Код
const clientId = '...';
const drpc = require('discord-rpc');
const rpc = new drpc.Client({ transport: 'ipc' });
rpc.on('ready', async () => {
rpc.setActivity({
details: '...',
state: '...',
startTimestamp: new Date(),
largeImageKey: '...',
largeImageText: '...',
smallImageKey: '...',
smallImageKey: '...'
});
});
rpc.login({ clientId: clientId })
Ошибка
/javascript/rpc/node_modules/discord-rpc/src/transports/ipc.js:32
reject(new Error('Could not connect'));
^
Error: Could not connect
at Socket.onerror (/javascript/rpc/node_modules/discord-rpc/src/transports/ipc.js:32:16)
at Object.onceWrapper (node:events:628:26)
at Socket.emit (node:events:513:28)
at emitErrorNT (node:internal/streams/destroy:151:8)
at emitErrorCloseNT (node:internal/streams/destroy:116:3)
at process.processTicksAndRejections (node:internal/process/task_queues:82:21)
Node.js v18.10.0