diff --git a/df_dependencies/init.lua b/df_dependencies/init.lua index b0c6b04..1f279ef 100644 --- a/df_dependencies/init.lua +++ b/df_dependencies/init.lua @@ -38,16 +38,19 @@ dofile(modpath.."/nodes.lua") dofile(modpath.."/misc.lua") dofile(modpath.."/mapgen.lua") -local mods_required = "" -local mods_sorted = {} -for mod, _ in pairs(df_dependencies.mods_required) do - table.insert(mods_sorted, mod) +local list_mods_required = function() + local mods_required = "" + local mods_sorted = {} + for mod, _ in pairs(df_dependencies.mods_required) do + table.insert(mods_sorted, mod) + end + table.sort(mods_sorted) + for _, mod in ipairs(mods_sorted) do + mods_required = mods_required .. ", " .. mod + end + minetest.debug(mods_required) end -table.sort(mods_sorted) -for _, mod in ipairs(mods_sorted) do - mods_required = mods_required .. ", " .. mod -end ---minetest.debug(mods_required) +list_mods_required() -- This mod is meant to only exist at initialization time. Other mods should make copies of anything it points to for their own use. minetest.after(1, function() df_dependencies = nil end) diff --git a/df_dependencies/mod.conf b/df_dependencies/mod.conf index 846f1af..86a5aa1 100644 --- a/df_dependencies/mod.conf +++ b/df_dependencies/mod.conf @@ -1,4 +1,4 @@ name = df_dependencies -description = A utility mod for df_caverns that gathers all dependencies on minetest_game in one place, to ease compatibility efforts with mineclone and other such games +description = A utility mod for df_caverns that gathers all dependencies on minetest_game in one place, to ease cross-compatibility efforts with Minetest Game, MineClone2 and MineClone5. depends = -optional_depends = beds, bucket, default, doors, farming, fireflies, mcl_beds, mcl_buckets, mcl_chests, mcl_compatibility, mcl_copper, mcl_core, mcl_doors, mcl_explosions, mcl_farming, mcl_fences, mcl_furnaces, mcl_init, mcl_mapgen, mcl_mobitems, mcl_ocean, mcl_potions, mcl_sounds, mcl_stairs, mcl_strongholds, mcl_tnt, mcl_torches, mcl_wool, mcl_worlds, mclx_core, mesecons, moreblocks, stairs, tnt, vessels, wool \ No newline at end of file +optional_depends = beds, bucket, default, doors, farming, fireflies, mcl_beds, mcl_buckets, mcl_chests, mcl_compatibility, mcl_copper, mcl_core, mcl_doors, mcl_explosions, mcl_farming, mcl_fences, mcl_formspec, mcl_furnaces, mcl_init, mcl_mapgen, mcl_mobitems, mcl_ocean, mcl_potions, mcl_sounds, mcl_stairs, mcl_strongholds, mcl_tnt, mcl_torches, mcl_wool, mcl_worlds, mclx_core, mesecons, moreblocks, stairs, tnt, vessels, wool \ No newline at end of file