Page 1 of 1
Access Mod Settings UI When Mod is in a Modpack/Game?

Posted:
Sat Jan 21, 2017 00:22
by echosa
I just recently found out that mods can add their own settings to the settings UI. However, when I add these mods to my custom game, I do not get that UI. I'm assuming that the only way to get those settings in the UI is to install the mod globally.
Is there a way to get those options available in the settings UI when the mod is installed in a game (or even a modpack)?
Re: Access Mod Settings UI When Mod is in a Modpack/Game?

Posted:
Sat Jan 21, 2017 13:24
by Wuzzy
You could add a file called “settingtypes.txt” into the subgame directory itself. It works, Minetest Game makes use of it. The settings will then appear under “Games” in advanced settings.
Personally, I dislike this approach as this introduces a totally avoidable redundancy.
Re: Access Mod Settings UI When Mod is in a Modpack/Game?

Posted:
Sun Jan 22, 2017 03:36
by echosa
What redundancy do you mean? I'm genuinely curious. I guess I don't fully understand the issue, since the settings for the game would be specifically under that game, so I assume each game would have its own settings/area.
Re: Access Mod Settings UI When Mod is in a Modpack/Game?

Posted:
Sun Jan 22, 2017 15:30
by Wuzzy
Well, it's redundant because you would have settingtypes.txt both in the subgame directory AND the mod directories. You can't just drop in a mod with correctly specified settingtypes.txt because, as you already noticed, this gets ignored if the mod is part of a subgame. Which forces subgame authors to basically copy all mod settings in a subgame settingtypes.txt, which I think is a little bit stupid.
This is basically a design flaw in Minetest itself IMO. But don't worry too much: The settings WILL still be distinct on a per-subgame basis.
Long story short: Just provide a settingtypes.txt in the subgame directory and you're done.