1.0.8 • Published 4 years ago
showdown.js v1.0.8
Showdown.js
About
Showdown.js is a module that allows you to easily create a bot for Pokemon Showdown
Instalation
npm install showdown.js
Example
'use strict';
const Client = require('showdown.js').Client;
let client = new Client({
name: 'yourbotname',
pass: 'yourpassword',
baseRooms: ['lobby'],
port: 8000,
host: 'sim.smogon.com',
});
client.on('message', msg => {
if (msg.content === 'ping') {
msg.source.send('Pong!');
}
});
client.connect();