* Front Page * Table of Contents * Return to Town

hyperium

Owner: ~hyper

Commands

To get info about how to use the bot, say ;help in a channel where the bot can see you. You can do ;list to get a list of modules.

Modules

hyperium uses a system of modules, where each module/plugin registers some commands, then the user can use them.

Example

Here is an example module that can be placed inside any of the "plugin directories" which plugins will be loaded from:

MyPlugin/ - plugin.js - ... extra files/assets that your plugin will use

Example content for plugin.js:

export default class MyPlugin { register(hyperium) { /* This is where you register commands and other things. */ hyperium.command('echo', e => { // 'e' is the event object containing data and functions for this specific command run e.reply(`${e.from} said: ${e.arg}`); }); /* 'special' commands will not have the bot's prefix, you would say `!fail` to use this command */ hyperium.special('!fail', e => { /* throws will be caught and displayed */ throw new Error('some error!'); }); /* 'matchers' are regular expressions which will run when it matches a message */ hyperium.match(/^hi, (.*)$/, (e, match) => { /* match: the RegExpMatchArray for the regex */ e.reply('hi!') }) } }

Yum

yum is hyperium's backend, it provides services such as storage and authentication.

Source

hyperium isn't open-source yet, however it will be free open-source software when it is ready for use. hyperium is written in TypeScript and run in Node.JS


last compiled: 2024-01-23 01:58:22.544311