mirror of
https://github.com/minetest-mods/MoreMesecons.git
synced 2025-06-30 07:20:36 +02:00
Change README.md and fix a bug for teleporter and wireless
This commit is contained in:
@ -1,4 +1,4 @@
|
||||
wireless = {}
|
||||
local wireless = {}
|
||||
|
||||
local register = function(pos)
|
||||
local meta = minetest.env:get_meta(pos)
|
||||
@ -56,6 +56,12 @@ minetest.register_node("moremesecons_wireless:wireless", {
|
||||
meta:set_string("formspec", "field[channel;channel;${channel}]")
|
||||
register(pos)
|
||||
end,
|
||||
on_destruct = function(pos)
|
||||
local RID = minetest.get_meta(pos):get_int("RID")
|
||||
if RID then
|
||||
table.remove(wireless, RID)
|
||||
end
|
||||
end,
|
||||
on_receive_fields = function(pos, formname, fields, sender)
|
||||
local meta = minetest.get_meta(pos)
|
||||
meta:set_string("channel", fields.channel)
|
||||
|
Reference in New Issue
Block a user