diff --git a/functions.lua b/functions.lua index 1c6d13f..470ed3e 100644 --- a/functions.lua +++ b/functions.lua @@ -701,16 +701,20 @@ yl_speak_up.set_muted = function(p_name, obj, set_muted) luaentity.yl_speak_up.talk = false yl_speak_up.update_nametag(luaentity) - minetest.chat_send_player(p_name,"NPC with ID n_"..npc.." will shut up at pos ".. - minetest.pos_to_string(obj:get_pos(),0).." on command of "..p_name) +-- minetest.chat_send_player(p_name,"NPC with ID n_"..npc.." will shut up at pos ".. +-- minetest.pos_to_string(obj:get_pos(),0).." on command of "..p_name) + minetest.chat_send_player(p_name, "NPC n_"..tostring(npc).." is now muted and will ".. + "only talk to those who can edit the NPC.") yl_speak_up.log_change(p_name, "n_"..npc, "muted - NPC stops talking") elseif(not(set_muted) and not(luaentity.yl_speak_up.talk)) then -- mute the npc luaentity.yl_speak_up.talk = true yl_speak_up.update_nametag(luaentity) - minetest.chat_send_player(p_name,"NPC with ID n_"..npc.." will resume speech at pos ".. - minetest.pos_to_string(obj:get_pos(),0).." on command of "..p_name) + minetest.chat_send_player(p_name, "NPC n_"..tostring(npc).." is no longer muted and ".. + "will talk with any player who right-clicks the NPC.") +-- minetest.chat_send_player(p_name,"NPC with ID n_"..npc.." will resume speech at pos ".. +-- minetest.pos_to_string(obj:get_pos(),0).." on command of "..p_name) yl_speak_up.log_change(p_name, "n_"..npc, "unmuted - NPC talks again") end end