From b0f3db9328c969c77510a87910bf4bae5945bafd Mon Sep 17 00:00:00 2001 From: metalstache Date: Fri, 19 Jul 2013 23:22:23 -0400 Subject: [PATCH] Fix nil variable in after function --- init.lua | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/init.lua b/init.lua index 3466059..9e16aad 100644 --- a/init.lua +++ b/init.lua @@ -59,7 +59,7 @@ minetest.register_on_joinplayer(function(player) specialties.players[name].skills = {} specialties.players[name].skills = specialties.readXP(name) specialties.players[name].hud = {} - minetest.after(0.5, function() + minetest.after(0.5, function(name) local Yoffset = 0.02 local y = 0 for skill,num in pairs(specialties.players[name].skills) do @@ -82,7 +82,8 @@ minetest.register_on_joinplayer(function(player) }) y = y+Yoffset end - end) + end, + name) end) local function show_formspec(name, specialty) minetest.show_formspec(name, "specialties:spec", get_specialInfo(name, specialty))