function spire_of_souls:source/creature/tutorial/encounter_phaseid/creature_ic if @e[name=Mordum,tag=!InCombat]

scoreboard players add @e[name=Mordum,score_SPC_Fel=203,score_SPC_Wait=0] SPC_Fel 1
scoreboard players add @e[name=Mordum,score_SPC_ICInject=401,score_SPC_Wait=0] SPC_ICInject 1
scoreboard players add @e[name=Mordum,score_SPC_VShift=605,score_SPC_Wait=0] SPC_VShift 1
scoreboard players add @e[name=SpellCastTriggerFel,tag=Update,score_SPC_Time=10] SPC_Time 1
scoreboard players add @e[name=SpellCastTriggerIceInject,tag=Update,score_SPC_Time=10] SPC_Time 1

function spire_of_souls:source/creature/tutorial/spellcast_trigger/spellcast_fel if @e[name=Mordum,score_SPC_Fel_min=203]
function spire_of_souls:source/creature/tutorial/spellcast_trigger/spellcast_ice_inject if @e[name=Mordum,score_SPC_ICInject_min=401]
function spire_of_souls:source/creature/tutorial/spellcast_trigger/spellcast_voidshift if @e[name=Mordum,score_SPC_VShift_min=605]

function spire_of_souls:source/creature/tutorial/spellcast_effect/effect_fel if @e[name=SpellCastTriggerFel,score_SPC_Time_min=10]
function spire_of_souls:source/creature/tutorial/spellcast_effect/effect_ice_inject if @e[name=SpellCastTriggerIceInject,score_SPC_Time_min=10]
function spire_of_souls:source/creature/tutorial/spellcast_particle/particle_fel if @e[name=SpellCastTriggerFel,score_SPC_Time_min=1]
function spire_of_souls:source/creature/tutorial/spellcast_particle/particle_ice_inject if @e[name=SpellCastTriggerIceInject,score_SPC_Time_min=1]
scoreboard players set @e[name=SpellCastTriggerFel,score_SPC_Time_min=10] SPC_Time 0
scoreboard players set @e[name=SpellCastTriggerIceInject,score_SPC_Time_min=10] SPC_Time 0
scoreboard players add @e[name=SpellCastTriggerFel,score_SPC_Time=0] SPC_TimeT 1
scoreboard players add @e[name=SpellCastTriggerIceInject,score_SPC_Time=0] SPC_TimeT 1
scoreboard players add @e[name=SpellCastTriggerFel,tag=Update,score_SPC_Time=0] SPC_TimeT 1
scoreboard players add @e[name=SpellCastTriggerIceInject,tag=Update,score_SPC_Time=0] SPC_TimeT 1

function spire_of_souls:source/creature/tutorial/creature_defeat if @e[name=Mordum,score_GetPercentHP=10]
function spire_of_souls:instance/instance_encounter/restart_encounter/zone_trial_of_mind if @a[score_GetPlayerDeath_min=1]