diff options
Diffstat (limited to 'src/ai/ai_instance.cpp')
-rw-r--r-- | src/ai/ai_instance.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/ai/ai_instance.cpp b/src/ai/ai_instance.cpp index 6d3397a70..a5ef5135b 100644 --- a/src/ai/ai_instance.cpp +++ b/src/ai/ai_instance.cpp @@ -352,6 +352,10 @@ void AIInstance::GameLoop() } catch (AI_VMSuspend e) { this->suspend = e.GetSuspendTime(); this->callback = e.GetSuspendCallback(); + } catch (AI_FatalError e) { + this->engine->ThrowError(e.GetErrorMessage()); + this->engine->ResumeError(); + this->Died(); } this->is_started = true; @@ -368,6 +372,10 @@ void AIInstance::GameLoop() } catch (AI_VMSuspend e) { this->suspend = e.GetSuspendTime(); this->callback = e.GetSuspendCallback(); + } catch (AI_FatalError e) { + this->engine->ThrowError(e.GetErrorMessage()); + this->engine->ResumeError(); + this->Died(); } } |