-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
371 additions
and
157 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 changes: 26 additions & 0 deletions
26
Fika.Core/Coop/Patches/Class1374_ReloadBackendLocale_Patch.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
using SPT.Reflection.Patching; | ||
using System.Reflection; | ||
using System.Threading.Tasks; | ||
|
||
namespace Fika.Core.Coop.Patches | ||
{ | ||
internal class Class1374_ReloadBackendLocale_Patch : ModulePatch | ||
{ | ||
private static bool HasBeenSet = false; | ||
|
||
protected override MethodBase GetTargetMethod() | ||
{ | ||
return typeof(Class1374).GetMethod(nameof(Class1374.ReloadBackendLocale)); | ||
} | ||
|
||
[PatchPostfix] | ||
public static void Postfix(Task __result) | ||
{ | ||
if (!HasBeenSet) | ||
{ | ||
FikaPlugin.Instance.StartCoroutine(FikaPlugin.Instance.WaitForLocales(__result)); | ||
HasBeenSet = true; | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters