Skip to content

Talent proper cleanup

Alex Ksandra requested to merge 0player/t-engine4:talent_proper_cleanup into master

Talents that use restinit & coroutine.yield can cause useTalent to get locked into "always forced target" state, which causes even more problems upon reload because the stub method it uses has an upvalue.

http://forums.te4.org/viewtopic.php?f=42&t=43331&p=194553

Not knowing the full details (the log is lost), I've thrown in an emergency cleanup in case a talent decided to coro out. Of course this does break stuff like using getTarget after coroutine.yield, but seeing as actually nothing does, and as it otherwise, as we've seen, may result in save corruption, I think that's a fine compromise.

Merge request reports