34 lines
1.1 KiB
Plaintext
34 lines
1.1 KiB
Plaintext
|
//:: atropal_warning.nss
|
||
|
|
||
|
void main()
|
||
|
{
|
||
|
// Get the creature who triggered this event.
|
||
|
object oPC = GetEnteringObject();
|
||
|
|
||
|
// Only fire for (real) PCs.
|
||
|
if ( !GetIsPC(oPC) || GetIsDMPossessed(oPC) )
|
||
|
return;
|
||
|
|
||
|
// Only fire once per PC.
|
||
|
if ( GetLocalInt(OBJECT_SELF, "DO_ONCE__" + ObjectToString(oPC)) )
|
||
|
return;
|
||
|
SetLocalInt(OBJECT_SELF, "DO_ONCE__" + ObjectToString(oPC), TRUE);
|
||
|
|
||
|
// If the PC's total level is at most 50.
|
||
|
if ( GetHitDice(oPC) <= 50 )
|
||
|
{
|
||
|
|
||
|
//:: Send a message to the player's chat window.
|
||
|
SendMessageToPC(oPC, "As you draw near the entryway, you are overcome by a powerful feeling of dread.");
|
||
|
SendMessageToPC(oPC, "You feel that entering the next room would be a very short-lived & terrible idea.");
|
||
|
|
||
|
//:: Have text appear over the PC's head.
|
||
|
FloatingTextStringOnCreature("As you draw near the entryway, you are overcome by a powerful feeling of dread.", oPC, FALSE);
|
||
|
FloatingTextStringOnCreature("You feel that entering the next room would be a very short-lived & terrible idea.", oPC, FALSE);
|
||
|
|
||
|
//:: Have the PC say something.
|
||
|
PlayVoiceChat(VOICE_CHAT_BADIDEA, oPC);
|
||
|
|
||
|
}
|
||
|
|
||
|
}
|