From ac25db2c0d0ea974a5aa62d2cdb9b0a012a89a3a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20N=C3=BCcke?= Date: Thu, 3 Jul 2014 11:35:44 +0200 Subject: [PATCH] Added missing userdata wrapping and removed debug prints. --- src/main/resources/assets/opencomputers/lua/kernel.lua | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/main/resources/assets/opencomputers/lua/kernel.lua b/src/main/resources/assets/opencomputers/lua/kernel.lua index 0adabafca..300cba059 100644 --- a/src/main/resources/assets/opencomputers/lua/kernel.lua +++ b/src/main/resources/assets/opencomputers/lua/kernel.lua @@ -344,9 +344,7 @@ local userdataWrapper = { -- reflection when loading again (and then immediately wrap it again). -- Collect wrapped callback methods. [persistKey or "LuaJ"] = function(self) - print("start saving userdata " .. tostring(wrappedUserdata[self])) local className, nbt = userdata.save(wrappedUserdata[self]) - print("done saving userdata") -- The returned closure is what actually gets persisted, including the -- upvalues, that being the classname and a byte array representing the -- nbt data of the userdata value. @@ -667,6 +665,7 @@ local function main() error("computer stopped unexpectedly", 0) else args = table.pack(coroutine.yield(result[2])) -- system yielded value + wrapUserdata(args) end end end