diff --git a/init.lua b/init.lua index 6d079e6..5d16c27 100644 --- a/init.lua +++ b/init.lua @@ -122,8 +122,15 @@ teleports.set_formspec = function(pos) y = y + 1 end + local label + if buttons == "" then + label = S("No teleport in range!") + else + label = S("Go to available teleports! Use mossy cobblestone as fuel!") + end + meta:set_string("formspec", "size[8,9;]" - .."label[0,0;" .. F(S("Go to available teleports! Use mossy cobblestone as fuel!")) .. "]" + .."label[0,0;"..F(label).."]" .."list[current_name;price;0,1;1,1;]" ..buttons .."button_exit[1,4;2,0.5;cancel;"..F(S("Cancel")).."]"