Skip to content
User Avatar
#2771
Auto-translated
I want to summon the hero "Sarge" from the reserve, but the console gives an error saying that the hero does not belong to any player. Basically, the question is, why is he different from the other 10 reserved heroes?
Also, just in case, I'll post the code from which he is summoned.

function TheEnd()
while (1) do
sleep(2);
if (Exists("Zehir") == nil) and (Exists("Eruina") == nil) then
SuperTheEnd()
break
end
end
end

function SuperTheEnd()
DeployReserveHero("Sarge", 14, 134, GROUND)
sleep(2)
EnableHeroAI("Sarge", nil)
sleep(2)
StartAdvMapDialog(8)
sleep(25)
Win()
end

(I split it into 2 functions because I was trying to somehow fix and change the code so that it would work. In the end, it doesn't work in either function, or in both).
Автор карт:
Долина расхитителей
Выбор мира