//:://///////////////////////////////////////////// //:: Creeping Doom: Heartbeat //:: NW_S0_CrpDoomC.nss //:: Copyright (c) 2001 Bioware Corp. //::////////////////////////////////////////////// /* Creature caught in the swarm take an initial damage of 1d20, but there after they take 1d6 per swarm counter on the AOE. */ //::////////////////////////////////////////////// //:: Created By: Preston Watamaniuk //:: Created On: May 17, 2001 //::////////////////////////////////////////////// #include "X0_I0_SPELLS" void main() { //Declare major variables int nDamage; effect eDam; effect eVis = EffectVisualEffect(VFX_COM_BLOOD_REG_RED); object oTarget = GetEnteringObject(); int nSwarm = 6; int nDamCount = 1; float fDelay; if(nSwarm < 1) { nSwarm = 1; } //Get first target in spell area oTarget = GetFirstInPersistentObject(); while(GetIsObjectValid(oTarget) && nDamCount < 1000) { if (GetStandardFactionReputation(STANDARD_FACTION_HOSTILE,oTarget)<40) { fDelay = GetRandomDelay(1.0, 2.2); //Spell resistance check if (GetLocalInt(oTarget,"pure_water")!=2) { //Roll Damage nDamage = d6(nSwarm); //Set Damage Effect with the modified damage eDam = EffectDamage(nDamage, DAMAGE_TYPE_PIERCING); //Apply damage and visuals DelayCommand(fDelay, ApplyEffectToObject(DURATION_TYPE_INSTANT, eVis, oTarget)); DelayCommand(fDelay, ApplyEffectToObject(DURATION_TYPE_INSTANT, eDam, oTarget)); DelayCommand(fDelay, ApplyEffectToObject(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_IMP_DISEASE_S),oTarget)); DelayCommand(fDelay, ApplyEffectToObject(DURATION_TYPE_INSTANT, EffectDeath(TRUE), oTarget)); nDamCount = nDamCount + nDamage; SendMessageToPC(oTarget,"The flies dig deep into your body, burrowing under your skin"); } else { SendMessageToPC(oTarget,"The flies seem uninterested in you."); } } //Get next target in spell area oTarget = GetNextInPersistentObject(); } }