Advertisement
julienanid

[Trinity] OnLogin

Sep 28th, 2013
487
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 1.06 KB | None | 0 0
  1. /*
  2. <--------------------------------------------------------------------------->
  3. - Developer(s):  .~I~., QQrofl
  4. - Updated by: Rochet2
  5. - Complete: %100
  6. - ScriptName: 'on_login'
  7. - Comment: Untested.
  8. <--------------------------------------------------------------------------->
  9. */
  10. #include "ScriptPCH.h"
  11. /*
  12. COLORS
  13. */
  14. #define MSG_COLOR "00ff00"
  15. #define NAME_COLOR "00ff00"
  16. /*
  17. WELCOME MSG
  18. */
  19. #define W_MSG "WELCOME BACK ONLINE"
  20. uint32 spellArray[] = { 48161, 48073, 20217, 48469, 16609, 15366, 22888, 57399, 17013, 16612, 24705,
  21. 26035, 31305, 36001, 70235, 70242, 70244, 30090, 30088, 30089 };
  22. class on_login : public PlayerScript
  23. {
  24. public:
  25. on_login() : PlayerScript("on_login") {}
  26. void OnLogin(Player* player)
  27. {
  28. player->GetSession()->SendNotification("|cff"MSG_COLOR"! "W_MSG" |cff"NAME_COLOR"%s|cff"MSG_COLOR" !", player->GetName.c_str());
  29. player->Dismount();
  30. player->RemoveAurasByType(SPELL_AURA_MOUNTED);
  31. for (int i = 0; sizeof(spellArray)/sizeof(*spellArray))
  32. player->AddAura(spellArray[i], player);
  33. }
  34. };
  35. void AddSC_on_login()
  36. {
  37. new on_login();
  38. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement