Skip to content

Commit

Permalink
Add debug logs
Browse files Browse the repository at this point in the history
  • Loading branch information
brandonsturgeon committed Feb 15, 2021
1 parent f85cdea commit 00bfcb7
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions moon/cfc_chat_transit/server/init.moon
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,8 @@ ChatTransit.ReceiveMessage = (ply, text, teamChat) =>
return unless text
return if text == ""

@Logger\debug "Received message for #{ply\Nick!}, '#{text}'"

teamName = ply\Team!
rankColor = @GetTeamColorCode teamName
avatar = ply.PlayerSummary.response.players[1].avatar
Expand All @@ -67,4 +69,6 @@ ChatTransit.ReceiveMessage = (ply, text, teamChat) =>

@WebSocket\write message

@Logger\debug "Sent message '#{text}' to websocket"

hook.Add "PlayerSay", "CFC_ChatTransit_MessageListener", ChatTransit\ReceiveMessage, HOOK_MONITOR_LOW

0 comments on commit 00bfcb7

Please sign in to comment.