mirror of
https://github.com/JonnyBro/JaBa.git
synced 2024-11-22 13:14:58 +05:00
fixes
This commit is contained in:
parent
e1a6fad375
commit
8e991d858b
2 changed files with 20 additions and 16 deletions
|
@ -34,7 +34,7 @@ class Activity extends Command {
|
||||||
.setTitle("Awkword")
|
.setTitle("Awkword")
|
||||||
.setColor(data.config.embed.color)
|
.setColor(data.config.embed.color)
|
||||||
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Awkword", channel: voice.name })}](${invite.code})**`)
|
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Awkword", channel: voice.name })}](${invite.code})**`)
|
||||||
.setFooter(data.config.embed.footer)
|
.setFooter(message.translate("general/activity:FOOTER"))
|
||||||
.setTimestamp()
|
.setTimestamp()
|
||||||
return message.channel.send(embed);
|
return message.channel.send(embed);
|
||||||
});
|
});
|
||||||
|
@ -46,7 +46,7 @@ class Activity extends Command {
|
||||||
.setTitle("Betrayal.io")
|
.setTitle("Betrayal.io")
|
||||||
.setColor(data.config.embed.color)
|
.setColor(data.config.embed.color)
|
||||||
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Betrayal.io", channel: voice.name })}](${invite.code})**`)
|
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Betrayal.io", channel: voice.name })}](${invite.code})**`)
|
||||||
.setFooter(data.config.embed.footer)
|
.setFooter(message.translate("general/activity:FOOTER"))
|
||||||
.setTimestamp()
|
.setTimestamp()
|
||||||
return message.channel.send(embed);
|
return message.channel.send(embed);
|
||||||
});
|
});
|
||||||
|
@ -58,7 +58,7 @@ class Activity extends Command {
|
||||||
.setTitle("Checkers In The Park")
|
.setTitle("Checkers In The Park")
|
||||||
.setColor(data.config.embed.color)
|
.setColor(data.config.embed.color)
|
||||||
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Checkers In The Park", channel: voice.name })}](${invite.code})**`)
|
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Checkers In The Park", channel: voice.name })}](${invite.code})**`)
|
||||||
.setFooter(data.config.embed.footer)
|
.setFooter(message.translate("general/activity:FOOTER"))
|
||||||
.setTimestamp()
|
.setTimestamp()
|
||||||
return message.channel.send(embed);
|
return message.channel.send(embed);
|
||||||
});
|
});
|
||||||
|
@ -70,7 +70,7 @@ class Activity extends Command {
|
||||||
.setTitle("Chess In The Park")
|
.setTitle("Chess In The Park")
|
||||||
.setColor(data.config.embed.color)
|
.setColor(data.config.embed.color)
|
||||||
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Chess In The Park", channel: voice.name })}](${invite.code})**`)
|
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Chess In The Park", channel: voice.name })}](${invite.code})**`)
|
||||||
.setFooter(data.config.embed.footer)
|
.setFooter(message.translate("general/activity:FOOTER"))
|
||||||
.setTimestamp()
|
.setTimestamp()
|
||||||
return message.channel.send(embed);
|
return message.channel.send(embed);
|
||||||
});
|
});
|
||||||
|
@ -82,7 +82,7 @@ class Activity extends Command {
|
||||||
.setTitle("Doodle Crew")
|
.setTitle("Doodle Crew")
|
||||||
.setColor(data.config.embed.color)
|
.setColor(data.config.embed.color)
|
||||||
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Doodle Crew", channel: voice.name })}](${invite.code})**`)
|
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Doodle Crew", channel: voice.name })}](${invite.code})**`)
|
||||||
.setFooter(data.config.embed.footer)
|
.setFooter(message.translate("general/activity:FOOTER"))
|
||||||
.setTimestamp()
|
.setTimestamp()
|
||||||
return message.channel.send(embed);
|
return message.channel.send(embed);
|
||||||
});
|
});
|
||||||
|
@ -94,7 +94,7 @@ class Activity extends Command {
|
||||||
.setTitle("Fishington.io")
|
.setTitle("Fishington.io")
|
||||||
.setColor(data.config.embed.color)
|
.setColor(data.config.embed.color)
|
||||||
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Fishington.io", channel: voice.name })}](${invite.code})**`)
|
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Fishington.io", channel: voice.name })}](${invite.code})**`)
|
||||||
.setFooter(data.config.embed.footer)
|
.setFooter(message.translate("general/activity:FOOTER"))
|
||||||
.setTimestamp()
|
.setTimestamp()
|
||||||
return message.channel.send(embed);
|
return message.channel.send(embed);
|
||||||
});
|
});
|
||||||
|
@ -106,7 +106,7 @@ class Activity extends Command {
|
||||||
.setTitle("Letter Tile")
|
.setTitle("Letter Tile")
|
||||||
.setColor(data.config.embed.color)
|
.setColor(data.config.embed.color)
|
||||||
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Letter Tile", channel: voice.name })}](${invite.code})**`)
|
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Letter Tile", channel: voice.name })}](${invite.code})**`)
|
||||||
.setFooter(data.config.embed.footer)
|
.setFooter(message.translate("general/activity:FOOTER"))
|
||||||
.setTimestamp()
|
.setTimestamp()
|
||||||
return message.channel.send(embed);
|
return message.channel.send(embed);
|
||||||
});
|
});
|
||||||
|
@ -118,7 +118,7 @@ class Activity extends Command {
|
||||||
.setTitle("Poker Night")
|
.setTitle("Poker Night")
|
||||||
.setColor(data.config.embed.color)
|
.setColor(data.config.embed.color)
|
||||||
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Poker Night", channel: voice.name })}](${invite.code})**`)
|
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Poker Night", channel: voice.name })}](${invite.code})**`)
|
||||||
.setFooter(data.config.embed.footer)
|
.setFooter(message.translate("general/activity:FOOTER"))
|
||||||
.setTimestamp()
|
.setTimestamp()
|
||||||
return message.channel.send(embed);
|
return message.channel.send(embed);
|
||||||
});
|
});
|
||||||
|
@ -130,7 +130,7 @@ class Activity extends Command {
|
||||||
.setTitle("Spell Cast")
|
.setTitle("Spell Cast")
|
||||||
.setColor(data.config.embed.color)
|
.setColor(data.config.embed.color)
|
||||||
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Spell Cast", channel: voice.name })}](${invite.code})**`)
|
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Spell Cast", channel: voice.name })}](${invite.code})**`)
|
||||||
.setFooter(data.config.embed.footer)
|
.setFooter(message.translate("general/activity:FOOTER"))
|
||||||
.setTimestamp()
|
.setTimestamp()
|
||||||
return message.channel.send(embed);
|
return message.channel.send(embed);
|
||||||
});
|
});
|
||||||
|
@ -142,7 +142,7 @@ class Activity extends Command {
|
||||||
.setTitle("Words Snack")
|
.setTitle("Words Snack")
|
||||||
.setColor(data.config.embed.color)
|
.setColor(data.config.embed.color)
|
||||||
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Words Snack", channel: voice.name })}](${invite.code})**`)
|
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Words Snack", channel: voice.name })}](${invite.code})**`)
|
||||||
.setFooter(data.config.embed.footer)
|
.setFooter(message.translate("general/activity:FOOTER"))
|
||||||
.setTimestamp()
|
.setTimestamp()
|
||||||
return message.channel.send(embed);
|
return message.channel.send(embed);
|
||||||
});
|
});
|
||||||
|
@ -154,7 +154,7 @@ class Activity extends Command {
|
||||||
.setTitle("Youtube Together")
|
.setTitle("Youtube Together")
|
||||||
.setColor(data.config.embed.color)
|
.setColor(data.config.embed.color)
|
||||||
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Youtube Together", channel: voice.name })}](${invite.code})**`)
|
.setDescription(`**[${message.translate("misc:CLICK_HERE", { activity: "Youtube Together", channel: voice.name })}](${invite.code})**`)
|
||||||
.setFooter(data.config.embed.footer)
|
.setFooter(message.translate("general/activity:FOOTER"))
|
||||||
.setTimestamp()
|
.setTimestamp()
|
||||||
return message.channel.send(embed);
|
return message.channel.send(embed);
|
||||||
});
|
});
|
||||||
|
|
|
@ -17,13 +17,14 @@ class Say extends Command {
|
||||||
}
|
}
|
||||||
|
|
||||||
async run (message, args, data) {
|
async run (message, args, data) {
|
||||||
|
if (!args[0]) return message.delete();
|
||||||
|
|
||||||
// Arguments split
|
// Arguments split
|
||||||
let split = "++";
|
let split = "++";
|
||||||
args = args.join(" ").split(split);
|
args = args.join(" ").split(split);
|
||||||
for (var i = 0; i < args.length; i++) args[i] = args[i].trim();
|
for (var i = 0; i < args.length; i++) args[i] = args[i].trim();
|
||||||
|
|
||||||
if (!args[0]) return message.delete();
|
if (message.attachments.size > 0) var attachment = message.attachments.array()[0].url;
|
||||||
if (message.attachments.size > 0) attachment = message.attachments.array()[0].url
|
|
||||||
|
|
||||||
if (args[1] && !args[2]) {
|
if (args[1] && !args[2]) {
|
||||||
message.delete();
|
message.delete();
|
||||||
|
@ -31,7 +32,8 @@ class Say extends Command {
|
||||||
saychannel.startTyping();
|
saychannel.startTyping();
|
||||||
|
|
||||||
setTimeout(function() {
|
setTimeout(function() {
|
||||||
saychannel.send(args[0], { files: [ attachment ] });
|
if (attachment) saychannel.send(args[0], { files: [ attachment ] });
|
||||||
|
else saychannel.send(args[0]);
|
||||||
saychannel.stopTyping();
|
saychannel.stopTyping();
|
||||||
}, 2000);
|
}, 2000);
|
||||||
} else if (args[2]) {
|
} else if (args[2]) {
|
||||||
|
@ -39,7 +41,8 @@ class Say extends Command {
|
||||||
saychannel.startTyping();
|
saychannel.startTyping();
|
||||||
|
|
||||||
setTimeout(function() {
|
setTimeout(function() {
|
||||||
saychannel.send(args[0], { files: [ attachment ] });
|
if (attachment) saychannel.send(args[0], { files: [ attachment ] });
|
||||||
|
else saychannel.send(args[0]);
|
||||||
saychannel.stopTyping();
|
saychannel.stopTyping();
|
||||||
}, 2000);
|
}, 2000);
|
||||||
} else {
|
} else {
|
||||||
|
@ -48,7 +51,8 @@ class Say extends Command {
|
||||||
saychannel.startTyping();
|
saychannel.startTyping();
|
||||||
|
|
||||||
setTimeout(function() {
|
setTimeout(function() {
|
||||||
saychannel.send(args[0], { files: [ attachment ] });
|
if (attachment) saychannel.send(args[0], { files: [ attachment ] });
|
||||||
|
else saychannel.send(args[0]);
|
||||||
saychannel.stopTyping();
|
saychannel.stopTyping();
|
||||||
}, 2000);
|
}, 2000);
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue