2024-12-21 16:28:32 -05:00
|
|
|
use commands::{
|
|
|
|
ClearCommand, CounterCommand, ExecFile, ExitCommand, HelpCommand, PanicCommmand, ZLua,
|
|
|
|
};
|
2024-12-21 14:35:55 -05:00
|
|
|
use handler::{COMMAND_MANAGER, Category};
|
2024-12-01 23:52:12 -06:00
|
|
|
|
2024-12-19 20:54:46 -05:00
|
|
|
use crate::commands;
|
2024-12-09 20:28:28 -05:00
|
|
|
|
2024-12-19 20:54:46 -05:00
|
|
|
pub mod commands;
|
|
|
|
pub mod handler;
|
2024-12-21 14:35:55 -05:00
|
|
|
pub mod input;
|
2024-12-06 11:19:12 -05:00
|
|
|
|
2024-12-19 20:54:46 -05:00
|
|
|
pub fn setup() {
|
2024-12-21 14:35:55 -05:00
|
|
|
commands!(
|
|
|
|
HelpCommand,
|
|
|
|
ClearCommand,
|
|
|
|
ExitCommand,
|
|
|
|
CounterCommand,
|
2024-12-21 16:28:32 -05:00
|
|
|
PanicCommmand,
|
|
|
|
ZLua
|
2024-12-21 14:35:55 -05:00
|
|
|
);
|
|
|
|
let cat = Category::new("cr", "Core", "Core commands");
|
|
|
|
COMMAND_MANAGER.write().add_category(cat.clone());
|
|
|
|
COMMAND_MANAGER
|
|
|
|
.write()
|
|
|
|
.add_command_with_category(Box::new(ExecFile), cat.clone());
|
2024-12-01 23:52:12 -06:00
|
|
|
}
|