VideoTamperPatch, configurable outside of the BepInEx config

This commit is contained in:
2025-08-20 15:40:39 -04:00
parent 95cfd7ebb0
commit b796a6b075
7 changed files with 104 additions and 2 deletions

View File

@@ -0,0 +1,6 @@
namespace undead_universal_patch_il2cpp.Core.Config;
public class BaseOptionConfig
{
public bool Enabled { get; set; } = false;
}

View File

@@ -2,7 +2,7 @@ using System;
using System.IO;
using System.Text.Json;
namespace undead_universal_patch_il2cpp.Core;
namespace undead_universal_patch_il2cpp.Core.Config;
public class DediConfig<T>
{
@@ -23,7 +23,8 @@ public class DediConfig<T>
_options = options;
}
private string GetAlways() {
private string GetAlways()
{
if (!File.Exists(path))
{
File.WriteAllText(path, _default);

View File

@@ -1,4 +1,5 @@
using System.Collections.Generic;
using undead_universal_patch_il2cpp.Core.Config;
namespace undead_universal_patch_il2cpp.Core.Content.UndeadGameManager;

View File

@@ -1,4 +1,5 @@
using System.Collections.Generic;
using undead_universal_patch_il2cpp.Core.Config;
namespace undead_universal_patch_il2cpp.Core.Content.UndeadGameManager;

View File

@@ -7,6 +7,7 @@ using undead_universal_patch_il2cpp.Core.Config;
using undead_universal_patch_il2cpp.Core.Content.CustomRecNet.CustomEmotes;
using undead_universal_patch_il2cpp.Core.Content.CustomRecNet.CustomPhoton;
using undead_universal_patch_il2cpp.Core.Content.UndeadGameManager;
using undead_universal_patch_il2cpp.Patches.Video;
using UnityEngine;
namespace undead_universal_patch_il2cpp.Core;
@@ -50,6 +51,7 @@ public class Initialization
{
if (GameManagerConfig.AnyGameFreeSpawn.Value) GameFreeSpawns.config.Get();
if (GameManagerConfig.StaticGameConfig.Value) GameConfigurator.config.Get();
VideoTamperPatch.config.Get();
}
private static void AttachGameObjects()