diff options
author | yexo <yexo@openttd.org> | 2011-12-01 22:23:13 +0000 |
---|---|---|
committer | yexo <yexo@openttd.org> | 2011-12-01 22:23:13 +0000 |
commit | 1bc1a419376b4d9cbd0153614aa8244d03247fc4 (patch) | |
tree | 142c9cbd7f02452607c71472067beee812f68859 /src/script/api | |
parent | 42c92be121d406e70a0431ab0dacc7f6934ee9a5 (diff) | |
download | openttd-1bc1a419376b4d9cbd0153614aa8244d03247fc4.tar.xz |
(svn r23392) -Fix: [NoAI] assigning 'null' to an AIList element to remove it didn't work
Diffstat (limited to 'src/script/api')
-rw-r--r-- | src/script/api/script_list.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/script/api/script_list.cpp b/src/script/api/script_list.cpp index 70f07a9a3..14d400bcb 100644 --- a/src/script/api/script_list.cpp +++ b/src/script/api/script_list.cpp @@ -745,7 +745,7 @@ SQInteger ScriptList::_get(HSQUIRRELVM vm) SQInteger ScriptList::_set(HSQUIRRELVM vm) { if (sq_gettype(vm, 2) != OT_INTEGER) return SQ_ERROR; - if (sq_gettype(vm, 3) != OT_INTEGER || sq_gettype(vm, 3) == OT_NULL) { + if (sq_gettype(vm, 3) != OT_INTEGER && sq_gettype(vm, 3) != OT_NULL) { return sq_throwerror(vm, _SC("you can only assign integers to this list")); } |