Initial upload
Initial upload. PRC8 has been added. Module compiles, PRC's default AI & treasure scripts have been integrated. Started work on top hak for SLA / Ability / Scripting modifications.
This commit is contained in:
58
_removed/nw_s0_invisib.nss
Normal file
58
_removed/nw_s0_invisib.nss
Normal file
@@ -0,0 +1,58 @@
|
||||
///::///////////////////////////////////////////////
|
||||
//:: Invisibility
|
||||
//:: NW_S0_Invisib.nss
|
||||
//:: Copyright (c) 2001 Bioware Corp.
|
||||
//:://////////////////////////////////////////////
|
||||
/*
|
||||
Target creature becomes invisibility
|
||||
*/
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Preston Watamaniuk
|
||||
//:: Created On: Jan 7, 2002
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
#include "x0_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())
|
||||
{
|
||||
return;
|
||||
}
|
||||
// End of Spell Cast Hook
|
||||
//Declare major variables
|
||||
object oTarget = GetSpellTargetObject();
|
||||
|
||||
//effect eVis = EffectVisualEffect(VFX_DUR_INVISIBILITY);
|
||||
effect eInvis = EffectInvisibility(INVISIBILITY_TYPE_NORMAL);
|
||||
effect eDur = EffectVisualEffect(VFX_DUR_CESSATE_POSITIVE);
|
||||
|
||||
effect eLink = EffectLinkEffects(eInvis, eDur);
|
||||
//eLink = EffectLinkEffects(eLink, eVis);
|
||||
|
||||
//Fire cast spell at event for the specified target
|
||||
SignalEvent(oTarget, EventSpellCastAt(OBJECT_SELF, SPELL_INVISIBILITY, FALSE));
|
||||
int nDuration = GetCasterLevel(OBJECT_SELF);
|
||||
nDuration=nDuration*30;
|
||||
nDuration=nDuration+Random(nDuration);
|
||||
float fDuration=IntToFloat(nDuration);
|
||||
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_TEMPORARY, eLink, oTarget, fDuration);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user