2025-08-19 20:05 CEST

spring: develop 08ecc2df Diff ] Back to Repository ]
Author Committer Branch Timestamp Parent
Tobi Vollebregt Tobi Vollebregt develop 2010-02-06 16:09:32 develop 4f6117b2
Changeset lua unit script: fixed Sleep/WaitFor not working in Killed

Couldn't yield through pcall. Added an 'onerror' callback function
on threads, which is called after a co_resume in which the thread
died due to an error. This is now used instead of pcall to ensure
SetDeathScriptFinished is called in Killed, even when an error occurs.

As a side effect stacktrace on error in Killed now works.
mod - installer/builddata/springcontent/LuaGadgets/Gadgets/unit_script.lua Diff ] File ]