Where should mods go?

Post Reply
rgh
Member
Posts: 46
Joined: Fri Oct 07, 2016 13:32

Where should mods go?

by rgh » Post

According to the wiki https://wiki.minetest.net/Help:Installing_Mods
As of 0.4.7, the mods are installed globally and enabled per world.
and yet, when I look at minetest-0.4.16, the minetest_game mods are all within the game at:

minetest-0.4.16-win64\games\minetest_game\mods

So, is the wiki incorrect, should I move all those mods, does minetest_game not follow the recommended file layout or... have I gotten the wrong idea entirely?

User avatar
Pyrollo
Developer
Posts: 385
Joined: Mon Jan 08, 2018 15:14
GitHub: pyrollo
In-game: Naj
Location: Paris

Re: Where should mods go?

by Pyrollo » Post

AFAIK wiki is correct. Mods can be installed in several places. mintest_game mods are under minetest_game directory and extra mods are under mods directory :

Code: Select all

minetest/
├── games/
│   ├── minetest_game/
│   │   └── … (minetest_game mods)
├── mods/
│   └── … (installed extra mods and modpacks)
(Its better not changing anything in minetest_game as changes could be deleted in case of update)
[ Display Modpack ] - [ Digiterms ] - [ Crater MG ] - [ LATE ]

rgh
Member
Posts: 46
Joined: Fri Oct 07, 2016 13:32

Re: Where should mods go?

by rgh » Post

Well, in that case, I might have the same mod, possibly in different versions, in both
minetest/mods and a game specific mod directory.

Is the game specific version always loaded in preference over the other?

User avatar
Krock
Developer
Posts: 4650
Joined: Thu Oct 03, 2013 07:48
GitHub: SmallJoker
Location: Switzerland
Contact:

Re: Where should mods go?

by Krock » Post

rgh wrote:I might have the same mod, possibly in different versions
That will at least leave some error or warning messages in your debug.txt file, as these mods may conflict.
rgh wrote:Is the game specific version always loaded in preference over the other?
Yes, firstly there's builtin ("builtin"), subgame ("games/minetest_game"), world-only mods ("worlds/my world/worldmods/") and finally the regular mods. Almost in all use cases it's good enough to put your mods into the "mods" directory. Modifying the minetest_game content should only be considered when you've cloned the repository directly from GitHub to not lose all your changes on update.
Look, I programmed a bug for you. >> Mod Search Engine << - Mods by Krock - DuckDuckGo mod search bang: !mtmod <keyword here>

rgh
Member
Posts: 46
Joined: Fri Oct 07, 2016 13:32

Re: Where should mods go?

by rgh » Post

Thank you Krock.
Krock wrote:
rgh wrote:I might have the same mod, possibly in different versions
That will at least leave some error or warning messages in your debug.txt file, as these mods may conflict
Yes, for example, my debug.txt contains the lines:

2018-01-18 07:52:25: WARNING[Main]: Not registering alias, item with same name is already defined: mushroom:brown_natural -> flowers:mushroom_fertile_brown
2018-01-18 07:52:25: WARNING[Main]: Not registering alias, item with same name is already defined: mushroom:red_natural -> flowers:mushroom_fertile_red

and I'm wondering how to fix the problem.
Grepping the minetest directory for *.lua files containing the word 'mushroom' gives 5 files:

minetest-0.4.16-win64\games\minetest_game\mods\flowers\init.lua
minetest-0.4.16-win64\games\minetest_game\mods\flowers\mapgen.lua
minetest-0.4.16-win64\mods\hud_hunger\hunger\food.lua
minetest-0.4.16-win64\mods\mobs_animal\warthog.lua
minetest-0.4.16-win64\mods\plantlife_modpack\3dmushrooms\init.lua
Krock wrote:
rgh wrote:Is the game specific version always loaded in preference over the other?
Yes, firstly there's builtin ("builtin"), subgame ("games/minetest_game"), world-only mods ("worlds/my world/worldmods/") and finally the regular mods. Almost in all use cases it's good enough to put your mods into the "mods" directory. Modifying the minetest_game content should only be considered when you've cloned the repository directly from GitHub to not lose all your changes on update.
Could I clarify that? Are you saying that the game minetest_game has a hard-coded special status, in that its mods are available in all worlds, even in worlds created from a different game?

Post Reply

Who is online

Users browsing this forum: No registered users and 6 guests