From 8fe06cd1ed75738503c582b7de60131bea4bc1ed Mon Sep 17 00:00:00 2001 From: misomosi Date: Mon, 18 May 2026 16:06:19 -0400 Subject: [PATCH] Add a way to restart the game through steam --- OSFE/RetroAchievements.cs | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/OSFE/RetroAchievements.cs b/OSFE/RetroAchievements.cs index dd96cb5..b4a0dbd 100644 --- a/OSFE/RetroAchievements.cs +++ b/OSFE/RetroAchievements.cs @@ -1,6 +1,12 @@ using HarmonyLib; using System.IO; using UnityEngine; +using Steamworks; + +static class RetroAchievements +{ + public static uint AppID = 960690u; +}; // We don't actually care much about hooking LoadItemData, but it's // called soon after mods are loaded, so it gives us an early entrypoint @@ -17,6 +23,12 @@ internal class EntryPoint static EntryPoint() { Debug.Log("Hello World!"); +#if false + // This is a way to restart the app immediately through steam + // Useful for restarting when user wants to switch to hardcore mode + Application.OpenURL("steam://run/" + RetroAchievements.AppID); + Application.Quit(); +#endif } static void Prefix() {} } -- 2.49.1