moover_rust/src/commands/user_interactions/headpat.rs

20 lines
No EOL
536 B
Rust

use poise;
use serenity::all::User;
use super::interaction::send_with_embed;
use crate::types::{Error, Context};
#[poise::command(
slash_command,
description_localized("en-US", "Headpat all your friends!")
)]
pub async fn headpat(ctx: Context<'_>,
#[description = "Who is the lucky one?"]
user: User
) -> Result<(), Error> {
let title = "HEADPATS!";
let desc = format!("{} headpats {}", ctx.author(), user);
send_with_embed(ctx, "headpat", &title, &desc).await?;
ctx.reply("Done!").await?;
Ok(())
}