Aantioch_Infernum/_module/nss/kingannounce.nss
2023-10-12 22:59:45 -05:00

21 lines
498 B
Plaintext

void main()
{
object oPC = GetEnteringObject();
string sName = GetName(oPC, FALSE);
object oKingsGuard = GetNearestObjectByTag("KingsGuard");
// Only fire once.
if ( GetLocalInt(GetModule(), "DO_ONCE__" + sName))
return;
if (GetIsPC(oPC))
{
AssignCommand(oKingsGuard, ClearAllActions());
AssignCommand(oKingsGuard, ActionSpeakString(sName + " has entered the Court!", TALKVOLUME_TALK));
SetLocalInt(GetModule(), "DO_ONCE__" + sName, TRUE);
}
}