mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-27 06:37:32 +02:00
Ow
This commit is contained in:
@@ -0,0 +1,37 @@
|
|||||||
|
const { Command } = require('discord.js-commando');
|
||||||
|
|
||||||
|
module.exports = class OwOCommand extends Command {
|
||||||
|
constructor(client) {
|
||||||
|
super(client, {
|
||||||
|
name: 'owo',
|
||||||
|
group: 'text-edit',
|
||||||
|
memberName: 'owo',
|
||||||
|
description: 'OwO.',
|
||||||
|
args: [
|
||||||
|
{
|
||||||
|
key: 'text',
|
||||||
|
prompt: 'What text would you like to OwO?',
|
||||||
|
type: 'string',
|
||||||
|
validate: text => {
|
||||||
|
if (this.owo(text).length < 2000) return true;
|
||||||
|
return 'Invalid text, your text is too long.';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
run(msg, { text }) {
|
||||||
|
return msg.say(this.owo(text));
|
||||||
|
}
|
||||||
|
|
||||||
|
owo(text) {
|
||||||
|
return text
|
||||||
|
.replace(/(?:r|l)/g, 'w')
|
||||||
|
.replace(/(?:R|L)/g, 'W')
|
||||||
|
.replace(/n([aeiou])/g, 'ny$1')
|
||||||
|
.replace(/N([aeiou])/g, 'Ny$1')
|
||||||
|
.replace(/N([AEIOU])/g, 'NY$1')
|
||||||
|
.replace(/ove/g, 'uv');
|
||||||
|
}
|
||||||
|
};
|
||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "xiao",
|
"name": "xiao",
|
||||||
"version": "62.3.0",
|
"version": "62.4.0",
|
||||||
"description": "Your personal server companion.",
|
"description": "Your personal server companion.",
|
||||||
"main": "Xiao.js",
|
"main": "Xiao.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
|||||||
Reference in New Issue
Block a user