Lankhmar_PRC8/_module/nss/cnv_wp_kerdor.nss

50 lines
918 B
Plaintext
Raw Permalink Normal View History

2025-04-03 12:54:47 -04:00
#include "x0_i0_partywide"
void main()
{
object oTarget;
location lTarget;
int nInt;
object oSpawn;
object oPC = GetPCSpeaker();
// Give 5 experience (to party) to the PC.
GiveXPToAll(oPC, 5);
oTarget = GetWaypointByTag("WP_kersdoor");
lTarget = GetLocation(oTarget);
if (GetAreaFromLocation(lTarget)==OBJECT_INVALID) return;
oTarget=GetFirstFactionMember(oPC, FALSE);
while (GetIsObjectValid(oTarget))
{
AssignCommand(oTarget, ClearAllActions());
AssignCommand(oTarget, ActionJumpToLocation(lTarget));
oTarget=GetNextFactionMember(oPC, FALSE);
}
oTarget = GetObjectByTag("Kels1");
nInt = GetObjectType(oTarget);
oTarget = GetObjectByTag("Kels1");
DestroyObject(oTarget, 3.0);
oTarget = GetWaypointByTag("WP_SPn_Kers2");
lTarget = GetLocation(oTarget);
oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "kels2", lTarget);
oTarget = GetObjectByTag("kersdoor1");
SetLocked(oTarget, FALSE);
}