//::///////////////////////////////////////////////
//:: Wall of Force: Heartbeat
//:: shaz_sp_wall_of_forcec.nss
//:://////////////////////////////////////////////
/*
    // Wouldn't normally need a heart for this spell,
	// but we will use it to give arrow immunity to people
	// being targeted across the wall 
*/
//:://////////////////////////////////////////////
//:: Created By: Shazbotian
//:: Created On: 4/30/08
//:://////////////////////////////////////////////


#include "X0_I0_SPELLS"
#include "x2_inc_spellhook"
#include "shaz_inc_math"
#include "jx_inc_magic"
#include "shaz_inc_forcewall"

void main()
{

    //Declare major variables
    int nCasterLvl = JXGetCasterLevel(OBJECT_SELF);
    int nMetaMagic = JXGetMetaMagicFeat();
    

    //--------------------------------------------------------------------------
    // GZ 2003-Oct-15
    // When the caster is no longer there, all functions calling
    // JXGetAOERealCreator will fail. Its better to remove the barrier then
    //--------------------------------------------------------------------------
    if (!GetIsObjectValid(JXGetAOERealCreator()))
    {
        DestroyObject(OBJECT_SELF);
        return;
    }
	
	ShazForceWallDoArrowImmunity();
}