added createEmbed

This commit is contained in:
2025-01-07 00:31:01 +01:00
parent 78a65511c2
commit 62b3eb070b
8 changed files with 252 additions and 37 deletions

View File

@@ -17,10 +17,10 @@ import config from "config";
import { WaterMeService } from "actions/waterMe/waterMe.service";
import { MedicationService } from "actions/medication/medication.service";
import { HelpService } from "actions/help/help.service";
import { custom } from "zod";
import { GreetingService } from "actions/greeting/greeting.service";
import { ActivityService } from "actions/activity/activity.service";
import { DmService } from "actions/dm/dm.service";
import { EmbedService } from "actions/embed/embed.service";
export default class DiscordController extends EventEmitter {
private discordService!: DiscordService;
@@ -30,6 +30,7 @@ export default class DiscordController extends EventEmitter {
helpService: HelpService;
activityService: ActivityService;
dmService: DmService;
embedService: EmbedService;
constructor() {
super();
@@ -40,6 +41,7 @@ export default class DiscordController extends EventEmitter {
this.helpService = new HelpService();
this.activityService = new ActivityService();
this.dmService = new DmService();
this.embedService = new EmbedService();
// log when running
client.once("ready", async () => {
await this.setActivity();
@@ -124,6 +126,12 @@ export default class DiscordController extends EventEmitter {
case Commands.Enum.accept:
await this.greetingService.handleInteraction(interaction);
return;
case Commands.Enum.welcome:
await this.greetingService.handleInteraction(interaction);
return;
case Commands.Enum.embed:
await this.embedService.handleInteraction(interaction);
return;
default:
break;
}