End of Year updates.
End of Year updates.
This commit is contained in:
59
_module/nss/cr_claw_ggg_r.nss
Normal file
59
_module/nss/cr_claw_ggg_r.nss
Normal file
@@ -0,0 +1,59 @@
|
||||
////////////////////////////////////////////
|
||||
//
|
||||
// Green Guardian Gargoyle Hold Attack
|
||||
//
|
||||
// CR_CLAW_GGG_R
|
||||
//
|
||||
// Keeps track of when the right claw hits
|
||||
// and applies the paralysis.
|
||||
//
|
||||
////////////////////////////////////////////
|
||||
|
||||
#include "NW_I0_SPELLS"
|
||||
#include "prc_inc_combmove"
|
||||
#include "prc_misc_const"
|
||||
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
object oGGG = OBJECT_SELF;
|
||||
object oItem = GetSpellCastItem();
|
||||
object oTarget = GetSpellTargetObject();
|
||||
string sID = GetObjectUUID(oGGG);
|
||||
int nDuration = 4;
|
||||
|
||||
effect eVis = EffectVisualEffect(VFX_IMP_STUN);
|
||||
effect eDur = EffectVisualEffect(VFX_DUR_PARALYZED);
|
||||
effect ePara = EffectParalyze();
|
||||
effect eLink = EffectLinkEffects(ePara, eDur);
|
||||
|
||||
string sRight = sID + "RightClaw";
|
||||
string sLeft = sID + "LeftClaw";
|
||||
|
||||
SetLocalInt(oTarget, sRight, 1);
|
||||
|
||||
GetLocalInt(oTarget, sLeft);
|
||||
|
||||
int iRight = GetLocalInt(oTarget, sRight);
|
||||
int iLeft = GetLocalInt(oTarget, sLeft);
|
||||
|
||||
if ((iRight + iLeft > 2) ||
|
||||
(iRight + iLeft < 2))
|
||||
{
|
||||
SetLocalInt(oTarget, sRight, 0);
|
||||
SetLocalInt(oTarget, sLeft, 0);
|
||||
return;
|
||||
}
|
||||
|
||||
if(!MySavingThrow(SAVING_THROW_FORT, oTarget, 16, SAVING_THROW_TYPE_NONE))
|
||||
{
|
||||
//Apply the VFX impact and effects
|
||||
ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eLink, oTarget, RoundsToSeconds(nDuration));
|
||||
ApplyEffectToObject(DURATION_TYPE_INSTANT, eVis, oTarget);
|
||||
|
||||
SetLocalInt(oTarget, sRight, 0);
|
||||
SetLocalInt(oTarget, sLeft, 0);
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user