Initial commit
Adding all of the current content for Anphillia Unlimited.
This commit is contained in:
90
_removed/x2_s0_batttide.nss
Normal file
90
_removed/x2_s0_batttide.nss
Normal file
@@ -0,0 +1,90 @@
|
||||
//::///////////////////////////////////////////////
|
||||
//:: Battletide
|
||||
//:: X2_S0_BattTide
|
||||
//:: Copyright (c) 2001 Bioware Corp.
|
||||
//:://////////////////////////////////////////////
|
||||
/*
|
||||
You create an aura that steals energy from your
|
||||
enemies. Your enemies suffer a -2 circumstance
|
||||
penalty on saves, attack rolls, and damage rolls,
|
||||
once entering the aura. On casting, you gain a
|
||||
+2 circumstance bonus to your saves, attack rolls,
|
||||
and damage rolls.
|
||||
Modified by : Rabidness
|
||||
on : June 20 , 2004
|
||||
Changes:
|
||||
- Fixed an issue where the AOE would dispell if the CASTER left the AOE
|
||||
...when the AOE was supposed to be centered ON the caster.
|
||||
*/
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Andrew Nobbs
|
||||
//:: Created On: Dec 04, 2002
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Last Updated By: Andrew Nobbs 06/06/03
|
||||
|
||||
#include "NW_I0_SPELLS"
|
||||
#include "x2_i0_spells"
|
||||
|
||||
#include "x2_inc_spellhook"
|
||||
|
||||
//Function called to remove the AOE effect when it is dead, since the normal
|
||||
//AOE onExit script is disabled against the creator of the effect
|
||||
//VvVvV This whole function has been added by Rabidness VvVvV
|
||||
void delayDispell( object oTarget )
|
||||
{
|
||||
//Search through the valid effects on the target.
|
||||
effect eAOE = GetFirstEffect( oTarget );
|
||||
while ( GetIsEffectValid( eAOE ) )
|
||||
{
|
||||
//If the effect was created by the Battletide then remove it
|
||||
if( GetEffectSpellId( eAOE ) == 517 )
|
||||
{
|
||||
RemoveEffect( oTarget , eAOE );
|
||||
}
|
||||
//Get next effect on the target
|
||||
eAOE = GetNextEffect( oTarget );
|
||||
}
|
||||
DeleteLocalObject( oTarget , "oBattleTide" );
|
||||
}
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
/*
|
||||
Spellcast Hook Code
|
||||
Added 2003-07-07 by Georg Zoeller
|
||||
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 = OBJECT_SELF;
|
||||
effect eAOE = EffectAreaOfEffect(41);
|
||||
int nDuration = GetCasterLevel(oTarget);
|
||||
//Make nDuration at least 1 round.
|
||||
if (nDuration < 1)
|
||||
{
|
||||
nDuration = 1;
|
||||
}
|
||||
int nMetaMagic = GetMetaMagicFeat();
|
||||
//Make metamagic check for extend
|
||||
if (nMetaMagic == METAMAGIC_EXTEND)
|
||||
{
|
||||
nDuration = nDuration *2; //Duration is +100%
|
||||
}
|
||||
//Create the AOE object at the selected location
|
||||
ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eAOE, oTarget, RoundsToSeconds(nDuration));
|
||||
//VvVvV Rabidness additions VvVvV
|
||||
SetLocalObject( oTarget , "oBattleTide" , oTarget );
|
||||
DelayCommand( RoundsToSeconds( nDuration ) , delayDispell( oTarget ) );
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user