Horsefly Swamp update
Creatures & encounter tables to support Horsefly swamp expansion.
This commit is contained in:
37
_module/nss/spell_suck.nss
Normal file
37
_module/nss/spell_suck.nss
Normal file
@@ -0,0 +1,37 @@
|
||||
#include "NW_I0_SPELLS"
|
||||
#include "prc_inc_spells"
|
||||
|
||||
void DoAbilityDamage(object oTarget, object oCaster)
|
||||
{
|
||||
|
||||
effect eVis = EffectVisualEffect(VFX_IMP_MAGBLUE);
|
||||
int nDam = 2;
|
||||
int nType = ABILITY_INTELLIGENCE;
|
||||
if ( GetLevelByClass(CLASS_TYPE_CLERIC,oTarget) > 1 ||
|
||||
GetLevelByClass(CLASS_TYPE_PALADIN,oTarget) > 1 ||
|
||||
GetLevelByClass(CLASS_TYPE_RANGER,oTarget) > 1 ||
|
||||
GetLevelByClass(CLASS_TYPE_DRUID,oTarget) > 1 )
|
||||
nType = ABILITY_WISDOM;
|
||||
if ( GetLevelByClass(CLASS_TYPE_SORCERER,oTarget) > 1 ||
|
||||
GetLevelByClass(CLASS_TYPE_BARD,oTarget) > 1 )
|
||||
nType = ABILITY_CHARISMA;
|
||||
|
||||
effect eDam = EffectAbilityDecrease(nType,nDam);
|
||||
|
||||
ApplyEffectToObject(DURATION_TYPE_INSTANT,eVis,oTarget);
|
||||
ApplyEffectToObject(DURATION_TYPE_PERMANENT,eDam,oTarget);
|
||||
|
||||
}
|
||||
|
||||
void main()
|
||||
{
|
||||
object oTarget = PRCGetSpellTargetObject();
|
||||
object oCaster = OBJECT_SELF;
|
||||
|
||||
/* int bIsPoisoned = GetLocalInt(oTarget,"IsPoisoned");
|
||||
if ( bIsPoisoned )
|
||||
return; */
|
||||
|
||||
DelayCommand(0.1,DoAbilityDamage(oTarget,oCaster));
|
||||
|
||||
}
|
Reference in New Issue
Block a user