d-tts
v2.0.1
Published
디스코드 봇에서 언어코드로 TTS 음성을 송출합니다.
Downloads
5
Maintainers
Readme
예시:
const { Client } = require("discord.js"),
{ getVoiceStream } = require("d-tts");
const client = new Client();
client.login("Token");
client.on("ready", () => {
console.log("Bot is Ready.");
})
.on("message", m => {
if (m.content === "test") {
message.member.voice.channel.join().then(connection => {
const stream = getVoiceStream("테스트 TTS", "ko-KR");
const dispatcher = connection.play(stream);
dispatcher.on("finish", () => message.member.voice.channel.leave());
});
}
});
필요한 모듈:
discord.js
@discordjs/opus
ffmpeg-static