mirror of
https://github.com/HappyTanuki/BumbleCee.git
synced 2025-10-28 02:25:13 +00:00
코드 갈어엎기(사용성 개박살났으니 빌드는 이전 것으로 할 것.)
This commit is contained in:
@@ -2,25 +2,23 @@
|
||||
#include <dpp/dpp.h>
|
||||
#include <string>
|
||||
|
||||
commands::Repeat::Repeat(std::shared_ptr<dpp::cluster> botCluster, std::unordered_map<dpp::snowflake, std::shared_ptr<MusicQueue>> *queueMap)
|
||||
: VCCommand(botCluster)
|
||||
commands::Repeat::Repeat(dpp::snowflake botID, BumbleCeepp* Bot)
|
||||
: ICommand(botID, Bot)
|
||||
{
|
||||
this->queueMap = queueMap;
|
||||
dpp::slashcommand command = dpp::slashcommand("r", "반복 켜기/끄기", botCluster->me.id);
|
||||
dpp::slashcommand command = dpp::slashcommand("r", "반복 켜기/끄기", botID);
|
||||
|
||||
commandObjectVector.push_back(command);
|
||||
}
|
||||
|
||||
void commands::Repeat::operator()(const dpp::slashcommand_t& event) {
|
||||
std::shared_ptr<MusicQueue> queue = getQueue(event);
|
||||
|
||||
if (queue->repeat) {
|
||||
|
||||
if (Bot->repeat) {
|
||||
event.reply("반복을 껐습니다.");
|
||||
queue->repeat = false;
|
||||
Bot->repeat = false;
|
||||
}
|
||||
else {
|
||||
event.reply("반복을 켰습니다.");
|
||||
queue->repeat = true;
|
||||
Bot->repeat = true;
|
||||
}
|
||||
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user