Add documentation to gambling commands
This commit is contained in:
@@ -2,6 +2,7 @@ use super::get_user_wealth_mut;
|
||||
use crate::common::{Context, Error};
|
||||
use poise::serenity_prelude as serenity;
|
||||
|
||||
/// Tells you what your or someone else's balance is
|
||||
#[poise::command(slash_command, prefix_command)]
|
||||
pub async fn balance(ctx: Context<'_>, user: Option<serenity::User>) -> Result<(), Error> {
|
||||
let user = user.as_ref().unwrap_or(ctx.author());
|
||||
|
||||
@@ -2,6 +2,7 @@ use crate::{Context, Error};
|
||||
use super::get_user_wealth_mut;
|
||||
use poise::serenity_prelude as serenity;
|
||||
|
||||
/// Generously donate your tokens to someone else
|
||||
#[poise::command(slash_command, prefix_command)]
|
||||
pub async fn give(ctx: Context<'_>, user: serenity::User, amount: usize) -> Result<(), Error> {
|
||||
if user.bot {
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
use crate::common::{Context, Error};
|
||||
use super::get_user_wealth_mut;
|
||||
|
||||
/// Put forward an amount of tokens to either lose or earn
|
||||
#[poise::command(slash_command, prefix_command)]
|
||||
pub async fn wager(ctx: Context<'_>, amount: usize) -> Result<(), Error> {
|
||||
let mut users = ctx.data().users.lock().await;
|
||||
|
||||
Reference in New Issue
Block a user