Amon_PRC8/_removed/x0_s0_truestrike.nss
Jaysyn904 c5cffc37af Initial Commit
Initial Commit [v1.01]
2025-04-03 19:00:46 -04:00

64 lines
1.6 KiB
Plaintext

//::///////////////////////////////////////////////
//:: Truestrike
//:: x0_s0_truestrike.nss
//:: Copyright (c) 2002 Bioware Corp.
//:://////////////////////////////////////////////
/*
+20 attack bonus for 9 seconds.
CHANGE: Miss chance still applies, unlike rules.
*/
//:://////////////////////////////////////////////
//:: Created By: Brent Knowles
//:: Created On: July 15, 2002
//:://////////////////////////////////////////////
//:: VFX Pass By:
#include "NW_I0_SPELLS"
#include "70_inc_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
//Declare major variables
object oTarget;
int nDuration = spell.Level;
effect eVis = EffectVisualEffect(VFX_IMP_HEAD_ODD);
effect eAttack = EffectAttackIncrease(20);
effect eDur = EffectVisualEffect(VFX_DUR_CESSATE_POSITIVE);
effect eLink = eAttack;
eLink = EffectLinkEffects(eLink, eDur);
oTarget = OBJECT_SELF;
if(spell.Meta == METAMAGIC_EXTEND)
{
nDuration = nDuration *2; //Duration is +100%
}
//Fire spell cast at event for target
SignalEvent(oTarget, EventSpellCastAt(OBJECT_SELF, 415, FALSE));
//Apply VFX impact and bonus effects
ApplyEffectToObject(DURATION_TYPE_INSTANT, eVis, oTarget);
ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eLink, oTarget, RoundsToSeconds(nDuration));
}