0.1.6 • Published 3 years ago

weirdhub v0.1.6

Weekly downloads
-
License
ISC
Repository
-
Last release
3 years ago

weirdhub

any issues?

Join the support server

Content:

Installation:

npm i weirdhub

or

npm install weirdhub

SnakeGame

const { snakegame } = require("weirdhub");

const { Client } = require("discord.js");
const client = new Client();

client.on("message", (message) => {
  if (message.content.startsWith("!snake")) {
   new snakegame({
    message: message,
    embed: {
    title: 'Snake', //embed title
    color: "#gt4668", //embed color
    gameOverTitle: "Game Over", //game over embed title
    },
    emojis: {
      empty: '⬛', //zone emoji
      snakeBody: '🟩', //snake
      food: '🍎', //food emoji
      //control
      up: '⬆️', 
      right: '⬅️',
      down: '⬇️',
      left: '➡️',
      },
    }).start()
  }
});

client.login("your token");

This function requires discord-buttons

Emojify

const { emojify } = require("weirdhub");

emojify("Hi");

flip

const { flip } = require("weirdhub");
flip("Hi"); // output = Hᴉ

WouldYouRather

const { WouldYouRather } = require("weirdhub");

const { Client } = require("discord.js");
const client = new Client();

client.on("message", async (message) => {
  if (message.content.startsWith("!snake")) {
    await WouldYouRather(message);
  }
});

client.login("your token");

This function requires discord-buttons

Sudo

const { sudo } = require('weirdhub');
const user = message.mentions.members.first();
const msg = args.slice(1).join(" ");
const sud = new sudo({
    message: message,
    text: msg,
    member: user,
});
sud.start();

RockPaperScissors

const opponent = message.mentions.users.first();
if(!opponent) return message.channel.send(`please mention the user that you want to fight with`);
const { rps } = require('weirdhub')
const game = new rps({
    message: message,
    opponent: opponent, // DO NOT CHANGE THIS
    challenger: message.author, // DO NOT CHANGE THIS
    acceptmessage: "click to fight with <@" + message.author + '> at RockPaperScissors', // message that the bot will send to see if opponent accepts
})
game.start() // start the game

This function requires discord-buttons

Biggify

const { biggify } = require('weirdhub')
const { Client } = require("discord.js");
const client = new Client();

client.on("message", async (message) => {
  if (message.content.startsWith("!biggify")) {
    const msg = args.slice(1).join(" ");
    const big = biggify(`${msg}`)
    message.channel.send(`\`\`\`${big}\`\`\``) // do not remove the \`\`\` \`\`\`
  }
});

client.login("your token");

output:

  _     _ 
 | |__ (_)
 | '_ \| |
 | | | | |
 |_| |_|_|

This function requires figlet

0.1.6

3 years ago

0.1.5

3 years ago

0.1.4

3 years ago

0.1.3

3 years ago

0.1.2

3 years ago

0.1.1

3 years ago

0.1.0

3 years ago

0.0.8

3 years ago

0.0.6

3 years ago

0.0.5

3 years ago