From 25f9952c671f181f92f2db11db36fadda9037b4b Mon Sep 17 00:00:00 2001 From: IceHax Date: Wed, 26 Sep 2018 17:53:21 +0200 Subject: [PATCH 1/2] fix names with color codes coloring the whole console. --- resources/[system]/hardcap/server.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/[system]/hardcap/server.lua b/resources/[system]/hardcap/server.lua index bce633d..bb54756 100644 --- a/resources/[system]/hardcap/server.lua +++ b/resources/[system]/hardcap/server.lua @@ -20,7 +20,7 @@ end) AddEventHandler('playerConnecting', function(name, setReason) local cv = GetConvarInt('sv_maxclients', 32) - print('Connecting: ' .. name) + print('Connecting: ' .. name .. '^7') if playerCount >= cv then print('Full. :(') From 471b19d37c88b62df832c7193e75a23f478b3cdf Mon Sep 17 00:00:00 2001 From: IceHax Date: Wed, 26 Sep 2018 18:06:30 +0200 Subject: [PATCH 2/2] fix colored chat messages print in console --- resources/[system]/chat/sv_chat.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/[system]/chat/sv_chat.lua b/resources/[system]/chat/sv_chat.lua index a619f85..245ae74 100644 --- a/resources/[system]/chat/sv_chat.lua +++ b/resources/[system]/chat/sv_chat.lua @@ -18,7 +18,7 @@ AddEventHandler('_chat:messageEntered', function(author, color, message) TriggerClientEvent('chatMessage', -1, author, { 255, 255, 255 }, message) end - print(author .. ': ' .. message) + print(author .. '^7: ' .. message .. '^7') end) AddEventHandler('__cfx_internal:commandFallback', function(command) @@ -76,4 +76,4 @@ AddEventHandler('onServerResourceStart', function(resName) for _, player in ipairs(GetPlayers()) do refreshCommands(player) end -end) \ No newline at end of file +end)