PRC8_fork/trunk/newspellbook/inv_nightmareb.nss
Jaysyn904 1662218bb4 Initial upload.
Adding base PRC 4.19a files to repository.
2022-10-07 13:51:24 -04:00

34 lines
909 B
Plaintext

#include "prc_alterations"
#include "inv_inc_invfunc"
#include "inv_invokehook"
void main()
{
//Get the object that is exiting the AOE
object oTarget = GetExitingObject();
//Search through the valid effects on the target.
effect eAOE = GetFirstEffect(oTarget);
while (GetIsEffectValid(eAOE))// && bValid == FALSE)
{
//If the effect was created by the Web then remove it
if (GetEffectCreator(eAOE) == GetAreaOfEffectCreator())
{
if(GetEffectSpellId(eAOE) == INVOKE_NIGHTMARES_MADE_REAL)
{
RemoveEffect(oTarget, eAOE);
}
}
eAOE = GetNextEffect(oTarget);
}
if(oTarget != GetAreaOfEffectCreator()) return;
//clean HIPS off creator
object oSkin = GetPCSkin(oTarget);
IPRemoveMatchingItemProperties(oSkin, ITEM_PROPERTY_BONUS_FEAT, DURATION_TYPE_TEMPORARY, 31);
}