Connection ErrorBad RequestThis page went staleSession ExpiredSign in requiredForbiddenNot FoundToo Many RequestsServer ErrorBad GatewayService UnavailableGateway TimeoutHTTP Version Not Supported
Session Expired
Your session has expired. Please log in to continue.
Sign in required
You need an account to do that. Sign in or create one — it only takes a minute.
This page went stale
Your security token was rejected, usually because the page sat open too long or you signed in elsewhere. Nothing was saved. Reload the page and try again.
Request Failed
We encountered an issue while processing your request.
Please check your internet connection and try again.
Error Details:
Share Link
Current questions and answers regarding the map editor.
Hello. Please help me with a script. The task is: if a unit is lost in the army, it results in a defeat. But after a *certain point*, the unit needs to be lost. How can I make it so that the scripted loss of the unit is not penalized with a defeat, but if the loss occurs before *this point*, then the defeat is counted? Below is the code that tracks the unit in the hero's army, and if it's not there, the map is lost.
function lostDragon() -- Checks for the loss of the dragon
while 1 do
sleep (10);
if GetHeroCreatures("Ohtarig", 83) == 0 and dragon == 1 then
SetObjectiveState("q5", OBJECTIVE_FAILED);
sleep (10);
Loose();
break
end;
end;
end;
startThread(lostDragon)