LoD_PRC8/_module/nss/tb_portgchoice.nss
Jaysyn904 94990edc60 Initial Upload
Initial Upload
2023-09-21 21:20:34 -04:00

35 lines
684 B
Plaintext

void main()
{
object oPC = GetLastUsedBy();
if(!GetIsPC(oPC))
{
return;
}
object oTarget = oPC;
int nInt = GetObjectType(oTarget);
if(nInt != OBJECT_TYPE_WAYPOINT)
{
ApplyEffectToObject(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_FNF_WORD), oTarget);
}
else
{
ApplyEffectAtLocation(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_FNF_WORD), GetLocation(oTarget));
}
AssignCommand(oPC, ClearAllActions());
oTarget = GetWaypointByTag("tb_GorgonPortals");
location lTarget = GetLocation(oTarget);
if(GetAreaFromLocation(lTarget)==OBJECT_INVALID)
{
return;
}
AssignCommand(oPC, ActionJumpToLocation(lTarget));
}