easy-games-js
v1.2.1
Published
This package is coded by Tovade#0001. Please do not steal this package or recreate it!
Downloads
169
Readme
#ez-games-js
This package is coded by Tovade#0001. Please do not steal this package or recreate it!
tictactoe example:
const Discord = require('discord.js')
const client = new Discord.Client()
const { tictactoe } = require('easy-games-js')
const prefix = "!" client.on('message', (message) => {
if(message.content.startsWith(`${prefix}tictactoe`)) {
const tic = new tictactoe(message.members.mentions.first(), message)
tic.init({ PROVIDE_MEMBER: "Please provide a member", ACCEPT_CHALLENGE: "{user} Do you accept this challange?", DOESNT_PLAY: "looks like {user} doesnt wanna play", WICH_SIDE: "**{user}, Which Side Do You Pick? Type \`End\` To Forfeit!**", GAME_OVER: "Times up!", END: "end", INACTIVITY: "game ended due to inactivity!", WINNER: "Congrats u have won {winner}", DRAW: "Its a draw"})
}
//translations are not required just optional!
})
const Discord = require('discord.js')
const client = new Discord.Client()
const { akinator } = require('easy-games-js')
const prefix = "!"
client.on('message', (message) => {
const args = message.content.slice(prefix).slice().split(/ +/)
if(message.content.startsWith(`${prefix}akinator`)) {
const aki = new akinator(message, args)
aki.init()
//unable to translate keep in mind!
}
})
const Discord = require("discord.js");
const client = new Discord.Client();
const { rps } = require("easy-games-js");
const prefix = "!";
client.on("message", (message) => {
const args = message.content.slice(prefix).slice().split(/ +/);
if (message.content.startsWith(`${prefix}rps`)) {
const rock = new rps(message);
rock.init({ SELECT_REACTION: "**Play A Game of RPS Against The Bot!\nSelect Reactions To Play!**", LOST: "You have lost!", WON: "You have won!", TIE: "Its a tie!", MISSING_PERMISSION: "Missing permissions {permission}!"});
//translations are not required!
}
});
any copies should credit me!