import { Events } from "discord.js"; import { userService } from "@/modules/user/user.service"; import { levelingService } from "@/modules/leveling/leveling.service"; import type { Event } from "@lib/types"; const event: Event = { name: Events.MessageCreate, execute: async (message) => { if (message.author.bot) return; if (!message.guild) return; const user = await userService.getUserById(message.author.id); if (!user) return; levelingService.processChatXp(message.author.id); // Activity Tracking for Lootdrops // We do dynamic import to avoid circular dependency issues if any, though likely not needed here. // But better safe for modules. Actually direct import is fine if structure is clean. import("@/modules/economy/lootdrop.service").then(m => m.lootdropService.processMessage(message)); }, }; export default event;