gbotjs

0.0.3 • Public • Published

gBotJS

gBotJS stands for global bot javascript. It tries to mean that you only need one framework to make bots for multiple platforms.

(Discord and Minecraft are supported by default)

Getting started

To install and use gBotJS in your project, do:

npm install gbotjs

It will do the installing.

Now you can use gBotJS. For example:

const gbot = require("gbotjs");
 
gbot.command("example", (user, args, reply, platform, nativeMsg) => {
    reply(`${user} is saying ${args.join(" ")} and is using ${platform}`);
    console.log(nativeMsg);
});
 
gbot.start({
    prefix: "!",
    separator: " ",
    discord: {
        disabled: false,
        token:
            "Discord Bot Token, from https://discordapp.com/developers/applications"
    },
    minecraft: {
        disabled: false,
        host: "server ip, for example play.hypixel.net",
        port: 25565,
        name: "Username"
    }
});

This will start a bot, that when you do

!example gBotJS is great

it says your name, the things you said, and your platform, for example:

Manen is saying gBotJS is great and is using discord

and on the console, it will log a discord.js Message instance.

Package Sidebar

Install

npm i gbotjs

Weekly Downloads

1

Version

0.0.3

License

MIT

Unpacked Size

7.39 kB

Total Files

10

Last publish

Collaborators

  • werymanen