mirror of
https://github.com/technix/ham_radio.git
synced 2024-08-19 04:34:09 +02:00
fix protection
This commit is contained in:
parent
5ece6f8383
commit
4fb166ebe4
@ -34,9 +34,13 @@ minetest.register_node("ham_radio:transmitter", {
|
||||
meta:set_string("infotext", '')
|
||||
end,
|
||||
on_receive_fields = function(pos, formname, fields, sender)
|
||||
if not minetest.is_player(sender) then
|
||||
return
|
||||
end
|
||||
|
||||
if (
|
||||
fields.quit ~= "true"
|
||||
or minetest.is_protected(pos, name)
|
||||
or minetest.is_protected(pos, sender:get_player_name())
|
||||
or not ham_radio.validate_frequency(fields.frequency)
|
||||
) then
|
||||
return
|
||||
|
Loading…
Reference in New Issue
Block a user