mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-04 15:56:52 +02:00
37 lines
906 B
JavaScript
37 lines
906 B
JavaScript
const Command = require('../../structures/Command');
|
|
const { shuffle, firstUpperCase } = require('../../util/Util');
|
|
|
|
module.exports = class NobodyNameCommand extends Command {
|
|
constructor(client) {
|
|
super(client, {
|
|
name: 'nobody-name',
|
|
aliases: ['organization-name', 'org-name', 'organization-xiii-name'],
|
|
group: 'text-edit',
|
|
memberName: 'nobody-name',
|
|
description: 'Converts a name into the Organization XIII style.',
|
|
credit: [
|
|
{
|
|
name: 'Kingdom Hearts',
|
|
url: 'https://www.kingdomhearts.com/home/us/'
|
|
}
|
|
],
|
|
args: [
|
|
{
|
|
key: 'text',
|
|
prompt: 'What name would you like to convert?',
|
|
type: 'string',
|
|
max: 1950,
|
|
parse: text => text.toLowerCase()
|
|
}
|
|
]
|
|
});
|
|
}
|
|
|
|
run(msg, { text }) {
|
|
const letters = text.split('');
|
|
letters.push('x');
|
|
const shuffled = shuffle(letters);
|
|
return msg.say(firstUpperCase(shuffled.join('')));
|
|
}
|
|
};
|