initial commit

This commit is contained in:
Darius
2025-09-26 13:41:46 +02:00
commit 9a961363f3
17 changed files with 1553 additions and 0 deletions

View File

@@ -0,0 +1,7 @@
import { Collection } from "@discordjs/collection";
import { SongCommand } from "./command-song.ts";
import type { ICommand } from "./interface.ts";
export const commands = new Collection<string, ICommand>();
commands.set(SongCommand.name, new SongCommand());

View File

@@ -0,0 +1,23 @@
import type { ChatUserstate, Client } from "tmi.js";
import type { ICommand, ICommandRequirements } from "./interface.ts";
export class SongCommand implements ICommand {
name = "song";
cooldown = 0;
enabled = true;
requirements: ICommandRequirements = {
developer: true,
mod: false,
};
triggered = async (
client: Client,
channel: string,
_state: ChatUserstate,
_message: string,
_args: Array<string>,
) => {
client.say(channel, "testing");
};
}

12
src/commands/interface.ts Normal file
View File

@@ -0,0 +1,12 @@
export interface ICommand {
name: string;
cooldown: number;
enabled: boolean;
triggered(...args: unknown[]): Promise<unknown>;
requirements: ICommandRequirements;
}
export interface ICommandRequirements {
developer: boolean;
mod: boolean;
}