0
0
mirror of https://github.com/sp-tarkov/modules.git synced 2025-02-13 08:50:43 -05:00
modules/project/SPT.Debugging/SPTDebuggingPlugin.cs
2024-05-21 19:10:17 +01:00

50 lines
1.4 KiB
C#

using System;
using SPT.Common;
using SPT.Common.Http;
using SPT.Common.Utils;
using SPT.Debugging.Patches;
using BepInEx;
namespace SPT.Debugging
{
[BepInPlugin("com.SPT.debugging", "SPT.Debugging", SPTPluginInfo.PLUGIN_VERSION)]
public class SPTDebuggingPlugin : BaseUnityPlugin
{
public static LoggingLevelResponse logLevel;
public void Awake()
{
Logger.LogInfo("Loading: SPT.Debugging");
try
{
new EndRaidDebug().Enable();
new LoggerClassLogPatch().Enable();
// new CoordinatesPatch().Enable();
// new StaticLootDumper().Enable();
// new ExfilDumper().Enable();
// BTR debug command patches, can be disabled later
//new BTRDebugCommandPatch().Enable();
//new BTRDebugDataPatch().Enable();
//new PMCBotSpawnLocationPatch().Enable();
//new ReloadClientPatch().Enable();
}
catch (Exception ex)
{
Logger.LogError($"{GetType().Name}: {ex}");
throw;
}
Logger.LogInfo("Completed: SPT.Debugging");
}
public void Start()
{
var loggingJson = RequestHandler.GetJson("/singleplayer/enableBSGlogging");
logLevel = Json.Deserialize<LoggingLevelResponse>(loggingJson);
}
}
}