mirror of
https://github.com/OpenTTD/OpenTTD
synced 2026-01-21 19:32:54 +01:00
(svn r16481) [0.7] -Backport from trunk:
- Fix: [NoAI] Another try/catch related bug (r16454) - Fix: Road vehicles ending up on the pavement when they are in a drive through station that got removed due to bankruptcy [FS#2909] (r16448) - Fix: [NoAI] AIRail::GetRailStationDirection returned incorrect information (r16440) - Fix: Crash when a company is deleted while a dropdown with company names is open (r16430) - Change: [NoAI] Stop an AI when it takes too long to initialize or load [FS#2869] (r16425)
This commit is contained in:
@@ -209,7 +209,7 @@ bool Squirrel::CallMethod(HSQOBJECT instance, const char *method_name, HSQOBJECT
|
||||
if (ret != NULL) sq_getstackobj(vm, -1, ret);
|
||||
/* Reset the top, but don't do so for the AI main function, as we need
|
||||
* a correct stack when resuming. */
|
||||
if (suspend == -1) sq_settop(this->vm, top);
|
||||
if (!this->IsSuspended()) sq_settop(this->vm, top);
|
||||
/* Restore the return-value location. */
|
||||
this->vm->_suspended_target = last_target;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user