@m3rcena/weky
TypeScript icon, indicating that this package has built-in type declarations

10.1.0 • Public • Published

Weky

A fun npm package to play games within Discord with buttons!


Made with love in Greece Made with TypeScript
NPM version NPM downloads Get Started Now
npm install lavalink-client



Install

Latest stable Version: v10.1.0

👉 via NPM
npm install --save @m3rcena/weky

Documentation

Check out the Documentation

Used in:

Features

  • 🧑 Beginner friendly

  • 🎉 Easy to use

  • 🔘 Discord Buttons

  • 🤖 Supports Discord.js v14

  • ✂ Fully Customizable

  • and much more!

Usage 📚

👉 CommonJS
const { Client, GatewayIntentBits } = require("discord.js");

const { WekyManager }= require("@m3rcena/weky");

const client = new Client({
    intents: [
        GatewayIntentBits.Guilds,
        GatewayIntentBits.GuildMessages,
        GatewayIntentBits.MessageContent,
    ]
});

client.on("ready", async (cl) => {
    console.log("Bot is ready");
    client.wekyManager = new WekyManager(cl); // Initialize Weky Manager
});

client.on("messageCreate", async (message) => {
    if (message.author.bot) return;
    if (message.content === "w!calculator") {
        client.wekyManager.createCalculator({
            interaction: message,
            client: client,
            embed: {
                color: "Blurple",
                title: "Calculator | M3rcena Development",
                timestamp: new Date(),
            }
        })
    };
});

client.login('Your bot Token');
👉 ESM (Module)
import { Client, GatewayIntentBits } from "discord.js";

import { WekyManager } from "@m3rcena/weky";

export interface ExtendedClient extends Client {
    wekyManager: WekyManager;
};

const client = new Client({
    intents: [
        GatewayIntentBits.Guilds,
        GatewayIntentBits.GuildMessages,
        GatewayIntentBits.MessageContent,
    ]
}) as ExtendedClient;

client.on("ready", async (cl) => {
    console.log("Bot is ready");
    client.wekyManager = new WekyManager(cl); // Initialize Weky Manager
});

client.on("messageCreate", async (message) => {
    if (message.author.bot) return;
    if (message.content === "w!calculator") {
        client.wekyManager.createCalculator({
            interaction: message,
            client: client,
            embed: {
                color: "Blurple",
                title: "Calculator | M3rcena Development",
            }
        })
    };
});

client.login("Your bot token");

Result 📤

Contributing 🤝

  • Contributions, issues and feature requests are welcome!
  • Feel free to check issues page

Support ❔

<iframe src="https://discord.com/widget?id=1224358764463783987&theme=dark" width="350" height="350" allowtransparency="true" frameborder="0" sandbox="allow-popups allow-popups-to-escape-sandbox allow-same-origin allow-scripts"></iframe>

Developers 👨‍💻

Contributors



Readme

Keywords

Package Sidebar

Install

npm i @m3rcena/weky

Weekly Downloads

573

Version

10.1.0

License

ISC

Unpacked Size

663 kB

Total Files

108

Last publish

Collaborators

  • d4rk.s0ul