feat: adding color changing
This commit is contained in:
parent
28ed823e2b
commit
680eeea7a1
4 changed files with 7 additions and 2 deletions
1
src/commands/colorAlterChange.ts
Normal file
1
src/commands/colorAlterChange.ts
Normal file
|
@ -0,0 +1 @@
|
|||
export async function colorAlterChange(userId: string, args: string[]){}
|
1
src/commands/colorAlterChange.ts~
Normal file
1
src/commands/colorAlterChange.ts~
Normal file
|
@ -0,0 +1 @@
|
|||
export function colorAlterChange(userId: string, args: string[]){}
|
|
@ -13,10 +13,11 @@ client.on("ready", async () => {
|
|||
client.on("messageCreate", async (message: Message) => {
|
||||
try{if (!message.author) {await client.users.fetch(message.authorId)} }
|
||||
catch(e){console.log(e)}
|
||||
|
||||
|
||||
if (message === undefined) {return}
|
||||
if (message.author?.bot) {}
|
||||
else {
|
||||
if (message?.content.startsWith(config.prefix)) {
|
||||
if (message.content.startsWith(config.prefix)) {
|
||||
commandHandler(message, config.prefix);
|
||||
}
|
||||
else {
|
||||
|
|
|
@ -4,6 +4,7 @@ import { listAlters } from "../commands/listAlters"
|
|||
import { createAlter } from "../commands/createAlter"
|
||||
import { deleteAlter } from "../commands/deleteAlter"
|
||||
import { avatarAlterChange } from "../commands/avatarAlterChange"
|
||||
import { colorAlterChange } from "../commands/colorAlterChange"
|
||||
import { split } from "shlex"
|
||||
|
||||
export async function commandHandler(message : Message, prefix : String) {
|
||||
|
@ -34,6 +35,7 @@ export async function commandHandler(message : Message, prefix : String) {
|
|||
break
|
||||
}
|
||||
case "color" : {
|
||||
await message.reply(await colorAlterChange(message.author.id, args));
|
||||
break
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue