1
0
mirror of https://github.com/OpenTTD/OpenTTD synced 2026-01-22 19:54:06 +01:00

(svn r17564) [0.7] -Backport from trunk:

- Fix: Vehicles waiting for their time table did not load anymore after their initial load was completed [FS#3201] (r17551)
- Fix: Aircraft were given an unfair advantage in station rating calculations (r17550)
- Fix: [NewGRF] Sign extending of profit calculation did not work (r17546)
- Fix: [NoAI] AIs had 'infinite' time when running code from the global scope [FS#3202] (r17545)
- Fix: [NoAI] Crash when doing commands in the 'global' scope [FS#3202] (r17544)
This commit is contained in:
rubidium
2009-09-18 07:00:35 +00:00
parent a6251ba1a5
commit 803e452fab
3 changed files with 31 additions and 21 deletions

View File

@@ -466,7 +466,7 @@ static SQInteger _io_file_read(SQUserPointer file, SQUserPointer buf, SQInteger
/* Load and run the script */
if (SQ_SUCCEEDED(LoadFile(vm, script, SQTrue))) {
sq_push(vm, -2);
if (SQ_SUCCEEDED(sq_call(vm, 1, SQFalse, SQTrue))) {
if (SQ_SUCCEEDED(sq_call(vm, 1, SQFalse, SQTrue, 100000))) {
sq_pop(vm, 1);
return true;
}