From e86e5d57414eb4538f231384fae2d42cc144a17c Mon Sep 17 00:00:00 2001 From: Sandu Liviu Catalin Date: Sat, 10 Jul 2021 14:16:03 +0300 Subject: [PATCH] Update sqratLightObj.h --- module/Sqrat/sqratLightObj.h | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/module/Sqrat/sqratLightObj.h b/module/Sqrat/sqratLightObj.h index 3d58bdc8..02eff162 100644 --- a/module/Sqrat/sqratLightObj.h +++ b/module/Sqrat/sqratLightObj.h @@ -518,4 +518,15 @@ template < typename T > LightObj MakeLightObj(HSQUIRRELVM vm, const T & v) return Var< LightObj >(vm, -1).value; } +///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +inline StackStrF::StackStrF(HSQUIRRELVM vm, LightObj & o) + : StackStrF(vm, -1) +{ + sq_pushobject(vm, o.mObj); + // Process the object on the stack + Proc(false); + // Restore stack + sq_pop(vm, 1); +} + }