Okay, I got some help and i now understand how it works…
I’m using it with my own dev bot and I see some errors:
(node:19640) DeprecationWarning: TextChannel#sendMessage: use TextChannel#send instead
and
(node:22402) DeprecationWarning: TextChannel#sendMessage: use TextChannel#send instead
(node:22402) DeprecationWarning: ClientUser#setGame: use ClientUser#setActivity instead
events.js:171
throw err; // Unhandled ‘error’ event
^
Error [ERR_UNHANDLED_ERROR]: Unhandled error. ([object Object])
at Client.emit (events.js:169:17)
at WebSocketConnection.onError (/code/mihion/botz/matrix/node_modules/discord.js/src/client/websocket/WebSocketConnection.js:371:17)
at WebSocket.onError (/code/mihion/botz/matrix/node_modules/ws/lib/event-target.js:128:16)
at WebSocket.emit (events.js:180:13)
at WebSocket.finalize (/code/mihion/botz/matrix/node_modules/ws/lib/websocket.js:190:41)
at TLSSocket.emit (events.js:180:13)
at emitErrorNT (internal/streams/destroy.js:64:8)
at process._tickCallback (internal/process/next_tick.js:114:19)