From 3accd9798094f884113afe31eb20dbac7ca6c308 Mon Sep 17 00:00:00 2001 From: Anthony M <47640864+IDeletedSystem64@users.noreply.github.com> Date: Sat, 30 Jan 2021 23:23:32 -0600 Subject: [PATCH 1/6] Add new statuses --- start.js | 172 ++++++++++++++++++++++++++++--------------------------- 1 file changed, 88 insertions(+), 84 deletions(-) diff --git a/start.js b/start.js index 7301cc4..8b66384 100644 --- a/start.js +++ b/start.js @@ -1,84 +1,88 @@ -console.log('Preparing to start!') -const fs = require('fs'); -const Discord = require('discord.js'); -const { prefix, token } = require('./config.json'); -const os = require("os") - -const version = "Test Release 3, build 439"; -const release = "anitrox_ptb" - - -console.log('Starting!') -const client = new Discord.Client(); -client.commands = new Discord.Collection(); -const activities_list = [ - "with n!help", - "Where am I?", - "with Sylveons!", - "on my host's hard disk", - "with Happy", - "HAAAAAAAAPPPPPPPYYYYYYYYYYYYYYYYYYYY", - "Running on " + process.platform + " / " + os.version() + "!", - "with the tea machine", - "with Borked Computers", - "on Happy's main PC- wait shoot she's coming", - "btw I use Debian linux", - "Watching you", - "Running " + release + " Version " + version, - "in Incognito Mode- wait what" -]; -const footicon = "https://media.discordapp.net/attachments/549707869138714635/793524910172667964/Screenshot_26.png" -const footer = "Made with ❤ in Illinois | Anitrox © 2018-2021 IDeletedSystem64" - -const commandFiles = fs.readdirSync('./commands').filter(file => file.endsWith('.js')); - -for (const file of commandFiles) { - const command = require(`./commands/${file}`); - client.commands.set(command.name, command); -} - -client.on("error", (e) => console.error(e)); -client.on("warn", (e) => console.warn(e)); -client.on("debug", (e) => console.info(e)) -client.once('ready', () => { - console.log('All systems go.'); -}); -setInterval(() => { - const index = Math.floor(Math.random() * (activities_list.length - 1) + 1); - client.user.setActivity(activities_list[index]); -}, 20000); - -client.on('message', message => { - if (!message.content.startsWith(prefix) || message.author.bot) return; - - const args = message.content.slice(prefix.length).split(/ +/); - const command = args.shift().toLowerCase(); - - if (!client.commands.has(command)) return; - - try { - client.commands.get(command).execute(client, message, args); - } catch (error) { - const embed = { - "title": "<:NyabotError:697145462347661412> **Well that happened...**", - "color": 13632027, - "footer": { - "icon_url": "https://cdn.discordapp.com/attachments/549707869138714635/793524910172667964/Screenshot_26.png", - "text": "Anitrox © IDeletedSystem64 2018-2021 All Rights Reserved." - }, - "fields": [ - { - "name": "**What Happened?**", - "value": "The command you tried to run failed to execute due to an error." - }, - { - "name": "Error Info", - "value": error.message - } - ] - }; - message.channel.send({ embed }); - } -}); - -client.login(token); +console.log('Preparing to start!') +const fs = require('fs'); +const Discord = require('discord.js'); +const { prefix, token } = require('./config.json'); +const os = require("os") +const version = "build 435"; +const release = "anitrox_unstable" + +console.log('Starting!') +const client = new Discord.Client(); +client.commands = new Discord.Collection(); +const activities_list = [ + "with np!help", + "Where am I?", + "with Sylveons!", + "on my host's hard disk", + "with Sophie", + "HAAAAAAAAPPPPPPPYYYYYYYYYYYYYYYYYYYY", + "Running on " + process.platform + " / " + os.version() + "!", + "with the tea machine", + "with Borked Computers", + "on Sophie's main PC- wait shoot she's coming", + "btw I use Debian linux", + "Watching you", + "Running " + release + " Version " + version, + "in Incognito Mode- wait what", + "uwu", + "Team Fortress 2 with Sophie", + "videos on Hulu", + "American Truck Simulator", + "my users!", + "Sophies skirt" +]; +const footicon = "https://media.discordapp.net/attachments/549707869138714635/793524910172667964/Screenshot_26.png" +const footer = "Made with ❤ in Illinois | Anitrox © 2018-2021 IDeletedSystem64" + +const commandFiles = fs.readdirSync('./commands').filter(file => file.endsWith('.js')); + +for (const file of commandFiles) { + const command = require(`./commands/${file}`); + client.commands.set(command.name, command); +} + +client.on("error", (e) => console.error(e)); +client.on("warn", (e) => console.warn(e)); +client.on("debug", (e) => console.info(e)) +client.once('ready', () => { + console.log('All systems go.'); +}); +setInterval(() => { + const index = Math.floor(Math.random() * (activities_list.length - 1) + 1); + client.user.setActivity(activities_list[index]); +}, 20000); + +client.on('message', message => { + if (!message.content.startsWith(prefix) || message.author.bot) return; + + const args = message.content.slice(prefix.length).split(/ +/); + const command = args.shift().toLowerCase(); + + if (!client.commands.has(command)) return; + + try { + client.commands.get(command).execute(client, message, args); + } catch (error) { + const embed = { + "title": "<:NyabotError:697145462347661412> **Well that happened...**", + "color": 13632027, + "footer": { + "icon_url": "https://cdn.discordapp.com/attachments/549707869138714635/793524910172667964/Screenshot_26.png", + "text": "Anitrox © IDeletedSystem64 2018-2021 All Rights Reserved." + }, + "fields": [ + { + "name": "**What Happened?**", + "value": "The command you tried to run failed to execute due to an error." + }, + { + "name": "Error Info", + "value": error.message + } + ] + }; + message.channel.send({ embed }); + } +}); + +client.login(token); From d835cdaebb6515c11e9566f7d1df84a4cae800b4 Mon Sep 17 00:00:00 2001 From: Anthony M <47640864+IDeletedSystem64@users.noreply.github.com> Date: Sat, 30 Jan 2021 23:25:00 -0600 Subject: [PATCH 2/6] Check for mentioned user --- commands/kiss.js | 22 +++++++++++++++++++++- commands/leskiss.js | 22 +++++++++++++++++++++- 2 files changed, 42 insertions(+), 2 deletions(-) diff --git a/commands/kiss.js b/commands/kiss.js index 6796d38..37c49c6 100644 --- a/commands/kiss.js +++ b/commands/kiss.js @@ -5,6 +5,8 @@ module.exports = { execute(client, message, args) { const messageAuthor = message.author const taggedUser = message.mentions.users.first(); + + // -------------------------------------- const gifchoices = [ "https://thumbs.gfycat.com/SlowGlossyBlackcrappie-small.gif", @@ -17,9 +19,27 @@ module.exports = { const index = Math.floor(Math.random() * (gifchoices.length - 1) + 1); var gif = (gifchoices[index]); // --------------------------------------- + const errorembed = { + "title": "<:NyabotError:697145462347661412> Error", + "color": 13632027, + "footer": { + "icon_url": "https://images-ext-2.discordapp.net/external/-qaO3jaZLojhEnjrHiKABdXD7gLWqFvdUqHdskNGWhE/https/media.discordapp.net/attachments/549707869138714635/793524910172667964/Screenshot_26.png", + "text": "Made with ❤ in Illinois | Anitrox © 2018-2021 IDeletedSystem64" + }, + "fields": [ + { + "name": "Well that happened...", + "value": "You need to @mention an user!" + } + ] + }; + + if(!taggedUser) { + return message.channel.send({ embed: errorembed}); + } const embed = { "title": ":heart: Kiss", - "description": "<@" + taggedUser + ">" + " You have been kissed by <@" + messageAuthor + ">!", + "description": "<@" + taggedUser + ">" + ", You have been kissed by <@" + messageAuthor + ">!", "color": 8311585, "footer": { "icon_url": "https://media.discordapp.net/attachments/549707869138714635/793524910172667964/Screenshot_26.png", diff --git a/commands/leskiss.js b/commands/leskiss.js index d803185..2476a3c 100644 --- a/commands/leskiss.js +++ b/commands/leskiss.js @@ -6,7 +6,7 @@ module.exports = { name: "leskiss", description: "Lesbian kiss <:lesbian:803831629428686849>", execute(client, message, args) { - const messageAuthor = message.messageAuthor + const messageAuthor = message.author const taggedUser = message.mentions.users.first(); // -------------------------------------- const gifchoices = [ @@ -30,6 +30,26 @@ module.exports = { const index = Math.floor(Math.random() * (gifchoices.length - 1) + 1); var gif = (gifchoices[index]); // --------------------------------------- + const errorembed = { + "title": "<:NyabotError:697145462347661412> Error", + "color": 13632027, + "footer": { + "icon_url": "https://images-ext-2.discordapp.net/external/-qaO3jaZLojhEnjrHiKABdXD7gLWqFvdUqHdskNGWhE/https/media.discordapp.net/attachments/549707869138714635/793524910172667964/Screenshot_26.png", + "text": "Made with ❤ in Illinois | Anitrox © 2018-2021 IDeletedSystem64" + }, + "fields": [ + { + "name": "Well that happened...", + "value": "You need to @mention an user!" + } + ] + }; + + if(!taggedUser) { + return message.channel.send({ embed: errorembed}); + // Checks if a user was mentioned. If not, returns error message. + } + const embed = { "title": ":heart: <:lesbian:803831629428686849> Kiss", From 2aa8fb67a702ffaf004add8cbed959a3639a45fb Mon Sep 17 00:00:00 2001 From: Anthony M <47640864+IDeletedSystem64@users.noreply.github.com> Date: Sat, 30 Jan 2021 23:26:04 -0600 Subject: [PATCH 3/6] lick foxi --- commands/lick.js | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 commands/lick.js diff --git a/commands/lick.js b/commands/lick.js new file mode 100644 index 0000000..53c7aa2 --- /dev/null +++ b/commands/lick.js @@ -0,0 +1,6 @@ +module.exports = { + name: "lick", + description: "Licks an user!", + execute(client, message, args) { + const messageAuthor = message.author + const taggedUser = message.mentions.users.first(); \ No newline at end of file From f331627bdb2931b3a18575a16a522acd5963ca96 Mon Sep 17 00:00:00 2001 From: Anthony M <47640864+IDeletedSystem64@users.noreply.github.com> Date: Sat, 30 Jan 2021 23:32:54 -0600 Subject: [PATCH 4/6] =?UTF-8?q?=F0=9F=99=83=20Ill=20be=20honest,=20I=20mes?= =?UTF-8?q?sed=20up=20a=20line.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- start.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/start.js b/start.js index 8b66384..825fa22 100644 --- a/start.js +++ b/start.js @@ -29,7 +29,7 @@ const activities_list = [ "videos on Hulu", "American Truck Simulator", "my users!", - "Sophies skirt" + "with Sophies skirt" ]; const footicon = "https://media.discordapp.net/attachments/549707869138714635/793524910172667964/Screenshot_26.png" const footer = "Made with ❤ in Illinois | Anitrox © 2018-2021 IDeletedSystem64" From 73f62ff32dab8afe690877f5d585bd6d470330e9 Mon Sep 17 00:00:00 2001 From: Anthony M <47640864+IDeletedSystem64@users.noreply.github.com> Date: Sat, 30 Jan 2021 23:48:07 -0600 Subject: [PATCH 5/6] Check for mentioned user, if none return error. --- commands/bonk.js | 21 ++++++++++++++++++++- commands/hug.js | 21 +++++++++++++++++++++ commands/info.js | 6 +++--- commands/nom.js | 21 ++++++++++++++++++++- commands/pat.js | 19 +++++++++++++++++++ commands/poke.js | 21 ++++++++++++++++++++- commands/slap.js | 25 ++++++++++++++++++++++++- 7 files changed, 127 insertions(+), 7 deletions(-) diff --git a/commands/bonk.js b/commands/bonk.js index 6d6d313..073c39c 100644 --- a/commands/bonk.js +++ b/commands/bonk.js @@ -5,7 +5,26 @@ module.exports = { execute(client, message, args) { const messageAuthor = message.author const taggedUser = message.mentions.users.first(); - + const errorembed = { + "title": "<:NyabotError:697145462347661412> Error", + "color": 13632027, + "footer": { + "icon_url": "https://images-ext-2.discordapp.net/external/-qaO3jaZLojhEnjrHiKABdXD7gLWqFvdUqHdskNGWhE/https/media.discordapp.net/attachments/549707869138714635/793524910172667964/Screenshot_26.png", + "text": "Made with ❤ in Illinois | Anitrox © 2018-2021 IDeletedSystem64" + }, + "fields": [ + { + "name": "Well that happened...", + "value": "You need to @mention an user!" + } + ] + }; + + if(!taggedUser) { + return message.channel.send({ embed: errorembed}); + // Checks if a user was mentioned. If not, returns error message. + } + const embed = { "title": " Bonk", "description": "<@" + taggedUser + ">" + " You have been bonked by <@" + messageAuthor + ">!", diff --git a/commands/hug.js b/commands/hug.js index dc4add0..a136479 100644 --- a/commands/hug.js +++ b/commands/hug.js @@ -13,6 +13,27 @@ module.exports = { "https://data.whicdn.com/images/294164107/original.gif", "https://media1.tenor.com/images/e5e7779385d003db13396e03b7fd1024/tenor.gif?itemid=16619907" ]; + //--------------------------------- + const errorembed = { + "title": "<:NyabotError:697145462347661412> Error", + "color": 13632027, + "footer": { + "icon_url": "https://images-ext-2.discordapp.net/external/-qaO3jaZLojhEnjrHiKABdXD7gLWqFvdUqHdskNGWhE/https/media.discordapp.net/attachments/549707869138714635/793524910172667964/Screenshot_26.png", + "text": "Made with ❤ in Illinois | Anitrox © 2018-2021 IDeletedSystem64" + }, + "fields": [ + { + "name": "Well that happened...", + "value": "You need to @mention an user!" + } + ] + }; + + if(!taggedUser) { + return message.channel.send({ embed: errorembed}); + // Checks if a user was mentioned. If not, returns error message. + } + const index = Math.floor(Math.random() * (gifchoices.length - 1) + 2); var gif = (gifchoices[index]); const embed = { diff --git a/commands/info.js b/commands/info.js index 8fcd5ec..c549db5 100644 --- a/commands/info.js +++ b/commands/info.js @@ -24,8 +24,8 @@ module.exports = { -const version = ("dev build 429") - const release = ("anitrox_dev") +const version = ("Public Test Release 4.1 (build 444)") + const release = ("anitrox_ptb") const os = require("os") const embed = { @@ -58,7 +58,7 @@ const version = ("dev build 429") }, { "name": "<:memory:793536677737136178> Bot Memory Usage", - "value": (Math.round(process.memoryUsage().heapUsed / 1024 / 1024 * 100) / 100) + " MiB" + ", Total Free Memory" + "value": (Math.round(process.memoryUsage().heapUsed / 1024 / 1024 * 100) / 100) + " MiB" }, { "name": "<:hostinfo:793529505263517747> Host Information", diff --git a/commands/nom.js b/commands/nom.js index cb8302f..3449231 100644 --- a/commands/nom.js +++ b/commands/nom.js @@ -18,7 +18,26 @@ module.exports = { const index = Math.floor(Math.random() * (gifchoices.length - 1) + 1); var gif = (gifchoices[index]); // --------------------------------------- - + const errorembed = { + "title": "<:NyabotError:697145462347661412> Error", + "color": 13632027, + "footer": { + "icon_url": "https://images-ext-2.discordapp.net/external/-qaO3jaZLojhEnjrHiKABdXD7gLWqFvdUqHdskNGWhE/https/media.discordapp.net/attachments/549707869138714635/793524910172667964/Screenshot_26.png", + "text": "Made with ❤ in Illinois | Anitrox © 2018-2021 IDeletedSystem64" + }, + "fields": [ + { + "name": "Well that happened...", + "value": "You need to @mention an user!" + } + ] + }; + + if(!taggedUser) { + return message.channel.send({ embed: errorembed}); + // Checks if a user was mentioned. If not, returns error message. + } + const embed = { "title": "<:BlobNomBlob:801241117919805510> Nom", "description": "<@" + taggedUser + "> You have been nommed by <@" + messageAuthor + ">!", diff --git a/commands/pat.js b/commands/pat.js index d67a4c7..a876ba4 100644 --- a/commands/pat.js +++ b/commands/pat.js @@ -17,6 +17,25 @@ module.exports = { const index = Math.floor(Math.random() * (gifchoices.length - 1) + 2); var gif = (gifchoices[index]); // --------------------------------------- + const errorembed = { + "title": "<:NyabotError:697145462347661412> Error", + "color": 13632027, + "footer": { + "icon_url": "https://images-ext-2.discordapp.net/external/-qaO3jaZLojhEnjrHiKABdXD7gLWqFvdUqHdskNGWhE/https/media.discordapp.net/attachments/549707869138714635/793524910172667964/Screenshot_26.png", + "text": "Made with ❤ in Illinois | Anitrox © 2018-2021 IDeletedSystem64" + }, + "fields": [ + { + "name": "Well that happened...", + "value": "You need to @mention an user!" + } + ] + }; + + if(!taggedUser) { + return message.channel.send({ embed: errorembed}); + // Checks if a user was mentioned. If not, returns error message. + } const embed = { "title": "<:pats:801238281286713355> Pat", diff --git a/commands/poke.js b/commands/poke.js index 266dfb6..1c98e1d 100644 --- a/commands/poke.js +++ b/commands/poke.js @@ -17,7 +17,26 @@ module.exports = { const index = Math.floor(Math.random() * (gifchoices.length - 1) + 2); var gif = (gifchoices[index]); // --------------------------------------- - + const errorembed = { + "title": "<:NyabotError:697145462347661412> Error", + "color": 13632027, + "footer": { + "icon_url": "https://images-ext-2.discordapp.net/external/-qaO3jaZLojhEnjrHiKABdXD7gLWqFvdUqHdskNGWhE/https/media.discordapp.net/attachments/549707869138714635/793524910172667964/Screenshot_26.png", + "text": "Made with ❤ in Illinois | Anitrox © 2018-2021 IDeletedSystem64" + }, + "fields": [ + { + "name": "Well that happened...", + "value": "You need to @mention an user!" + } + ] + }; + + if(!taggedUser) { + return message.channel.send({ embed: errorembed}); + // Checks if a user was mentioned. If not, returns error message. + } + const embed = { "title": "👉 Poke!", "description": "<@" + taggedUser + "> You have been poked by <@" + messageAuthor + ">!", diff --git a/commands/slap.js b/commands/slap.js index 74bf202..78d33b6 100644 --- a/commands/slap.js +++ b/commands/slap.js @@ -5,7 +5,30 @@ module.exports = { execute(client, message, args) { const messageAuthor = message.author const taggedUser = message.mentions.users.first(); - const embed = { +//--------------------------------------------------- + +//--------------------------------------------------- +const errorembed = { + "title": "<:NyabotError:697145462347661412> Error", + "color": 13632027, + "footer": { + "icon_url": "https://images-ext-2.discordapp.net/external/-qaO3jaZLojhEnjrHiKABdXD7gLWqFvdUqHdskNGWhE/https/media.discordapp.net/attachments/549707869138714635/793524910172667964/Screenshot_26.png", + "text": "Made with ❤ in Illinois | Anitrox © 2018-2021 IDeletedSystem64" + }, + "fields": [ + { + "name": "Well that happened...", + "value": "You need to @mention an user!" + } + ] +}; + +if(!taggedUser) { + return message.channel.send({ embed: errorembed}); +// Checks if a user was mentioned. If not, returns error message. +} + + const embed = { "title": ":anger: Slap", "description": "<@" + taggedUser + "> You have been slapped by <@" + messageAuthor + ">!", "color": 8311585, From b02fe66a6424ec8ceef5e9a69435c0d7ae6641fd Mon Sep 17 00:00:00 2001 From: Anthony M <47640864+IDeletedSystem64@users.noreply.github.com> Date: Sat, 30 Jan 2021 23:54:56 -0600 Subject: [PATCH 6/6] Final for lick.js --- commands/lick.js | 45 +++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 43 insertions(+), 2 deletions(-) diff --git a/commands/lick.js b/commands/lick.js index 53c7aa2..19dca35 100644 --- a/commands/lick.js +++ b/commands/lick.js @@ -1,6 +1,47 @@ module.exports = { + name: "lick", description: "Licks an user!", execute(client, message, args) { - const messageAuthor = message.author - const taggedUser = message.mentions.users.first(); \ No newline at end of file + const messageAuthor = message.author + const taggedUser = message.mentions.users.first(); +//--------------------------------------------------- + +//--------------------------------------------------- +const errorembed = { + "title": "<:NyabotError:697145462347661412> Error", + "color": 13632027, + "footer": { + "icon_url": "https://images-ext-2.discordapp.net/external/-qaO3jaZLojhEnjrHiKABdXD7gLWqFvdUqHdskNGWhE/https/media.discordapp.net/attachments/549707869138714635/793524910172667964/Screenshot_26.png", + "text": "Made with ❤ in Illinois | Anitrox © 2018-2021 IDeletedSystem64" + }, + "fields": [ + { + "name": "Well that happened...", + "value": "You need to @mention an user!" + } + ] +}; + +if(!taggedUser) { + return message.channel.send({ embed: errorembed}); +// Checks if a user was mentioned. If not, returns error message. +} + + const embed = { + "title": "Lick", + "description": "<@" + taggedUser + "> You have been licked by <@" + messageAuthor + ">!", + "color": 8311585, + "footer": { + "icon_url": "https://media.discordapp.net/attachments/549707869138714635/793524910172667964/Screenshot_26.png", + "text": "Made with ❤ in Illinois | Anitrox © IDeletedSystem64 2018-2021" + }, + "image": { + "url": "https://cdn.discordapp.com/attachments/803658122299572255/805314244123951114/cef569820773b0f5d54ee34cfa18e1f8.gif" + } + } + + + message.channel.send({ embed: embed }); + } + }