we do a little fixing

Co-authored-by: datejer  <datejer@users.noreply.github.com>
This commit is contained in:
2021-10-08 14:39:18 +02:00
parent 30c1a60dc1
commit face7875b9
4 changed files with 15 additions and 3 deletions

4
package-lock.json generated
View File

@@ -12,6 +12,10 @@
"discord.js": "^13.1.0", "discord.js": "^13.1.0",
"dotenv": "^10.0.0", "dotenv": "^10.0.0",
"nodemon": "^2.0.13" "nodemon": "^2.0.13"
},
"engines": {
"node": ">=16.10.0",
"npm": ">=7.24.0"
} }
}, },
"node_modules/@discordjs/builders": { "node_modules/@discordjs/builders": {

View File

@@ -61,7 +61,7 @@
"value": "Jeżeli będziesz bezużytecznie spamować lub nieprzyjmenie się zachowywać zostaniesz zbanowany." "value": "Jeżeli będziesz bezużytecznie spamować lub nieprzyjmenie się zachowywać zostaniesz zbanowany."
}, },
{ {
"name": "§3 Shitposting", "name": "§3 Bagno",
"value": "Kanał #bagno jest najbardziej wyluzowanym kanałem na naszym serwerze. Nie oznacza to jednak, że nie jest monitorowany. Jeżeli czujesz, że rzecz którą chcesz tam umieścić jest nadzwyczajnie kontrowersyjna, zastanów się dwa razy przed wciśnięciem Enter." "value": "Kanał #bagno jest najbardziej wyluzowanym kanałem na naszym serwerze. Nie oznacza to jednak, że nie jest monitorowany. Jeżeli czujesz, że rzecz którą chcesz tam umieścić jest nadzwyczajnie kontrowersyjna, zastanów się dwa razy przed wciśnięciem Enter."
}, },
{ {

View File

@@ -11,7 +11,7 @@ module.exports = {
execute(cl, msg, args) { execute(cl, msg, args) {
// TODO: add a permissions check here to make sure nobody can spawn msgs // TODO: add a permissions check here to make sure nobody can spawn msgs
// not intended outside of specific scenarios // not intended outside of specific scenarios
const embed = { let embed = {
color: cl.cfg.hexBlue, color: cl.cfg.hexBlue,
// timestamp: new Date(), // timestamp: new Date(),
// footer: { // footer: {
@@ -19,6 +19,9 @@ module.exports = {
// icon_url: cl.cfg.iconurl, // icon_url: cl.cfg.iconurl,
// }, // },
}; };
let readyMsg;
switch (args[0]) { switch (args[0]) {
case 'witaj': case 'witaj':
embed.author = { embed.author = {
@@ -34,7 +37,11 @@ module.exports = {
embed.title = 'Regulamin'; embed.title = 'Regulamin';
embed.description = embed.description =
'Regulamin naszego serwera składa się z tego, co następuje:'; 'Regulamin naszego serwera składa się z tego, co następuje:';
embed.footer.text = `Ostatnio zaktualizowany`; embed.footer = {
text: `Ostatnio zaktualizowany`,
icon_url: cl.cfg.iconurl,
};
embed.timestamp = new Date();
embed.fields = cl.cfg.embedFields.regulamin; embed.fields = cl.cfg.embedFields.regulamin;
readyMsg = { embeds: [embed] }; readyMsg = { embeds: [embed] };
break; break;

View File

@@ -38,6 +38,7 @@ cl.on('messageCreate', (msg) => {
msg.reply( msg.reply(
`An error occured while trying to execute ${cmdName} with args ${args}` `An error occured while trying to execute ${cmdName} with args ${args}`
); );
console.log(error);
return; return;
} }
console.log(`msgCommand: ${cmdName + args} by ${msg.author.tag}`); console.log(`msgCommand: ${cmdName + args} by ${msg.author.tag}`);