From e75153d8ac12b07f9a47fc08b55a1c6ddb1c4162 Mon Sep 17 00:00:00 2001 From: truebrain Date: Mon, 19 Dec 2011 20:44:31 +0000 Subject: (svn r23597) -Codechange: fix up squirrel export script a bit --- src/script/squirrel_helper.hpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/script/squirrel_helper.hpp') diff --git a/src/script/squirrel_helper.hpp b/src/script/squirrel_helper.hpp index 03f1315fa..cdc4b8b8f 100644 --- a/src/script/squirrel_helper.hpp +++ b/src/script/squirrel_helper.hpp @@ -109,7 +109,9 @@ namespace SQConvert { template <> inline void *GetParam(ForceType , HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { SQUserPointer tmp; sq_getuserpointer(vm, index, &tmp); return tmp; } template <> inline const char *GetParam(ForceType, HSQUIRRELVM vm, int index, SQAutoFreePointers *ptr) { + /* Convert what-ever there is as parameter to a string */ sq_tostring(vm, index); + const SQChar *tmp; sq_getstring(vm, -1, &tmp); char *tmp_str = strdup(SQ2OTTD(tmp)); -- cgit v1.2.3-54-g00ecf