Connection ErrorBad RequestSession 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.
Request Failed
We encountered an issue while processing your request.
Please check your internet connection and try again.
Or maybe there's an interceptor for outputting strings to the console?
The function _ERRORMESSAGE is responsible for this, which displays messages like (Script) ERROR
errormsg = _ERRORMESSAGE function _ERRORMESSAGE(string) if string ~= "Hitler kaput" then errormsg(string) end end
This is if the output string is the same; otherwise, you need to equate _ERRORMESSAGE = parse('') for a while.
function DoNotShowErrorMessage() local err = _ERRORMESSAGE _ERRORMESSAGE = parse('') -- or _ERRORMESSAGE = function()end sleep(1) _ERRORMESSAGE = err end
And if the error is caused by the game itself, like:
"attempt to call a nil value"
And the line needs to be removed only in one specific case.
_ERRORMESSAGE = "attempt to call a nil value" ?
What if the error is generated by the game, like: "attempt to call a nil value" And the line needs to be removed only in one case. _ERRORMESSAGE = "attempt to call a nil value" ?
Then the first option will work.
errormsg = _ERRORMESSAGE function _ERRORMESSAGE(string) if string ~= "attempt to call a nil value" then errormsg(string) end end
Such an error could occur when passing a message to a function (...Box) with an argument. For example, MessageBox(path..'a.txt','yes("'..hero..'")'). In this case, other tricks are needed, namely return parse('') at the end of this function (yes).
This kind of error could occur when passing a message to a function (...Box) with an argument. For example, MessageBox(path..'a.txt','yes("'..hero..'")'). In this case, other tricks are needed, namely, return parse('') at the end of this function (yes).
Создается карта про эльфов: Воссоединение - готовность 71%
Spectral
Auto-translated
I need to create a script where the hero casts spells on enemy creatures at the beginning of the battle, but if the enemy has immunity, the script throws an error. I tried using an interceptor, but after that, the game freezes, and I can't finish the battle. What should I do?
Создается карта про эльфов: Воссоединение - готовность 71%
Instead of UnitCastAimedSpell(unit, spell, target), use startThread(UnitCastAimedSpell, unit, spell, target). The error will still be there, but it won’t affect the script’s further execution.