Initial commit
Adding all of the current content for Anphillia Unlimited.
This commit is contained in:
21
_module/nss/wa_guard.nss
Normal file
21
_module/nss/wa_guard.nss
Normal file
@@ -0,0 +1,21 @@
|
||||
void main()
|
||||
{
|
||||
if (GetLocalInt(OBJECT_SELF, "justquaked") == 1)
|
||||
return;
|
||||
SetLocalInt(OBJECT_SELF, "justquaked", 1);
|
||||
object oUser = GetLastUsedBy();
|
||||
PlayAnimation(ANIMATION_PLACEABLE_OPEN);
|
||||
SetLocalInt(GetNearestObject(OBJECT_TYPE_DOOR, OBJECT_SELF, 1), "escaping", 0);
|
||||
SetLocalInt(GetNearestObject(OBJECT_TYPE_DOOR, OBJECT_SELF, 2), "escaping", 0);
|
||||
int n = 1;
|
||||
object oPC = GetNearestCreature(CREATURE_TYPE_PLAYER_CHAR, PLAYER_CHAR_IS_PC, oUser);
|
||||
while (oPC != OBJECT_INVALID)
|
||||
{
|
||||
if (GetLocalInt(oPC, "nullified") == 1)
|
||||
ApplyEffectToObject(DURATION_TYPE_TEMPORARY, EffectKnockdown(), oPC, 11.0);
|
||||
n++;
|
||||
oPC = GetNearestCreature(CREATURE_TYPE_PLAYER_CHAR, PLAYER_CHAR_IS_PC, oUser, n);
|
||||
}
|
||||
ApplyEffectToObject(DURATION_TYPE_TEMPORARY, EffectVisualEffect(VFX_FNF_SCREEN_SHAKE), OBJECT_SELF, 5.0);
|
||||
DelayCommand(15.0, SetLocalInt(OBJECT_SELF, "justquaked", 0));
|
||||
}
|
||||
Reference in New Issue
Block a user