20 lines
719 B
Plaintext
20 lines
719 B
Plaintext
// Real Time Strategy - NWN - Wizard Teleport
|
|
|
|
void main()
|
|
{
|
|
object oPC=GetEnteringObject();
|
|
object oWiz=GetNearestObjectByTag("Wizard",oPC);
|
|
object oWP=GetWaypointByTag("TELEPORT_WIZARD");
|
|
int nDone=GetLocalInt(oWiz,"nTeleported");
|
|
effect eVFX=EffectVisualEffect(VFX_FNF_IMPLOSION);
|
|
if (nDone!=TRUE&&oWiz!=OBJECT_INVALID)
|
|
{ // teleport
|
|
ApplyEffectToObject(DURATION_TYPE_TEMPORARY,eVFX,oWiz,3.0);
|
|
AssignCommand(oWiz,ClearAllActions());
|
|
AssignCommand(oWiz,JumpToObject(oWP));
|
|
AssignCommand(oWiz,ActionSpeakString("Now I am afraid you will have to die."));
|
|
ChangeToStandardFaction(oWiz,STANDARD_FACTION_HOSTILE);
|
|
SetLocalInt(oWiz,"nTeleported",TRUE);
|
|
} // teleport
|
|
}
|