Added "Removed Files" folder
Added "Removed Files" folder in case we needed to review any of them.
This commit is contained in:
66
_module/_removed files/nw_s0_imprinvis.nss
Normal file
66
_module/_removed files/nw_s0_imprinvis.nss
Normal file
@@ -0,0 +1,66 @@
|
||||
///::///////////////////////////////////////////////
|
||||
//:: Improved Invisibility
|
||||
//:: NW_S0_ImprInvis.nss
|
||||
//:: Copyright (c) 2001 Bioware Corp.
|
||||
//:://////////////////////////////////////////////
|
||||
/*
|
||||
Target creature can attack and cast spells while
|
||||
invisible
|
||||
*/
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Preston Watamaniuk
|
||||
//:: Created On: Jan 7, 2002
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
#include "x2_inc_spellhook"
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
/*
|
||||
Spellcast Hook Code
|
||||
Added 2003-06-23 by GeorgZ
|
||||
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
|
||||
object oTarget = GetSpellTargetObject();
|
||||
effect eImpact = EffectVisualEffect(VFX_IMP_HEAD_MIND);
|
||||
|
||||
effect eInvis = EffectInvisibility(INVISIBILITY_TYPE_IMPROVED);
|
||||
|
||||
effect eVis = EffectVisualEffect(VFX_DUR_INVISIBILITY);
|
||||
effect eDur = EffectVisualEffect(VFX_DUR_CESSATE_POSITIVE);
|
||||
effect eCover = EffectConcealment(55);
|
||||
effect eLink = EffectLinkEffects(eDur, eCover);
|
||||
eLink = EffectLinkEffects(eLink, eVis);
|
||||
|
||||
|
||||
//Fire cast spell at event for the specified target
|
||||
SignalEvent(oTarget, EventSpellCastAt(OBJECT_SELF, SPELL_IMPROVED_INVISIBILITY, FALSE));
|
||||
int nDuration = GetCasterLevel(OBJECT_SELF);
|
||||
int nMetaMagic = GetMetaMagicFeat();
|
||||
//Enter Metamagic conditions
|
||||
if (nMetaMagic == METAMAGIC_EXTEND)
|
||||
{
|
||||
nDuration = nDuration *2; //Duration is +100%
|
||||
}
|
||||
//Apply the VFX impact and effects
|
||||
ApplyEffectToObject(DURATION_TYPE_INSTANT, eImpact, oTarget);
|
||||
|
||||
ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eLink, oTarget, TurnsToSeconds(nDuration));
|
||||
ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eInvis, oTarget, TurnsToSeconds(nDuration));
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user