Files
xiao/commands/text-edit/organization-xiii-name.js
T
Daniel Odendahl Jr 7560246f26 Update to latest
2017-11-02 22:42:12 +00:00

31 lines
834 B
JavaScript

const { Command } = require('discord.js-commando');
const { shuffle } = require('../../util/Util');
module.exports = class OrganizationXIIINameCommand extends Command {
constructor(client) {
super(client, {
name: 'organization-xiii-name',
aliases: ['org-xiii-name', 'xiii-name', 'nobody-name', 'organization-xiii', 'org-xiii', 'xiii'],
group: 'text-edit',
memberName: 'organization-xiii-name',
description: 'Converts a name into the Organization XIII style.',
args: [
{
key: 'text',
prompt: 'What name would you like to convert?',
type: 'string',
max: 1950,
parse: text => text.toLowerCase().split('')
}
]
});
}
run(msg, { text }) {
text.push('x');
const shuffled = shuffle(text);
shuffled[0] = shuffled[0].toUpperCase();
return msg.say(shuffled.join(''));
}
};