print("sovereign vs raelag - no shield");
d = GetGameVar("C6M5_diff") + 0;

--monsters: demiliches, imps and cerberi
 
function Prepare()
	EnableCinematicCamera(nil);
	sleep(10);
	SummonCreature(DEFENDER, 38, 30 + d * 10, 10, 8);
	sleep(10);
	SummonCreature(DEFENDER, 38, 30 + d * 10, 10, 3);
	sleep(10);
end

function Start()
	EnableAutoFinish(nil);
	sleep(10);
	SummonCreature(DEFENDER, 19, 40 + d * 10, 4, 3);
	sleep(10);
	SummonCreature(DEFENDER, 20, 30 + d * 10, 4, 5);
	sleep(10);
	SummonCreature(DEFENDER, 19, 40 + d * 10, 4, 8);
	sleep(10);
	EnableCinematicCamera(not nil);
end

death = 0
function DefenderCreatureDeath()
	death = death + 1
	if death == 1 then
		sleep(10);
		SummonCreature(DEFENDER, 28, 25 + d * 5, 8, 6);
	end
	if death == 2 then
		sleep(10);
		SummonCreature(DEFENDER, 25, 10 + d * 5, 9, 6);
	end
	if death == 3 then
		sleep(10);
		SummonCreature(DEFENDER, 22, 30 + d * 10, 10, 6);
	end
	local defenders = GetDefenderCreatures();
	if (length(defenders) == 0) then Finish(ATTACKER) end;
end

function AttackerCreatureDeath()
	local attackers = GetAttackerCreatures();
	if (length(attackers) == 0) then Finish(DEFENDER) end;
end

function DefenderHeroMove(heroName)
	UnitCastGlobalSpell(GetDefenderHero(), 239);
	return not nil
end
