Add a cutie to owner list, update embed and ship commands
This commit is contained in:
parent
a78e7a7d08
commit
3d28bf8f56
10
src/main.rs
10
src/main.rs
|
@ -55,7 +55,7 @@ fn main() {
|
|||
StandardFramework::new()
|
||||
.configure(|c| {
|
||||
c.with_whitespace(true)
|
||||
.owners(vec![UserId(254310746450690048)].into_iter().collect())
|
||||
.owners(vec![UserId(254310746450690048), UserId(687740609703706630)].into_iter().collect())
|
||||
.prefixes(vec!["owo ", "OwO "])
|
||||
.no_dm_prefix(true)
|
||||
.case_insensitivity(true)
|
||||
|
@ -163,7 +163,6 @@ fn host(ctx: &mut Context, message: &Message) -> CommandResult {
|
|||
}
|
||||
|
||||
#[command]
|
||||
#[checks(Owner)]
|
||||
fn embed(ctx: &mut Context, message: &Message, args: Args) -> CommandResult {
|
||||
use serde::Deserialize;
|
||||
use serenity::utils::Colour;
|
||||
|
@ -261,16 +260,19 @@ fn embed(ctx: &mut Context, message: &Message, args: Args) -> CommandResult {
|
|||
m
|
||||
});
|
||||
|
||||
let _ = message.channel_id.say(&ctx.http, format!("Embed requested by: {}", message.author));
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
#[command]
|
||||
fn bottom_rng(ctx: &mut Context, message: &Message) -> CommandResult {
|
||||
fn bottom_rng(ctx: &mut Context, message: &Message, mut args: Args) -> CommandResult {
|
||||
use rand::{rngs::StdRng, SeedableRng};
|
||||
|
||||
let num = args.single::<u64>().unwrap_or(10);
|
||||
let messages = message
|
||||
.channel_id
|
||||
.messages(&ctx.http, |get| get.before(message.id).limit(20));
|
||||
.messages(&ctx.http, |get| get.before(message.id).limit(num));
|
||||
if let Err(e) = messages {
|
||||
let _ = message.channel_id.say(&ctx.http, format!("Error: {}", e));
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue