diff --git a/src/command/mod.rs b/src/command/mod.rs index c7057d6..bc8e79b 100644 --- a/src/command/mod.rs +++ b/src/command/mod.rs @@ -8,7 +8,8 @@ pub enum Selector { AllPlayers, // @a AllEntities, // @e Executor, // @s - NearestEntity // @n + NearestEntity, // @n, + Player(String) } impl Display for Selector { @@ -19,7 +20,8 @@ impl Display for Selector { Self::AllPlayers => write!(f, "@a"), Self::AllEntities => write!(f, "@e"), Self::Executor => write!(f, "@s"), - Self::NearestEntity => write!(f, "@n") + Self::NearestEntity => write!(f, "@n"), + Self::Player(name) => write!(f, "{name}") } } } @@ -27,6 +29,7 @@ impl Display for Selector { mod say; mod list; mod kill; +mod ban; impl Command { pub fn raw(cmd: &str) -> Self { @@ -48,4 +51,8 @@ impl Command { pub fn kill() -> kill::KillCommand { kill::KillCommand::default() } + + pub fn ban() -> ban::BanCommand { + ban::BanCommand::default() + } } \ No newline at end of file