1.0.7 • Published 4 years ago

snakemegumin v1.0.7

Weekly downloads
-
License
ISC
Repository
github
Last release
4 years ago

Snakemeg

Snakemeg te dá mais configurabilidade que a Snakecord.

Instalação

npm install snakemeg
yarn add snakemeg

Exemplo

const SnakeGame = require('snakemeg');

const snakeGame = new SnakeGame({
    title: 'Snake Game',
    color: "GREEN",
    field: "⬛",
    fruit: "🍎",
    animal: "🐍",
    thumbnail: message.author.avatarURL(),
    timestamp: false,
    gameOverTitle: "Game Over"
});

client.on('message', message => {
    if(!message.content.startsWith(config.prefix) || message.author.bot) return;

    const args = message.content.slice(config.prefix.length).trim().split(/ +/);
    const command = args.shift().toLowerCase();

   if(command === 'snake' || command === 'snakegame') {
        return snakeGame.newGame(message);
    })
  }
1.0.7

4 years ago