feat: split out minecraft
This commit is contained in:
parent
41407ecefb
commit
3927734083
6 changed files with 182 additions and 165 deletions
|
@ -16,9 +16,10 @@ pub(crate) mod user {
|
|||
use super::*;
|
||||
use crate::commands::link_email::link::get_server_member_discord;
|
||||
use serenity::model::id::UserId;
|
||||
use skynet_discord_bot::{whitelist_update, Config};
|
||||
use skynet_discord_bot::Config;
|
||||
use sqlx::Error;
|
||||
use skynet_discord_bot::common::database::{Minecraft, Wolves};
|
||||
use skynet_discord_bot::common::database::Wolves;
|
||||
use skynet_discord_bot::common::minecraft::{whitelist_update, Minecraft};
|
||||
|
||||
pub fn register(command: &mut CreateApplicationCommand) -> &mut CreateApplicationCommand {
|
||||
command.name("link_minecraft").description("Link your minecraft account").create_option(|option| {
|
||||
|
@ -123,8 +124,9 @@ pub(crate) mod server {
|
|||
use sqlx::Error;
|
||||
// this is to managfe the server side of commands related to minecraft
|
||||
use super::*;
|
||||
use skynet_discord_bot::{is_admin, update_server, Config};
|
||||
use skynet_discord_bot::common::database::Minecraft;
|
||||
use skynet_discord_bot::{is_admin, Config};
|
||||
use skynet_discord_bot::common::minecraft::Minecraft;
|
||||
use skynet_discord_bot::common::minecraft::update_server;
|
||||
|
||||
pub fn register(command: &mut CreateApplicationCommand) -> &mut CreateApplicationCommand {
|
||||
command.name("minecraft_add").description("Add a minecraft server").create_option(|option| {
|
||||
|
@ -203,8 +205,9 @@ pub(crate) mod server {
|
|||
use serenity::builder::CreateApplicationCommand;
|
||||
use serenity::client::Context;
|
||||
use serenity::model::prelude::application_command::ApplicationCommandInteraction;
|
||||
use skynet_discord_bot::{get_minecraft_config_server, is_admin, server_information, Config};
|
||||
use skynet_discord_bot::{is_admin, Config};
|
||||
use skynet_discord_bot::common::database::DataBase;
|
||||
use skynet_discord_bot::common::minecraft::{get_minecraft_config_server, server_information};
|
||||
|
||||
pub fn register(command: &mut CreateApplicationCommand) -> &mut CreateApplicationCommand {
|
||||
command.name("minecraft_list").description("List your minecraft servers")
|
||||
|
@ -267,7 +270,8 @@ pub(crate) mod server {
|
|||
use serenity::model::prelude::application_command::{ApplicationCommandInteraction, CommandDataOptionValue};
|
||||
use skynet_discord_bot::is_admin;
|
||||
use sqlx::{Error, Pool, Sqlite};
|
||||
use skynet_discord_bot::common::database::{DataBase, Minecraft};
|
||||
use skynet_discord_bot::common::database::DataBase;
|
||||
use skynet_discord_bot::common::minecraft::Minecraft;
|
||||
|
||||
pub fn register(command: &mut CreateApplicationCommand) -> &mut CreateApplicationCommand {
|
||||
command.name("minecraft_delete").description("Delete a minecraft server").create_option(|option| {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue