All pastes #752782 Raw Edit

Someone

public text v1 · immutable
#752782 ·published 2007-10-28 18:59 UTC
rendered paste body
#include "StdAfx.h"
#include "Setup.h"

	class OrbOfCommand : public GameObjectAIScript
      {
      public:
              OrbOfCommand(GameObject* goinstance) : GameObjectAIScript(goinstance) {}
              void OnActivate(Player * pPlayer)
              {
				    if(pPlayer->HasFinishedQuest(7761) && pPlayer->getLevel() >= 58 && pPlayer->InGroup() == 1)
					{
                      pPlayer->SafeTeleport(469, 0, -7672.939941, -1107.307617, 396.649994, 0.616532);
					}
					else if(pPlayer->getLevel() <= 57 || pPlayer->HasFinishedQuest(7761) == 0)
					{
					pPlayer->BroadcastMessage("You need to be level 58 and have completed the quest : Blackhand's Command");	
					}
					else if(pPlayer->HasFinishedQuest(7761) && pPlayer->getLevel() >= 58 && pPlayer->InGroup() == 0);
					{
					pPlayer->BroadcastMessage("You need to be in a raid group to be able to enter this instance");
					}
              }
              static GameObjectAIScript *Create(GameObject * GO) { return new OrbOfCommand(GO); }
      };
      GameObjectAIScript * create_go(GameObject * GO) { return new OrbOfCommand(GO); }

	  void SetupSCRIPT(ScriptMgr * mgr)
      {
              mgr->register_gameobject_script(179879, &OrbOfCommand::Create);
      }