Hi guys, Sorry I'm a lazy Leacher, but I will be posting helpful things soon enough.
At the moment I need help with a LUA script for a gameobject that teleports you different places depending on your race.
This is what I had, but its .gm, So if anyone could help me out with the LUA format of it, it would be greatly appreciated
Code:
global teleport=function(plr)
{
//alliance
if(plr.GetRace() == 1)
{
plr.Teleport(48, -414.5, 27.1, -48.35);
return 1;
}
if(plr.GetRace() == 2)
{
plr.Teleport(48, -532, 326.48, -49.67);
return 1;
}
if(plr.GetRace() == 3)
{
plr.Teleport(48, -414.5, 27.1, -48.35);
return 1;
}
if(plr.GetRace() == 4)
{
plr.Teleport(48, -532, 326.48, -49.67);
return 1;
}
if(plr.GetRace() == 5)
{
plr.Teleport(48, -414.5, 27.1, -48.35);
}
//horde
if(plr.GetRace() == 6)
{
plr.Teleport(48, -827.4, -227.7, -28.27);
}
if(plr.GetRace() == 7)
{
plr.Teleport(48, -827.4, -227.7, -28.27);
}
if(plr.GetRace() == 8)
{
plr.Teleport(48, -532, 326.48, -49.67);
}
if(plr.GetRace() == 10)
{
plr.Teleport(48, -532, 326.48, -49.67);
}
if(plr.GetRace() == 11)
{
plr.Teleport(48, -414.5, 27.1, -48.35);
}
};
.RegisterGameObjectEvent(999670, 2, teleport);