From 1bc1a419376b4d9cbd0153614aa8244d03247fc4 Mon Sep 17 00:00:00 2001 From: yexo Date: Thu, 1 Dec 2011 22:23:13 +0000 Subject: (svn r23392) -Fix: [NoAI] assigning 'null' to an AIList element to remove it didn't work --- src/script/api/script_list.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/script/api/script_list.cpp') 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")); } -- cgit v1.2.3-54-g00ecf