Skip to content

nilenta/natsu-bot-framework

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

natsu's hummus bot framework

This is the "framework" I made for natsubot, on hummus.

Feel free to modify.

Please read the eris docs, you people using this are probably random 12 year olds with no prior coding knowledge.

Before doing anything, rename .env.example to .env

how 2 run

To run this, download the code, and then place it in a folder.

Open terminal, then run

npm i

This will install all required libraries. After done installing, edit the .env file and add your hummus bot token.

DO NOT FORGET TO ADD A PREFIX

After modifying .env, you can run the bot by running

npm start

how do i add stuff

In the src folder, there are two folders. "commands" and "events"

You can add events by making a file with the event name and adding this code into it

Heres a useful link for a list of events, all events are from callCreate to the bottom.

module.exports = {
    async execute(client) {
        // Code that will execute on the event
    },
}

Put your code in the execute function, it will run when that event is fired.

There is already a command handler in the events folder under messageCreate.js.

yeah but how do i add commands

In the commands folder, add a js file, name it whatever you want the command to be called. For example, lets say I want to make a command called help.

If I want it to say "You need help? I gotchu bro" I would add this:

module.exports = {
    async execute(client, message, args) {
        await message.channel.createMessage('You need help? I gotchu bro')
    },
}

This will execute when the user runs the help command, BE SURE TO ADD YOUR OWN PREFIX IN THE .env FILE

hi i need help with this

Dm me on discord, my username is "nilenta"

Alternatively, you can dm me on hummus, my hummus tag is "natsu#1863"

cinnamoroll-RIFE4.6-4x-119.88fps.mp4