Advertisement
julienanid

Rules command

Jan 20th, 2013
254
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.76 KB | None | 0 0
  1. #include "ScriptPCH.h"
  2. #include "Chat.h"
  3.  
  4. class rulescommand : public CommandScript
  5. {
  6. public:
  7.     rulescommand() : CommandScript("rulescommand") { }
  8.  
  9.  ChatCommand* GetCommands() const
  10.     {
  11.         static ChatCommand IngameCommandTable[] =
  12.         {
  13.         { "rules",           SEC_PLAYER,         true,  &HandleRulesCommand,                "", NULL },
  14.         { NULL,             0,                  false, NULL,                              "", NULL }
  15.         };
  16.                  return IngameCommandTable;
  17.     }
  18.  
  19.         static bool HandleRulesCommand(ChatHandler * handler, const char * args)
  20.     {
  21.  
  22.  
  23. handler->PSendSysMessage("|cffB400B4TEST!");
  24.                 return true;
  25.  
  26.     }
  27. };
  28.  
  29. void AddSC_rulescommand()
  30. {
  31.     new rulescommand();
  32. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement