mirror of
				https://github.com/luanti-org/luanti.git
				synced 2025-11-04 01:05:48 +01:00 
			
		
		
		
	
		
			
				
	
	
		
			15 lines
		
	
	
		
			455 B
		
	
	
	
		
			Lua
		
	
	
	
	
	
			
		
		
	
	
			15 lines
		
	
	
		
			455 B
		
	
	
	
		
			Lua
		
	
	
	
	
	
--
 | 
						|
-- Mod channels experimental handlers
 | 
						|
--
 | 
						|
local mod_channel = core.mod_channel_join("experimental_preview")
 | 
						|
 | 
						|
core.register_on_modchannel_message(function(channel, sender, message)
 | 
						|
	core.log("action", "[modchannels] Server received message `" .. message
 | 
						|
			.. "` on channel `" .. channel .. "` from sender `" .. sender .. "`")
 | 
						|
 | 
						|
	if mod_channel:is_writeable() then
 | 
						|
		mod_channel:send_all("experimental answers to preview")
 | 
						|
		mod_channel:leave()
 | 
						|
	end
 | 
						|
end)
 |