Skip to content
This repository was archived by the owner on Oct 21, 2022. It is now read-only.

Commit ebc74f0

Browse files
committed
fix MODS button not showing after switching scenes
1 parent 139f095 commit ebc74f0

2 files changed

Lines changed: 9 additions & 3 deletions

File tree

ModLoader/Loader.cs

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,12 @@ private void Awake()
7575
}
7676

7777
Debug.Log("Early load finished");
78+
Helper.OnHomeSceneLoaded += this.OnGomeSceneLoaded;
79+
}
80+
81+
private void OnGomeSceneLoaded(object sender, EventArgs args)
82+
{
83+
this.insertModsButton();
7884
}
7985

8086
/// <summary>
@@ -89,10 +95,10 @@ private void Start()
8995
}
9096

9197
Debug.Log("Loading finished");
92-
this.postInit();
98+
this.insertModsButton();
9399
}
94100

95-
private void postInit()
101+
private void insertModsButton()
96102
{
97103
GameObject modsButton = GameObject.Instantiate(GameObject.Find("Exit Button"));
98104
ButtonPC buttonPC = modsButton.GetComponent<ButtonPC>();

ModLoader/SFSMod.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ public string Author
4343
}
4444

4545
/// <summary>
46-
/// Get what version of modloader this mod needs
46+
/// Get what min version of modloader this mod needs
4747
/// </summary>
4848
/// <value>
4949
/// v1.0.x

0 commit comments

Comments
 (0)