summaryrefslogtreecommitdiff
path: root/src/commands/voice/minecraft.ts
diff options
context:
space:
mode:
Diffstat (limited to 'src/commands/voice/minecraft.ts')
-rw-r--r--src/commands/voice/minecraft.ts8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/commands/voice/minecraft.ts b/src/commands/voice/minecraft.ts
index cad7c06..ea8fb6d 100644
--- a/src/commands/voice/minecraft.ts
+++ b/src/commands/voice/minecraft.ts
@@ -1,5 +1,5 @@
import ytdl from 'ytdl-core';
-import { Command } from 'discord.js-commando';
+import { Command, CommandoMessage } from 'discord.js-commando';
import { MessageEmbed } from 'discord.js';
import Youtube from 'simple-youtube-api';
//const { youtubeAPI } = require('../../config.json');
@@ -27,9 +27,9 @@ module.exports = class MinecraftVoice extends Command {
]
});
}
- async run(msg) {
+ async run(msg: CommandoMessage) {
const voiceChannel = msg.member.voice.channel;
- if (!voiceChannel) return msg.say('Join a channel and try again. ' + emoji.random());
+ if (!voiceChannel) return msg.say('Please join a channel and try again. ' + emoji.random());
const playlist = await youtube.getPlaylist('https://www.youtube.com/watch?v=05UM-i4PuOY&list=PLxOTV5xn7n1i2HcKtRBthP2loWjrBGAIY').catch(function () {
return msg.say('There was a problem getting the soundtrack. ' + emoji.random());
@@ -125,7 +125,7 @@ module.exports = class MinecraftVoice extends Command {
});
});
}
- playSong(queue, msg) {
+ playSong(queue, msg: CommandoMessage) {
const classThis = this; // use classThis instead of 'this' because of lexical scope below
queue[0].voiceChannel
.join()