Area & spawner pass.
Updated Aragnak's Isle & Lair, Bard College, Cazrak's Lair. Remade several items.
This commit is contained in:
45
_module/nss/ra_wake_aragnak.nss
Normal file
45
_module/nss/ra_wake_aragnak.nss
Normal file
@@ -0,0 +1,45 @@
|
||||
void main()
|
||||
{
|
||||
object oPC = GetEnteringObject();
|
||||
object oArea = GetArea(oPC);
|
||||
object oMob1 = GetNearestObjectByTag("RA_DRAG_ARAGNAK1", oPC); // Awake Aragnak
|
||||
object oMob2 = GetNearestObjectByTag("RA_DRAG_ARAGNAK2", oPC); // Sleeping Aragnak
|
||||
|
||||
//:: PCs only
|
||||
if (!GetIsPC(oPC)) return;
|
||||
|
||||
//:: Only trigger once
|
||||
int DoOnce = GetLocalInt(oPC, GetTag(OBJECT_SELF));
|
||||
if (DoOnce==TRUE) return;
|
||||
|
||||
//:: Don't want this trigger to fire if either version of Arganak is awake.
|
||||
if (GetLocalInt(oMob1, "awake") == 1) { return; }
|
||||
if (GetLocalInt(oMob2, "awake") == 1) { return; }
|
||||
|
||||
MusicBattlePlay(oArea);
|
||||
|
||||
//:: Remove "Sleep" from our dragon
|
||||
effect eEffect = GetFirstEffect(oMob2);
|
||||
|
||||
|
||||
while(GetIsEffectValid(eEffect))
|
||||
{
|
||||
if(GetEffectTag(eEffect) == "STILL_DRAGON")
|
||||
RemoveEffect(oMob2, eEffect);
|
||||
|
||||
eEffect = GetNextEffect(oMob2);
|
||||
}
|
||||
|
||||
//:: Talk a little trash.
|
||||
AssignCommand(GetObjectByTag("RA_DRAG_ARAGNAK2"), ActionSpeakString("INSECTS!!! YOU DARE DISTURB MY SLUMBER!!!!"));
|
||||
|
||||
FloatingTextStringOnCreature("You've drawn too close. The dragon is stirring from his slumber.", oPC);
|
||||
|
||||
//:: Set an INT so that we know he's awake
|
||||
SetLocalInt(oMob2, "awake", 1);
|
||||
SetLocalInt(oMob2, "sleep", 0);
|
||||
|
||||
//:: Set "do once" Tag
|
||||
SetLocalInt(oPC, GetTag(OBJECT_SELF), TRUE);
|
||||
}
|
||||
|
Reference in New Issue
Block a user