PoA_PRC8/_module/_removed files/nw_s0_delfirebal.nss
Jaysyn904 151d074880 Added "Removed Files" folder
Added "Removed Files" folder in case we needed to review any of them.
2022-10-10 10:39:34 -04:00

60 lines
1.6 KiB
Plaintext

//::///////////////////////////////////////////////
//:: Delayed Blast Fireball
//:: NW_S0_DelFirebal.nss
//:: Copyright (c) 2001 Bioware Corp.
//:://////////////////////////////////////////////
/*
The caster creates a trapped area which detects
the entrance of enemy creatures into 3 m area
around the spell location. When tripped it
causes a fiery explosion that does 1d6 per
caster level up to a max of 20d6 damage.
*/
//:://////////////////////////////////////////////
//:: Created By: Preston Watamaniuk
//:: Created On: July 27, 2001
//:://////////////////////////////////////////////
#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
//Declare major variables including Area of Effect Object
effect eAOE = EffectAreaOfEffect(AOE_PER_DELAY_BLAST_FIREBALL);
location lTarget = GetSpellTargetLocation();
int nDuration = GetCasterLevel(OBJECT_SELF);
//Make sure the duration is at least one round
if (nDuration == 0)
{
nDuration = 1;
}
int nMetaMagic = GetMetaMagicFeat();
//Check Extend metamagic feat.
if (nMetaMagic == METAMAGIC_EXTEND)
{
nDuration = nDuration *2;//Duration is +100%
}
//Create an instance of the AOE Object using the Apply Effect function
ApplyEffectAtLocation(DURATION_TYPE_TEMPORARY, eAOE, lTarget, RoundsToSeconds(nDuration));
}