1
0
mirror of https://github.com/Refactorio/RedMew.git synced 2025-03-03 14:53:01 +02:00

Add server print on admin_prints (#430)

* Add server print on admin_prints
This commit is contained in:
Matthew 2018-11-22 17:04:01 -05:00 committed by Valansch
parent 9ede998686
commit 8fb9ae35d7

View File

@ -32,9 +32,11 @@ Module.print_admins = function(msg, source)
source_name = 'Server'
chat_color = {r = 255, g = 255, b = 255}
end
local formatted_msg = string.format('%s(ADMIN) %s: %s', prefix, source_name, msg) -- to the server
print(formatted_msg)
for _, p in pairs(game.connected_players) do
if p.admin then
p.print(string.format('%s(ADMIN) %s: %s', prefix, source_name, msg), chat_color)
p.print(formatted_msg, chat_color)
end
end
end