Discord Blackjack

A way to play blackjack games on Discord.

Easy setup and use

Installation

$ npm i discord-blackjack

Setup

const blackjack = require("discord-blackjack")
// other code here

// if you are using prefix commands
client.on("messageCreate", async message => {
    if (message.content === "!blackjack") {
        blackjack(message)        
    }
})

// if you are using slash commands
client.on("interactionCreate", async interaction => {
    if (!interaction.isCommand) return;
    
    if (interaction.commandName === "blackjack") {
        blackjack(interaction)
    }
})

// other code here

This is only an example.

If you do not know Discord.JS or JavaScript in general, we suggest you to learn it, as unexpected errors may occur if you do not know what you're doing.

Check out or next page to see what changed from v4

Last updated