IF
  Global("DD_PO_quest","GLOBAL",2)
  Range([PC],10)
THEN
  RESPONSE #100
    StartDialogue("DDpoten1",[PC])
END

IF
  Detect([ENEMY])
  Range([ENEMY],7)
THEN
  RESPONSE #100
    ApplyDamage([ENEMY],20,ELECTRICITY)
    ApplyDamage([ENEMY],5,FIRE)
    Wait(5)
END

IF
  Global("magmis","LOCALS",0)
  See(NearestEnemyOf(Myself))
THEN
  RESPONSE #100
    ReallyForceSpell(NearestEnemyOf(Myself),WIZARD_MAGIC_MISSILE)
    ReallyForceSpell(NearestEnemyOf(Myself),WIZARD_MAGIC_MISSILE)
    ReallyForceSpell(NearestEnemyOf(Myself),WIZARD_MAGIC_MISSILE)
    SetGlobal("magmis","LOCALS",1)
END

IF
  See(NearestEnemyOf(Myself))
  Global("defense","LOCALS",0)
THEN
  RESPONSE #100
    SetGlobal("defense","LOCALS",1)
    ApplySpell(Myself,WIZARD_STONE_SKIN)
    ApplySpell(Myself,WIZARD_ABSOLUTE_IMMUNITY)
END

