//::///////////////////////////////////////////////
//:: Name x2_def_percept
//:: Copyright (c) 2001 Bioware Corp.
//:://////////////////////////////////////////////
/*
    Default On Perception script
*/
//:://////////////////////////////////////////////
//:: Created By: Keith Warner
//:: Created On: June 11/03
//:://////////////////////////////////////////////

          /*
 *  Script generated by LS Script Generator, v.TK.0
 *
 *  For download info, please visit:
 *  http://nwvault.ign.com/View.php?view=Other.Detail&id=1502
 */
// Put this script OnPerceived (of a creature).


void main()
{
    // We are only interested in "seen" events.
    if ( !GetLastPerceptionSeen() )
        return;

    // Get the creature who triggered this event.
    object oPC = GetLastPerceived();

    // Only fire for (real) PCs.
    if ( !GetIsPC(oPC)  ||  GetIsDMPossessed(oPC) )
        return;

    // Only fire once per PC.
    if ( GetLocalInt(oPC, "DO_ONCE__" + GetTag(OBJECT_SELF)) )
        return;
    SetLocalInt(oPC, "DO_ONCE__" + GetTag(OBJECT_SELF), TRUE);

    // Have us say something.
    SpeakString("You are a persistent wretch. Very well. I present to you Jyordhan, the false lord of Shadowdale and my most prized servant!");
    ExecuteScript("nw_c2_default2", OBJECT_SELF);
}

