mirror of
https://github.com/sp-tarkov/modules.git
synced 2025-02-13 08:30:45 -05:00
Needs merged with: SPT-AKI/Server#262 Short story first: Last night I was poking around the code as I always do looking for the cause of an exception and got sick and tired of the generic bad exceptions we always work off of. So I fixed it. This allows us access to BSG's internal logging using Nlog. This is useful for everybody. Not just SPT dev's, but mod dev's alike. It can be enabled from `core.json` with the option to send the output to the server. Here's an example of the improvement, its huge. Bepinex console is the gerneric logging we always use, the editor behind it is the improved logging from Nlog. Its night and day. ![image](/attachments/491dd8b6-e89a-4809-b19e-c5906ab6989e) The levels are based off of Nlog ordinals where low is more logging, high is less. (Stupid I know, but what can you do) Verbosity is as follows: * In all cases, except off, better exceptions will be logged. * to see the logging output in your bepinex logs, make sure you have debug logging enabled in bepinex. * WARNING: trace-info logging will quickly create log files in the megabytes. * 0 - trace * 1 - debug * 2 - info * 3 - warn * 4 - error * 5 - fatal * 6 - off Co-authored-by: Cj <161484149+CJ-SPT@users.noreply.github.com> Reviewed-on: SPT-AKI/Modules#96 Co-authored-by: Cj <cj@noreply.dev.sp-tarkov.com> Co-committed-by: Cj <cj@noreply.dev.sp-tarkov.com>