Client - liam-gen/discord.easy.js GitHub Wiki
const Client = new Discord.Bot(lang, prefix)
Functions
constructor
login
logout
on
setStatus
Events
message
start
constructor(lang, prefix)
| PARAMETER |
TYPE |
OPTIONAL |
DEFAULT |
DESCRIPTION |
| lang |
String |
no |
en |
Set the bot's language |
| prefix |
String |
no |
none |
Set the bot's prefix |
.login(token)
| PARAMETER |
TYPE |
OPTIONAL |
DEFAULT |
DESCRIPTION |
| token |
String |
no |
none |
Set the bot's token and login the bot in discord |
.logout()
| DESCRIPTION |
| Disconnect the bot |
.on(action, callback)
| PARAMETER |
TYPE |
OPTIONAL |
DEFAULT |
| action |
Event |
no |
none |
.setStatus(text)
| PARAMETER |
TYPE |
OPTIONAL |
DEFAULT |
DESCRIPTION |
| text |
String |
no |
none |
Set the bot's status |
Events
message
| OPTIONS |
DESCRIPTION |
| message |
Return the sent message |
| auhtor |
Return the author of the sent message message |
| channel |
Return the channel of the sent message |
| args |
Return the arguments of the send message. Example: ('hello', 'how', 'are', you' '?') |
| command |
Returns the command used. Example: ping |
start
| OPTIONS |
DESCRIPTION |
| client |
Return the bot's client |