IF
	Die()
THEN
	RESPONSE #100
		ReallyForceSpellDeadRES("ru_cloze",Myself)
END

IF
        HPLT(Myself,100)
        Global("POLY_GAS","LOCALS",0)
        Global("POLY_BAT","LOCALS",0)
THEN
	RESPONSE #100
                SetGlobal("POLY_GAS","LOCALS",1)
		Polymorph(BLOB_MIST_CREATURE)
                CreateVisualEffectObject("SPDISPMA",Myself)
                PlaySound("EFF_M10")
                DestroyAllEquipment()
                CreateItem("RU_IMMAM",1,0,0)
                CreateItem("RU_IMMRI",1,0,0)
                FillSlot(SLOT_RING_LEFT)
                FillSlot(SLOT_AMULET)
                SetGlobalTimer("GAS_TIMER","LOCALS",12)
END

IF
        Global("POLY_GAS","LOCALS",1)
        GlobalTimerExpired("GAS_TIMER","LOCALS")
THEN
	RESPONSE #100
                SetGlobal("POLY_GAS","LOCALS",0)
		Polymorph(VAMPIRE_FEMALE)
                CreateVisualEffectObject("SPDISPMA",Myself)
                PlaySound("EFF_M10")
                DestroyAllEquipment()
                CreateItem("RU_AMUL2",1,0,0)
                FillSlot(SLOT_AMULET)
                CreateItem("DRAGRING",1,0,0)
                FillSlot(SLOT_RING_LEFT)
                CreateItem("VAMPREG",1,0,0)
                FillSlot(SLOT_RING_RIGHT)
                CreateItem("RU_VAMHE",1,0,0)
                FillSlot(SLOT_HELMET)
                ReallyForceSpellRES("ru_cloz1",Myself)
END

IF
        Global("POLY_BAT","LOCALS",0)
        Global("POLY_GAS","LOCALS",0)
	See(NearestEnemyOf(Myself))
        !GlobalTimerNotExpired("DOMINATION","LOCALS")
THEN
	RESPONSE #50
                SetGlobalTimer("DOMINATION","LOCALS",12)
		ForceSpell(NearestEnemyOf(Myself),VAMPIRE_DOMINATION)
                Continue()
	RESPONSE #50
                SetGlobalTimer("DOMINATION","LOCALS",6)
                ReallyForceSpell(NearestEnemyOf(Myself),VAMPIRE_FEAR)
                Continue()
END

IF
        See(NearestEnemyOf(Myself))
THEN
	RESPONSE #100
                Continue()
END

IF
        Global("POLY_BAT","LOCALS",0)
        Global("POLY_GAS","LOCALS",0)
        ActionListEmpty()
        !CheckStat(LastSeenBy(Myself),4,WIZARD_PROTECTION_FROM_MAGIC_WEAPONS)
        Range(LastSeenBy(Myself),2)
THEN
	RESPONSE #100
                AttackReevaluate(LastSeenBy(Myself),30)
END

IF
        Global("POLY_BAT","LOCALS",0)
        Global("POLY_GAS","LOCALS",0)
	Detect("RU_LIME")
        CheckStat(LastSeenBy(Myself),4,WIZARD_PROTECTION_FROM_MAGIC_WEAPONS)
        Range(LastSeenBy(Myself),2)
THEN
	RESPONSE #100
                DisplayStringHead(Myself,@149)
                GiveOrder("RU_LIME",2)
                Wait(3)
END

IF
        Global("POLY_BAT","LOCALS",1)
	See(NearestEnemyOf(Myself))
        Range(NearestEnemyOf(Myself),2)
THEN
	RESPONSE #100
                SetGlobal("POLY_BAT","LOCALS",0)
		Polymorph(VAMPIRE_FEMALE)
                CreateVisualEffectObject("SPDISPMA",Myself)
                PlaySound("EFF_M10")
                DestroyAllEquipment()
                CreateItem("RU_AMUL2",1,0,0)
                FillSlot(SLOT_AMULET)
                CreateItem("DRAGRING",1,0,0)
                FillSlot(SLOT_RING_LEFT)
                CreateItem("VAMPREG",1,0,0)
                FillSlot(SLOT_RING_RIGHT)
                CreateItem("RU_VAMHE",1,0,0)
                FillSlot(SLOT_HELMET)
                CreateItem("RU_COM01",1,0,0)
                ReallyForceSpellRES("ru_cloz1",Myself)END

IF
        Global("POLY_BAT","LOCALS",1)
	See(NearestEnemyOf(Myself))
        !Range(NearestEnemyOf(Myself),2)
THEN
	RESPONSE #100
                MoveToObject(NearestEnemyOf(Myself))END

IF
        Global("POLY_BAT","LOCALS",0)
        Global("POLY_GAS","LOCALS",0)
	See(NearestEnemyOf(Myself))
        !Range(NearestEnemyOf(Myself),2)
THEN
	RESPONSE #100
                SetGlobal("POLY_BAT","LOCALS",1)
		Polymorph(BAT_INSIDE)
                CreateVisualEffectObject("SPDISPMA",Myself)
                PlaySound("EFF_M10")
                DestroyAllEquipment()
                CreateItem("RU_IMMAM",1,0,0)
                CreateItem("RU_IMMRI",1,0,0)
                FillSlot(SLOT_RING_LEFT)
                FillSlot(SLOT_AMULET)END

IF
        Global("POLY_BAT","LOCALS",0)
        Global("POLY_GAS","LOCALS",0)
        ActionListEmpty()
        HPGT(Myself,99)
	Range(NearestEnemyOf(Myself),2)
THEN
	RESPONSE #100
                AttackReevaluate(NearestEnemyOf(Myself),30)END