Due to update 2.4.3, some mods may no longer function. FixedConfig may be necessary.
Decompiled source of BoplRoundTimer v1.0.0
plugins/BoplRoundTimer.dll
Decompiled 16 minutes agousing System.Reflection; using BepInEx; using UnityEngine; [assembly: AssemblyVersion("1.0.0.0")] namespace BoplRoundTimer; [BepInPlugin("com.plusplus.boplroundtimer", "Bopl Round Timer", "1.0.0")] public sealed class Plugin : BaseUnityPlugin { private Object session; private float nextLookup; private FieldInfo roundInProgress; private float elapsed; private bool running; private bool visible; private string label; private int displayedSeconds; public Plugin() { displayedSeconds = -1; } private void Awake() { roundInProgress = typeof(GameSessionHandler).GetField("gameInProgress", BindingFlags.Instance | BindingFlags.Public | BindingFlags.NonPublic); } private void Update() { if ((object)roundInProgress == null) { return; } if (!(Time.unscaledTime < nextLookup)) { nextLookup = Time.unscaledTime + 0.25f; session = Object.FindObjectOfType(typeof(GameSessionHandler)); } if (!Object.op_Implicit(session)) { running = false; visible = false; return; } if (!(bool)roundInProgress.GetValue(session)) { running = false; return; } if (!running) { elapsed = 0f; running = true; visible = true; } else { if (Time.timeScale <= 0f) { return; } elapsed += Time.unscaledDeltaTime; } int num = (int)elapsed; if (displayedSeconds != num) { displayedSeconds = num; label = $"{num / 60:00}:{num % 60:00}"; } } private void OnGUI() { //IL_0026: Unknown result type (might be due to invalid IL or missing references) if (visible) { GUI.Box(new Rect((float)Screen.width - 124f, 14f, 108f, 30f), label); } } }