Initial upload
Initial upload
This commit is contained in:
31
_module/nss/aw_spell_darkven.nss
Normal file
31
_module/nss/aw_spell_darkven.nss
Normal file
@@ -0,0 +1,31 @@
|
||||
#include "X0_I0_SPELLS"
|
||||
//Script for Dark Vengeance
|
||||
void main(){
|
||||
int lvlTYPE=0;int passCHECK=0;int scSKILLCHECK=GetSkillRank(SKILL_SPELLCRAFT,OBJECT_SELF);
|
||||
if(scSKILLCHECK >= 18)passCHECK = 1 ;
|
||||
if(GetLevelByClass(CLASS_TYPE_BLACKGUARD, OBJECT_SELF) >= 24)
|
||||
lvlTYPE = 1;else if((lvlTYPE == 0) && (GetLevelByClass(CLASS_TYPE_PALEMASTER, OBJECT_SELF) >= 16))
|
||||
lvlTYPE = 1;else if((lvlTYPE == 0) && (GetLevelByClass(CLASS_TYPE_ASSASSIN, OBJECT_SELF) >= 20))
|
||||
lvlTYPE = 1;else if((lvlTYPE == 0) && (GetLevelByClass(CLASS_TYPE_SHADOWDANCER, OBJECT_SELF) >= 20))
|
||||
lvlTYPE = 1;
|
||||
if(lvlTYPE == 1)
|
||||
if(passCHECK == 1){
|
||||
int AWDMGtarget= GetCurrentHitPoints(OBJECT_SELF);int AWDMGself= GetCurrentHitPoints(OBJECT_SELF)-1;
|
||||
object oPC,oTargetSELF,oTargetHOSTILE;effect eEffectSELF,eEffectHOSTILE;int AWODDS=Random(100);float fDelay;
|
||||
location lTarget = GetSpellTargetLocation();
|
||||
oTargetSELF = GetItemActivator();
|
||||
oTargetHOSTILE = GetFirstObjectInShape(SHAPE_SPHERE, RADIUS_SIZE_SMALL, lTarget);
|
||||
eEffectSELF = EffectDamage(AWDMGself, DAMAGE_TYPE_NEGATIVE);eEffectHOSTILE = EffectDamage(AWDMGtarget, DAMAGE_TYPE_NEGATIVE);
|
||||
ApplyEffectToObject(DURATION_TYPE_INSTANT, eEffectSELF, GetItemActivator());
|
||||
ApplyEffectAtLocation(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_IMP_EVIL_HELP), GetLocation(oTargetSELF));
|
||||
ApplyEffectAtLocation(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_FNF_LOS_EVIL_30), lTarget);
|
||||
while (GetIsObjectValid(oTargetHOSTILE)){
|
||||
if(spellsIsTarget(oTargetHOSTILE, SPELL_TARGET_SELECTIVEHOSTILE, OBJECT_SELF)){
|
||||
if(AWODDS <= 80){
|
||||
DelayCommand(fDelay,ApplyEffectToObject(DURATION_TYPE_INSTANT, eEffectHOSTILE, oTargetHOSTILE));
|
||||
DelayCommand(fDelay,ApplyEffectAtLocation(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_IMP_DEATH), GetLocation(oTargetHOSTILE)));}
|
||||
fDelay = GetDistanceBetweenLocations(lTarget, GetLocation(oTargetHOSTILE))/20;}
|
||||
AWODDS=Random(100);oTargetHOSTILE = GetNextObjectInShape(SHAPE_SPHERE, RADIUS_SIZE_HUGE, lTarget);}}
|
||||
if(lvlTYPE == 0)SpeakString("You are not ready to use this.");
|
||||
if(passCHECK == 0)SpeakString("You do not have high enough spellcraft at this time.");
|
||||
}
|
||||
Reference in New Issue
Block a user