diff options
| author | ilotterytea <iltsu@alright.party> | 2025-04-06 18:25:46 +0400 |
|---|---|---|
| committer | ilotterytea <iltsu@alright.party> | 2025-04-06 18:25:46 +0400 |
| commit | d1f8efef4a68f81ca104e9b8f51e04497f3bd8aa (patch) | |
| tree | ce13d90a87fdbe25c8871ff1f39322681cd520b4 /bot/src/commands/command.cpp | |
| parent | 2a49844a95593ac98e919c18651320e62f276fa7 (diff) | |
feat: !ping in lua + bot and time libraries
Diffstat (limited to 'bot/src/commands/command.cpp')
| -rw-r--r-- | bot/src/commands/command.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/bot/src/commands/command.cpp b/bot/src/commands/command.cpp index 97dd88b..baf5a62 100644 --- a/bot/src/commands/command.cpp +++ b/bot/src/commands/command.cpp @@ -21,7 +21,6 @@ #include "../modules/massping.hpp" #include "../modules/mcsrv.hpp" #include "../modules/notify.hpp" -#include "../modules/ping.hpp" #include "../modules/settings.hpp" #include "../modules/spam.hpp" #include "../modules/timer.hpp" @@ -35,7 +34,6 @@ namespace bot { namespace command { CommandLoader::CommandLoader() { - this->add_command(std::make_unique<mod::Ping>()); this->add_command(std::make_unique<mod::Massping>()); this->add_command(std::make_unique<mod::Event>()); this->add_command(std::make_unique<mod::Notify>()); @@ -50,7 +48,11 @@ namespace bot { this->add_command(std::make_unique<mod::MinecraftServerCheck>()); this->luaState = std::make_shared<sol::state>(); - this->luaState->open_libraries(sol::lib::base, sol::lib::string); + this->luaState->open_libraries(sol::lib::base, sol::lib::string, + sol::lib::math); + + lua::library::add_bot_library(this->luaState); + lua::library::add_time_library(this->luaState); } void CommandLoader::load_lua_directory(const std::string &folder_path) { |
