Replace deprecated meta:set_string(*, nil)
calls
This commit is contained in:
parent
653e76c165
commit
33c045fafb
@ -379,7 +379,6 @@ minetest.register_node("techage:ta4_icta_controller", {
|
||||
meta:set_string("number", number)
|
||||
meta:set_int("state", techage.STOPPED)
|
||||
meta:set_string("formspec", techage.formspecRules(meta, fs_data, sOUTPUT))
|
||||
--meta:set_string("formspec", techage.cond_formspec(1, 1, nil))
|
||||
meta:set_string("infotext", "TA4 ICTA Controller "..number..": stopped")
|
||||
end,
|
||||
|
||||
|
@ -202,7 +202,7 @@ local function on_receive_fields(pos, formname, fields, player)
|
||||
local meta = M(pos)
|
||||
logic.infotext(meta, NDEF(pos).description)
|
||||
if fields.exit then
|
||||
meta:set_string("formspec", nil)
|
||||
meta:set_string("formspec", "")
|
||||
meta:set_string("fixed" , "true")
|
||||
else
|
||||
meta:set_string("formspec", formspec(meta))
|
||||
|
@ -25,7 +25,7 @@ local function join_to_string(tbl)
|
||||
end
|
||||
|
||||
local function reset_programmer(itemstack, user, pointed_thing)
|
||||
user:get_meta():set_string("techage_prog_numbers", nil)
|
||||
user:get_meta():set_string("techage_prog_numbers", "")
|
||||
minetest.chat_send_player(user:get_player_name(), S("[TechAge Programmer] programmer reset"))
|
||||
return itemstack
|
||||
end
|
||||
@ -53,7 +53,7 @@ local function program_numbers(itemstack, placer, pointed_thing)
|
||||
if pos then
|
||||
local meta = M(pos)
|
||||
local numbers = minetest.deserialize(placer:get_meta():get_string("techage_prog_numbers")) or {}
|
||||
placer:get_meta():set_string("techage_prog_numbers", nil)
|
||||
placer:get_meta():set_string("techage_prog_numbers", "")
|
||||
local player_name = placer:get_player_name()
|
||||
if meta and meta:get_string("owner") ~= player_name then
|
||||
minetest.chat_send_player(player_name, S("[TechAge Programmer] foreign or unknown node!"))
|
||||
|
@ -429,7 +429,7 @@ techage.register_node({"techage:terminal2"}, {
|
||||
local number = meta:get_string("number") or ""
|
||||
if number ~= "" then
|
||||
meta:set_string("node_number", number)
|
||||
meta:set_string("number", nil)
|
||||
meta:set_string("number", "")
|
||||
end
|
||||
end,
|
||||
})
|
||||
|
@ -75,7 +75,7 @@ for idx,pgn in ipairs(tPgns) do
|
||||
minetest.swap_node(pos, node)
|
||||
end
|
||||
if fields.exit then
|
||||
meta:set_string("formspec", nil)
|
||||
meta:set_string("formspec", "")
|
||||
local number = techage.add_node(pos, node.name)
|
||||
meta:set_string("infotext", S("TechAge Door Block").." "..number)
|
||||
end
|
||||
|
@ -61,7 +61,7 @@ for idx,pgn in ipairs(tPgns) do
|
||||
minetest.swap_node(pos, node)
|
||||
end
|
||||
if fields.exit then
|
||||
meta:set_string("formspec", nil)
|
||||
meta:set_string("formspec", "")
|
||||
local number = techage.add_node(pos, node.name)
|
||||
meta:set_string("infotext", S("TechAge Gate Block").." "..number)
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user