Skip to content

A Discord bot that allows for casual gambling on sumo wrestling

Notifications You must be signed in to change notification settings

richardtatum/dohyo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DOHYO

Dohyo is a Discord bot for casual gambling on sumo wrestling. In our server, we use the fantastic Twitch channel MidnightSumo to watch the games.

This bot was mostly to see what the experience of using the Discord.NET package was like (spoiler: it was great!), but feel free to use all or any part of it as a reference for creating your own bot.

Prerequisites

Dohyo requires you to provide a token (DISCORD_TOKEN) and a path to where the sqlite database file is to be stored (DB_URI) as environment variables.

Run this locally

Build and run dohyo with Docker:

git clone https://github.com/richardtatum/dohyo.git dohyo
cd dohyo
docker build -t dohyo .
docker run -p 8080:8080 -e DISCORD_TOKEN='valid-bot-token-here' -e DB_URI='path/to/sqlite.db' dohyo:latest

Usage

Once added, Dohyo listens for slash commands in any channel. These commands should be automatically populated by Discord into the command pop-up.

Commands

Dohyo provides the following slash commands out of the box:

/balance

The balance command provides the users current balance available for betting. By default, every user starts with ¥1,000.

image

/fight

The fight command starts a new fight, notifying users and opening the bets to everyone. NOTE: Only an admin can start a fight!

image

/bet

The bet command allows the user to pick a side (left or right) and bet an amount. The amount bet must be less than their current balance for it to work

image

/end

Once everyone has bet, the admin can use the end command, passing the winning side as an argument. This brings the currently open fight to a close and distribute the winnings accordingly.

image

Bonus Commands

These final two commands are mostly made in jest. One person in our server asked why we could tip the adjudicator of the fights (lovingly nicknamed 'The Wizard') after betting, similar to how you would tip the dealer at a poker table. Thus these commands were created.

/tip

The tip command allows any user to gift any amount of their current balance to The Wizard.

image

/wizard

The wizard command shows the current balance of the adjudicator, and just how generous your friends have been!

image

About

A Discord bot that allows for casual gambling on sumo wrestling

Topics

Resources

Stars

Watchers

Forks