#include "StdAfx.h"
#include "Setup.h"
class Orb_of_Translocation : public GameObjectAIScript
{
public:
Orb_of_Translocation(GameObject* goinstance) : GameObjectAIScript(goinstance) {}
static GameObjectAIScript *Create(GameObject * GO) { return new Orb_of_Translocation(GO); }
void OnActivate(Player * Plr)
{
if(Plr->getRace() == RACE_HUMAN)
Plr->EventTeleport(0, 0, -8949.95, -132.493, 83.5312);
else if(Plr->getRace() == RACE_ORC)
Plr->EventTeleport(1, 0, -618.518, -4251.67, 38.71
;
else if(Plr->getRace() == RACE_DWARF)
Plr->EventTeleport(0, 0, -6240.32, 331.033, 382.75
;
else if(Plr->getRace() == RACE_NIGHTELF)
Plr->EventTeleport(1, 0, 10311.3, 832.463, 1326.41);
else if(Plr->getRace() == RACE_UNDEAD)
Plr->EventTeleport(0, 0, 1676.35, 1677.45, 121.67);
else if(Plr->getRace() == RACE_TAUREN)
Plr->EventTeleport(10, 0, -2917.58, -257.98, 52.996
;
else if(Plr->getRace() == RACE_GNOME)
Plr->EventTeleport(0, 0, -6240.32, 331.033, 382.75
;
else if(Plr->getRace() == RACE_TROLL)
Plr->EventTeleport(1, 0,-618.518, -4251.67, 38.71
;
else if(Plr->getRace() == RACE_BLOODELF)
Plr->EventTeleport(530, 0, 10349.6, -6357.29, 33.4026);
else if(Plr->getRace() == RACE_DRAENEI)
Plr->EventTeleport(530, 0, -3961.64, -13931.2, 100.615);
else
Plr->BroadcastMessage("Error! You are an incorrect race!");
}
};
void SetupOrb_of_Translocation(ScriptMgr * mgr)
{
mgr->register_gameobject_script(910000, &Orb_of_Translocation::Create);
}