I am working on a script that replaces the Eldritch Blast (nw_s0_ieldblast) - turning it into a Point Blank Area of Effect spell that causes damage in a Sphere around the caster - causing more damage the closer the enemy is to the caster. The problem is that I cannot get it to give me a good VFX on the caster.
I attempted to get the VFX from Circle of Doom to radiate out from the caster, but cannot find it (which brings me to a request - is there a list of VFX and thier codes other than the one in the .2da list, which is almost all boxes floating over char. heads?). The one selected is... a box over his head
------------------------------- Also, how do I use the new format for a script? -----------------------------
//Made by Retpircs Wols; heavily "borrowed" from NWN Official - "Crushing Despair" and "Fireball"
#include "NW_I0_SPELLS"
#include "x2_inc_spellhook"
void main()
{
/*
Spellcast Hook Code
Added 2003-06-20 by Georg
If you want to make changes to all spells,
check x2_inc_spellhook.nss to find out more
*/
if (!X2PreSpellCastCode())
{
// If code within the PreSpellCastHook (i.e. UMD) reports FALSE, do not run this spell
return;
}
// End of Spell Cast Hook
//SpellCode
object oCaster = OBJECT_SELF; //get caster
int nLevel = GetLevelByclass(class_TYPE_WARLOCK); //get Warlock Level
//GetCasterLevel(OBJECT_SELF);
//Limit Caster level for the purposes of damage
if (nLevel > 10)
{
nLevel = 10;
}
int nChar = GetAbilityScore(oCaster, ABILITY_CHARISMA); //get Charisma score
int nDC = 5 + nChar; //make the DC the baddie needs to pass (beat charisma)
effect eEffect; //effect variable
//////////////////VISUALS: On CASTER
effect eVis = EffectVisualEffect(VFX_DUR_SPELL_EVIL_CIRCLE); //cannot get good visuals
ApplyEffectToObject(DURATION_TYPE_INSTANT, eVis, oCaster);
//////////////////END VISUALS for Caster
/////////////////////////////////////RUN Collasal hit - d2 * (charisma/3) + (War. Level/2)
object oTarget = GetFirstObjectInShape(SHAPE_SPHERE, RADIUS_SIZE_COLOSSAL, GetLocation(OBJECT_SELF), TRUE, OBJECT_TYPE_CREATURE);
while(GetIsObjectValid(oTarget)) //while loop for valid critter targets
{
if(!GetIsReactionTypeFriendly(oTarget) == TRUE) //make sure it is a baddie
{
//attempt a Will Save at 15 + Char Mod
if (WillSave(oTarget, nDC, SAVING_THROW_TYPE_MIND_SPELLS) == 0)
{
eEffect = EffectDamage(d2(nChar/3)+ (nLevel/2), DAMAGE_TYPE_NEGATIVE, DAMAGE_POWER_ENERGY);
ApplyEffectToObject(DURATION_TYPE_INSTANT, eEffect, oTarget);
//visuals Necro
effect eVis = EffectVisualEffect(VFX_HIT_SPELL_NECROMANCY);
ApplyEffectToObject(DURATION_TYPE_INSTANT, eVis, oTarget);
} //stop baddie if
} //end of do - grab next critter
oTarget = GetNextObjectInShape(SHAPE_SPHERE, RADIUS_SIZE_COLOSSAL, GetLocation(OBJECT_SELF), TRUE, OBJECT_TYPE_CREATURE);
} // End of Collosal
/////////////////////////////////////RUN Large hit - 4d * (charisma/3) + (War. Level/2)
oTarget = GetFirstObjectInShape(SHAPE_SPHERE, RADIUS_SIZE_LARGE, GetLocation(OBJECT_SELF), TRUE, OBJECT_TYPE_CREATURE);
while(GetIsObjectValid(oTarget))
{
if(!GetIsReactionTypeFriendly(oTarget) == TRUE)
{
//attempt a Will Save at 15 + Char Mod
if (WillSave(oTarget, nDC, SAVING_THROW_TYPE_MIND_SPELLS) == 0)
{
eEffect = EffectDamage(d4(nChar/3)+ (nLevel/2), DAMAGE_TYPE_NEGATIVE, DAMAGE_POWER_ENERGY);
ApplyEffectToObject(DURATION_TYPE_INSTANT, eEffect, oTarget);
//visuals Necro
effect eVis = EffectVisualEffect(VFX_HIT_SPELL_NECROMANCY);
ApplyEffectToObject(DURATION_TYPE_INSTANT, eVis, oTarget);
}
}
oTarget = GetNextObjectInShape(SHAPE_SPHERE, RADIUS_SIZE_LARGE, GetLocation(OBJECT_SELF), TRUE, OBJECT_TYPE_CREATURE);
} // End of Medium
/////////////////////////////////////RUN Small hit - 6d * (charisma/3) + (War. Level/2)
oTarget = GetFirstObjectInShape(SHAPE_SPHERE, RADIUS_SIZE_SMALL, GetLocation(OBJECT_SELF), TRUE, OBJECT_TYPE_CREATURE);
while(GetIsObjectValid(oTarget))
{
if(!GetIsReactionTypeFriendly(oTarget) == TRUE)
{
//attempt a Will Save at 15 + Char Mod
if (WillSave(oTarget, nDC, SAVING_THROW_TYPE_MIND_SPELLS) == 0)
{
eEffect = EffectDamage(d6(nChar/3)+ (nLevel/2), DAMAGE_TYPE_NEGATIVE, DAMAGE_POWER_ENERGY);
ApplyEffectToObject(DURATION_TYPE_INSTANT, eEffect, oTarget);
//visuals Necro
effect eVis = EffectVisualEffect(VFX_HIT_SPELL_NECROMANCY);
ApplyEffectToObject(DURATION_TYPE_INSTANT, eVis, oTarget);
}
}
oTarget = GetNextObjectInShape(SHAPE_SPHERE, RADIUS_SIZE_SMALL, GetLocation(OBJECT_SELF), TRUE, OBJECT_TYPE_CREATURE);
} // End of Small
}





Retour en haut






