Open lilly1987 opened 2 years ago
Greetings!
The issue is probably caused by the plugin being run before i18nEx, which causes some getters in Product
to get inlined. Once methods are inlined, i18nEx cannot patch these getters, the most crucial being Product.isJapan
used in multiple places like Product.windowTitel
and many other places to determine whether the game should use custom localisations.
I suggest doing either one of the following:
Product
getters in Awake
. Preferably call them once the game is fully initialised, like after GameUty.Init
.Add a soft BepInDependency
to horse.coder.com3d2.i18nex
as follows:
[BepInDependency("horse.coder.com3d2.i18nex", BepInDependency.DependencyFlags.SoftDependency)]
If i18nEx is present, this will cause your plugin to load after it, ensuring that important getters in Product
are patched before they get inlined.
https://cdn.discordapp.com/attachments/736350853442699284/932926197405470770/2022-01-18_18-06-55.mp4