diff --git a/01_DCS/Mods/services/Perun/lua/perun_config.lua b/01_DCS/Mods/services/Perun/lua/perun_config.lua index af632f1..120ee0e 100644 --- a/01_DCS/Mods/services/Perun/lua/perun_config.lua +++ b/01_DCS/Mods/services/Perun/lua/perun_config.lua @@ -18,6 +18,7 @@ PerunConfig.ConnectionError_L1 = "[Perun] ERROR: Connection broken - contact ser -- Misc PerunConfig.BroadcastPerunErrors = 1 -- (int) [0 (default),1] Value greater than 0 will broadcast chat message about missing connection to Perun +PerunConfig.RecordChatMessages = 1 -- Debug PerunConfig.DebugMode = 1 -- (int) [0 (default),1,2] Value greater than 0 will display Perun information in DCS log file, values: 1 - minimal verbose, 2 - all log information will be logged diff --git a/01_DCS/Scripts/Hooks/Perun-hook.lua b/01_DCS/Scripts/Hooks/Perun-hook.lua index d3fd71a..d28be79 100644 --- a/01_DCS/Scripts/Hooks/Perun-hook.lua +++ b/01_DCS/Scripts/Hooks/Perun-hook.lua @@ -24,6 +24,7 @@ Perun.MOTD_L1 = PerunConfig.MOTD_L1 Perun.MOTD_L2 = PerunConfig.MOTD_L2 Perun.ConnectionError = PerunConfig.ConnectionError_L1 Perun.BroadcastPerunErrors = PerunConfig.BroadcastPerunErrors +Perun.RecordChatMessages = PerunConfig.RecordChatMessages -- Variable init Perun.Version = "v0.12.1" @@ -706,7 +707,7 @@ end Perun.onPlayerTrySendChat = function (playerID, msg, all) -- Somebody tries to send chat message - if msg~=Perun.MOTD_L1 and msg~=Perun.MOTD_L2 and msg~=Perun.ConnectionError then + if Perun.RecordChatMessages and msg~=Perun.MOTD_L1 and msg~=Perun.MOTD_L2 and msg~=Perun.ConnectionError then Perun.LogChat(playerID,msg,all) end