1
0
mirror of https://github.com/Splizard/minetest-mod-snow.git synced 2024-12-28 07:30:17 +01:00

Put all the extra lua files in a src directory.

(This cleans up the folder for users, who don't want to see all those
strange files)
This commit is contained in:
Splizard 2014-06-04 11:20:57 +12:00
parent 7f9207c6ff
commit dbde0d7c93
14 changed files with 16 additions and 17 deletions

View File

@ -48,24 +48,24 @@ http://github.com/Splizard/minetest-mod-snow/
-- dofile(minetest.get_modpath("snow").."/falling_snow.lua")
-- Original init.lua File Broken into Smaller Files
dofile(minetest.get_modpath("snow").."/abms.lua")
dofile(minetest.get_modpath("snow").."/aliases.lua")
dofile(minetest.get_modpath("snow").."/basic_stairs_slabs.lua")
dofile(minetest.get_modpath("snow").."/crafting.lua")
dofile(minetest.get_modpath("snow").."/snowball.lua")
dofile(minetest.get_modpath("snow").."/src/abms.lua")
dofile(minetest.get_modpath("snow").."/src/aliases.lua")
dofile(minetest.get_modpath("snow").."/src/basic_stairs_slabs.lua")
dofile(minetest.get_modpath("snow").."/src/crafting.lua")
dofile(minetest.get_modpath("snow").."/src/snowball.lua")
-- The formspec menu didn't work when util.lua was the very first "dofile" so I moved
-- it and all the other original "dofiles", in order, to the bottom of the list. ~ LazyJ
-- Minetest would crash if the mapgen was called upon before the rest of other snow lua files so
-- I put it lower on the list and that seems to do the trick. ~ LazyJ
dofile(minetest.get_modpath("snow").."/util.lua")
dofile(minetest.get_modpath("snow").."/src/util.lua")
-- To get Xmas tree saplings, the "christmas_content", true or false, in "util.lua" has to be determined first.
-- That means "nodes.lua", where the saplings are controlled, has to come after "util.lua". ~ LazyJ
dofile(minetest.get_modpath("snow").."/nodes.lua")
dofile(minetest.get_modpath("snow").."/mapgen.lua")
dofile(minetest.get_modpath("snow").."/sled.lua")
dofile(minetest.get_modpath("snow").."/falling_snow.lua")
dofile(minetest.get_modpath("snow").."/src/nodes.lua")
dofile(minetest.get_modpath("snow").."/src/mapgen.lua")
dofile(minetest.get_modpath("snow").."/src/sled.lua")
dofile(minetest.get_modpath("snow").."/src/falling_snow.lua")
@ -73,7 +73,7 @@ dofile(minetest.get_modpath("snow").."/falling_snow.lua")
if (minetest.get_modpath("moreblocks")) then
dofile(minetest.get_modpath("snow").."/stairsplus.lua")
dofile(minetest.get_modpath("snow").."/src/stairsplus.lua")
else
end

View File

@ -3,10 +3,9 @@ If you want to run PlantLife and mods that depend on it, i.e. MoreTrees, Disable
commenting-out the lines starting with "local mgname = " through "end" (I left a note were to start
and stop) Disabling "Snow's" mapgen allows MoreTrees and PlantLife to do their thing until the
issue is figured out. However, the pine and xmas tree code is still needed for when those
saplings grow into trees.
The *starting* comment looks like this: --[[
The *closing* comment looks like this: --]]
saplings grow into trees. --]]
--The *starting* comment looks like this: --[[
--The *closing* comment looks like this: --]]
-- ~ LazyJ, 2014_05_13
@ -25,10 +24,10 @@ minetest.register_on_mapgen_init(function(MapgenParams)
end
if mgname == "v7" then
--Load mapgen_v7 compatibility.
dofile(minetest.get_modpath("snow").."/mapgen_v7.lua")
dofile(minetest.get_modpath("snow").."/src/mapgen_v7.lua")
else
--Load mapgen_v6 compatibility.
dofile(minetest.get_modpath("snow").."/mapgen_v6.lua")
dofile(minetest.get_modpath("snow").."/src/mapgen_v6.lua")
end
end)