aboutsummaryrefslogtreecommitdiff
path: root/src/server/scripts/Commands
diff options
context:
space:
mode:
authorTraesh <traesh@farahlon.com>2017-12-17 14:40:04 +0100
committerShauren <shauren.trinity@gmail.com>2017-12-31 23:22:55 +0100
commit89c91c271b94f34076be7256378610a2a45c9ed2 (patch)
tree71a2d1751039924a66ebfdb33408695f0cd51d3b /src/server/scripts/Commands
parent5dd686c080723eeeefdabb50b867f9f662d5deb9 (diff)
Core/Quests: Implemented player choices
* Implemented SPELL_EFFECT_LAUNCH_QUEST_CHOICE * Script hook for player choices
Diffstat (limited to 'src/server/scripts/Commands')
-rw-r--r--src/server/scripts/Commands/cs_debug.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/server/scripts/Commands/cs_debug.cpp b/src/server/scripts/Commands/cs_debug.cpp
index ec9c4811e4c..57ae2f6ad20 100644
--- a/src/server/scripts/Commands/cs_debug.cpp
+++ b/src/server/scripts/Commands/cs_debug.cpp
@@ -71,6 +71,7 @@ public:
{ "sellerror", rbac::RBAC_PERM_COMMAND_DEBUG_SEND_SELLERROR, false, &HandleDebugSendSellErrorCommand, "" },
{ "setphaseshift", rbac::RBAC_PERM_COMMAND_DEBUG_SEND_SETPHASESHIFT, false, &HandleDebugSendSetPhaseShiftCommand, "" },
{ "spellfail", rbac::RBAC_PERM_COMMAND_DEBUG_SEND_SPELLFAIL, false, &HandleDebugSendSpellFailCommand, "" },
+ { "playerchoice", rbac::RBAC_PERM_COMMAND_DEBUG_SEND_PLAYER_CHOICE, false, &HandleDebugSendPlayerChoiceCommand, "" },
};
static std::vector<ChatCommand> debugCommandTable =
{
@@ -245,6 +246,18 @@ public:
return true;
}
+ static bool HandleDebugSendPlayerChoiceCommand(ChatHandler* handler, char const* args)
+ {
+ if (!*args)
+ return false;
+
+ int32 choiceId = atoi(args);
+ Player* player = handler->GetSession()->GetPlayer();
+
+ player->SendPlayerChoice(player->GetGUID(), choiceId);
+ return true;
+ }
+
static bool HandleDebugSendEquipErrorCommand(ChatHandler* handler, char const* args)
{
if (!*args)