#include "nw_i0_generic"
location lTarget;
object oSpawn;
effect eEffect;
object oTarget;
/*   Script generated by
Lilac Soul's NWN Script Generator, v. 1.6

For download info, please visit:
http://www.lilacsoul.revility.com    */

//Put this OnUsed
void main()
{

object oPC = GetLastUsedBy();

if (!GetIsPC(oPC)) return;

int DoOnce = GetLocalInt(OBJECT_SELF, GetTag(OBJECT_SELF));

if (DoOnce==TRUE) return;



if (FortitudeSave(oPC, 14, SAVING_THROW_TYPE_EVIL ))
   {
   SetLocalInt(OBJECT_SELF, GetTag(OBJECT_SELF), TRUE);

   oTarget = oPC;

   eEffect = EffectParalyze();

   ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eEffect, oTarget, 6.0f);

   FloatingTextStringOnCreature("The mirror is actualy a gray ooze.  It drops from the frame and attacks.", oPC);

   oTarget = oPC;

   lTarget = GetLocation(oTarget);

   oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "zep_grayoozem", lTarget);

   oTarget = oSpawn;

   SetIsTemporaryEnemy(oPC, oTarget);

   AssignCommand(oTarget, ActionAttack(oPC));

   AssignCommand(oTarget, DetermineCombatRound(oPC));

   }

}
