mirror of
https://github.com/sys4-fr/server-nalc.git
synced 2025-01-23 16:30:19 +01:00
parent
1ae26b05f9
commit
8990897e53
@ -7,12 +7,13 @@ dofile(minetest.get_modpath("death_messages").."/settings.txt")
|
||||
-----------------------------------------------------------------------------------------------
|
||||
|
||||
-- A table of quips for death messages
|
||||
|
||||
local messages = {}
|
||||
|
||||
-- Another one to avoid double death messages
|
||||
local whacked = {}
|
||||
|
||||
local logfile = minetest.get_worldpath() .. "/death_logs.txt"
|
||||
|
||||
-- Fill this table with sounds
|
||||
local sounds = {
|
||||
[1] = "death_messages_player_1",
|
||||
@ -90,6 +91,9 @@ messages.whacking = {
|
||||
|
||||
local function broadcast_death(msg)
|
||||
minetest.chat_send_all(msg)
|
||||
local logfilep = io.open(logfile, "a")
|
||||
logfilep:write(os.date("[%Y-%m-%d %H:%M:%S] ") .. msg .. "\n")
|
||||
logfilep:close()
|
||||
if irc then
|
||||
irc:say(msg)
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user