mistername / RiskOfRainModding

3 stars 7 forks source link

TextPlus doesn't function correctly. #2

Closed Higgs1 closed 5 years ago

Higgs1 commented 5 years ago

Hey again,

Great job fixing #1 , but it appears that another mod I'd love to use in my game has a similar issue: TextPlus.

https://github.com/mistername/RiskOfRainModding/blob/d7cff19f38742d9b4edeb0c4259d0d667886e24a/TextPlus/TextPlus.cs#L40

pathForLanguageFile.LastIndexOf("plugins") returns -1 thus making some path that doesn't really exist.

From the mod description, I'm assuming you'd like the language files to be in the same directory as the one BepInEx uses to load mods - which is super neat btw. That folder is actually located at BepInEx.Paths.PluginPath

Thanks! :D

mistername commented 5 years ago

You are right, the folder for plugins in my end is BepInEx\plugins but if an user has a different folder for it it will not work. BepInEx.Paths.PluginPath always returns the correct path and as such I will use it from now on. a similar problem happens on the config folder sometimes and thanks to you I also fixed that part. It's fixed since ae53edcd4a079afcdb88fe3b519228ee125a5b2a and every mod affected by it is updated on thunderstore.