From 760901e8013d2cd2d484aba40d2d9f742e0736f1 Mon Sep 17 00:00:00 2001 From: Daniel Odendahl Jr Date: Fri, 22 Sep 2017 23:10:56 +0000 Subject: [PATCH] Snake Speak Command --- commands/text-edit/pirate.js | 1 + commands/text-edit/snake-speak.js | 28 ++++++++++++++++++++++++++++ commands/text-edit/temmie.js | 1 + package.json | 2 +- 4 files changed, 31 insertions(+), 1 deletion(-) create mode 100644 commands/text-edit/snake-speak.js diff --git a/commands/text-edit/pirate.js b/commands/text-edit/pirate.js index e9111002..50a1e4a2 100644 --- a/commands/text-edit/pirate.js +++ b/commands/text-edit/pirate.js @@ -6,6 +6,7 @@ module.exports = class PirateCommand extends Command { constructor(client) { super(client, { name: 'pirate', + aliases: ['pirate-speak'], group: 'text-edit', memberName: 'pirate', description: 'Converts text to pirate.', diff --git a/commands/text-edit/snake-speak.js b/commands/text-edit/snake-speak.js new file mode 100644 index 00000000..dd63a4af --- /dev/null +++ b/commands/text-edit/snake-speak.js @@ -0,0 +1,28 @@ +const Command = require('../../structures/Command'); + +module.exports = class SnakeSpeakCommand extends Command { + constructor(client) { + super(client, { + name: 'snake-speak', + aliases: ['snek-speak'], + group: 'text-edit', + memberName: 'snake-speak', + description: 'Convertsssss text to sssssnake ssssspeak.', + args: [ + { + key: 'text', + prompt: 'What text would you like to convert to sssssnake ssssspeak?', + type: 'string', + validate: text => { + if (text.replace(/s/gi, 'sssss').length < 2000) return true; + return 'Invalid text, your text is too long.'; + } + } + ] + }); + } + + run(msg, { text }) { + return msg.say(text.replace(/s/gi, 'sssss')); + } +}; diff --git a/commands/text-edit/temmie.js b/commands/text-edit/temmie.js index 9831ac86..bb1871b8 100644 --- a/commands/text-edit/temmie.js +++ b/commands/text-edit/temmie.js @@ -6,6 +6,7 @@ module.exports = class TemmieCommand extends Command { constructor(client) { super(client, { name: 'temmie', + aliases: ['temmie-speak'], group: 'text-edit', memberName: 'temmie', description: 'Converts text to Temmie speak.', diff --git a/package.json b/package.json index 84868724..c71dfa48 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "xiaobot", - "version": "42.1.0", + "version": "42.2.0", "description": "Your personal server companion.", "main": "Shard.js", "scripts": {