More reindentation
parent
aa66df968a
commit
5bceed83bf
3
ROADMAP
3
ROADMAP
|
@ -143,6 +143,7 @@ It's really fast. May be used on a website, to show the actual map.
|
|||
**** pvp shoudld be a privillege
|
||||
- So we can revoke it to some players
|
||||
**** TODO Continue to test factions and NPC mod
|
||||
CLOCK: [2018-12-24 lun. 01:04]--[2018-12-24 lun. 01:12] => 0:08
|
||||
CLOCK: [2018-12-24 lun. 00:51]--[2018-12-24 lun. 00:52] => 0:01
|
||||
CLOCK: [2018-12-23 dim. 18:16]--[2018-12-23 dim. 18:40] => 0:24
|
||||
CLOCK: [2018-12-23 dim. 13:29]--[2018-12-23 dim. 14:37] => 1:08
|
||||
|
@ -182,6 +183,8 @@ It's really fast. May be used on a website, to show the actual map.
|
|||
How to change that
|
||||
Try to edit mts files in mods/mg_villages/schems/
|
||||
These are schematics files sued with worldedit : not really usable
|
||||
Changing it from code could be easier
|
||||
- maybe see handle_schematics/build_chest
|
||||
|
||||
- [ ] Faction chest must be for faction only (no parcel needed)
|
||||
- [ ] Try to find a protector mod, test it
|
||||
|
|
|
@ -39,8 +39,8 @@ end
|
|||
-- checks if the plot marker is still present; places a new one if needed
|
||||
-- p: plot data (position, size, orientation, owner, ..)
|
||||
mg_villages.check_plot_marker = function( p, plot_nr, village_id )
|
||||
-- roads cannot be bought
|
||||
if( p.btype and p.btype=="road" ) then
|
||||
-- roads cannot be bought
|
||||
if( p.btype and p.btype=="road" ) then
|
||||
return;
|
||||
end
|
||||
local plot_pos = { x=p.x, y=p.y, z=p.z };
|
||||
|
|
|
@ -252,77 +252,77 @@ mg_villages.replace_tree_trunk = function( replacements, wood_type )
|
|||
table.insert( replacements, {'default:bookshelf', 'decorations:bookshelf_'..v});
|
||||
table.insert( replacements, {'doors:door_wood_t_1', 'doors:door_'..v..'_t_1'});
|
||||
table.insert( replacements, {'doors:door_wood_b_1', 'doors:door_'..v..'_b_1'});
|
||||
table.insert( replacements, {'doors:door_wood_t_2', 'doors:door_'..v..'_t_2'});
|
||||
table.insert( replacements, {'doors:door_wood_b_2', 'doors:door_'..v..'_b_2'});
|
||||
-- not really wood-realted, but needs to be replaced as well
|
||||
table.insert( replacements, {'default:furnace', 'oven:oven'});
|
||||
-- farming is also handled diffrently
|
||||
table.insert( replacements, {'farming:soil_wet', 'farming:soil'});
|
||||
table.insert( replacements, {'farming:cotton_1', 'farming:flax_1'});
|
||||
table.insert( replacements, {'farming:cotton_2', 'farming:flax_1'});
|
||||
table.insert( replacements, {'farming:cotton_3', 'farming:flax_2'});
|
||||
table.insert( replacements, {'farming:cotton_4', 'farming:flax_2'});
|
||||
table.insert( replacements, {'farming:cotton_5', 'farming:flax_3'});
|
||||
table.insert( replacements, {'farming:cotton_6', 'farming:flax_3'});
|
||||
table.insert( replacements, {'farming:cotton_7', 'farming:flax_4'});
|
||||
table.insert( replacements, {'farming:cotton_8', 'farming:flax_4'});
|
||||
-- stairs and slabs made out of default wood
|
||||
table.insert( replacements, {'stairs:stair_wood', 'trees:'..v..'_planks_stair'});
|
||||
table.insert( replacements, {'stairs:slab_wood', 'trees:'..v..'_planks_slab'});
|
||||
table.insert( replacements, {'stairs:stair_woodupside_down','trees:'..v..'_planks_stair_upside_down' } );
|
||||
table.insert( replacements, {'stairs:slab_woodupside_down', 'trees:'..v..'_planks_slab_upside_down' } );
|
||||
end
|
||||
end
|
||||
else
|
||||
return nil;
|
||||
end
|
||||
return wood_type;
|
||||
-- TODO if minetest.get_modpath("moreblocks") and moretrees.enable_stairsplus the
|
||||
table.insert( replacements, {'doors:door_wood_t_2', 'doors:door_'..v..'_t_2'});
|
||||
table.insert( replacements, {'doors:door_wood_b_2', 'doors:door_'..v..'_b_2'});
|
||||
-- not really wood-realted, but needs to be replaced as well
|
||||
table.insert( replacements, {'default:furnace', 'oven:oven'});
|
||||
-- farming is also handled diffrently
|
||||
table.insert( replacements, {'farming:soil_wet', 'farming:soil'});
|
||||
table.insert( replacements, {'farming:cotton_1', 'farming:flax_1'});
|
||||
table.insert( replacements, {'farming:cotton_2', 'farming:flax_1'});
|
||||
table.insert( replacements, {'farming:cotton_3', 'farming:flax_2'});
|
||||
table.insert( replacements, {'farming:cotton_4', 'farming:flax_2'});
|
||||
table.insert( replacements, {'farming:cotton_5', 'farming:flax_3'});
|
||||
table.insert( replacements, {'farming:cotton_6', 'farming:flax_3'});
|
||||
table.insert( replacements, {'farming:cotton_7', 'farming:flax_4'});
|
||||
table.insert( replacements, {'farming:cotton_8', 'farming:flax_4'});
|
||||
-- stairs and slabs made out of default wood
|
||||
table.insert( replacements, {'stairs:stair_wood', 'trees:'..v..'_planks_stair'});
|
||||
table.insert( replacements, {'stairs:slab_wood', 'trees:'..v..'_planks_slab'});
|
||||
table.insert( replacements, {'stairs:stair_woodupside_down','trees:'..v..'_planks_stair_upside_down' } );
|
||||
table.insert( replacements, {'stairs:slab_woodupside_down', 'trees:'..v..'_planks_slab_upside_down' } );
|
||||
end
|
||||
end
|
||||
else
|
||||
return nil;
|
||||
end
|
||||
return wood_type;
|
||||
-- TODO if minetest.get_modpath("moreblocks") and moretrees.enable_stairsplus the
|
||||
end
|
||||
|
||||
|
||||
-- if buildings are made out of a certain wood type, people might expect trees of that type nearby
|
||||
mg_villages.replace_saplings = function( replacements, wood_type )
|
||||
if( wood_type == 'default:junglewood' ) then
|
||||
table.insert( replacements, {'default:sapling', 'default:junglesapling'});
|
||||
elseif( wood_type == 'default:pine_wood' ) then
|
||||
table.insert( replacements, {'default:sapling', 'default:pine_sapling'});
|
||||
elseif( wood_type == 'default:acacia_wood' ) then
|
||||
table.insert( replacements, {'default:sapling', 'default:acacia_sapling'});
|
||||
elseif( wood_type == 'default:aspen_wood' ) then
|
||||
table.insert( replacements, {'default:sapling', 'default:aspen_sapling'});
|
||||
elseif( wood_type == 'mg:savannawood' ) then
|
||||
table.insert( replacements, {'default:sapling', 'mg:savannasapling'});
|
||||
elseif( wood_type == 'mg:pinewood' ) then
|
||||
table.insert( replacements, {'default:sapling', 'mg:pinesapling'});
|
||||
elseif( mg_villages.moretrees_treelist ) then
|
||||
for _,v in ipairs( mg_villages.moretrees_treelist ) do
|
||||
if( wood_type == "moretrees:"..v[1].."_planks" ) then
|
||||
table.insert( replacements, {'default:sapling', "moretrees:"..v[1].."_sapling_ongen"});
|
||||
end
|
||||
end
|
||||
elseif( mg_villages.ethereal_trees ) then
|
||||
for _,v in ipairs( mg_villages.ethereal_trees ) do
|
||||
if( wood_type == "ethereal:"..v.."_wood" ) then
|
||||
table.insert( replacements, {'default:sapling', "ethereal:"..v.."_sapling"});
|
||||
end
|
||||
end
|
||||
|
||||
elseif( mg_villages.forest_trees ) then
|
||||
for _,v in ipairs( mg_villages.forest_trees ) do
|
||||
if( wood_type == "forest:"..v.."_wood" ) then
|
||||
table.insert( replacements, {'default:sapling', "forest:"..v.."_sapling"});
|
||||
end
|
||||
end
|
||||
|
||||
elseif( mg_villages.tinytrees_trees ) then
|
||||
for _,v in ipairs( mg_villages.tinytrees_trees ) do
|
||||
if( wood_type == "trees:wood_"..v ) then
|
||||
table.insert( replacements, {'default:sapling', "trees:sapling_"..v});
|
||||
end
|
||||
|
||||
end
|
||||
elseif( mg_villages.realtest_trees ) then
|
||||
if(wood_type == 'default:junglewood' ) then
|
||||
table.insert( replacements, {'default:sapling', 'default:junglesapling'});
|
||||
elseif( wood_type == 'default:pine_wood' ) then
|
||||
table.insert( replacements, {'default:sapling', 'default:pine_sapling'});
|
||||
elseif( wood_type == 'default:acacia_wood' ) then
|
||||
table.insert( replacements, {'default:sapling', 'default:acacia_sapling'});
|
||||
elseif( wood_type == 'default:aspen_wood' ) then
|
||||
table.insert( replacements, {'default:sapling', 'default:aspen_sapling'});
|
||||
elseif( wood_type == 'mg:savannawood' ) then
|
||||
table.insert( replacements, {'default:sapling', 'mg:savannasapling'});
|
||||
elseif( wood_type == 'mg:pinewood' ) then
|
||||
table.insert( replacements, {'default:sapling', 'mg:pinesapling'});
|
||||
elseif( mg_villages.moretrees_treelist ) then
|
||||
for _,v in ipairs( mg_villages.moretrees_treelist ) do
|
||||
if( wood_type == "moretrees:"..v[1].."_planks" ) then
|
||||
table.insert( replacements, {'default:sapling', "moretrees:"..v[1].."_sapling_ongen"});
|
||||
end
|
||||
end
|
||||
elseif( mg_villages.ethereal_trees ) then
|
||||
for _,v in ipairs( mg_villages.ethereal_trees ) do
|
||||
if( wood_type == "ethereal:"..v.."_wood" ) then
|
||||
table.insert( replacements, {'default:sapling', "ethereal:"..v.."_sapling"});
|
||||
end
|
||||
end
|
||||
|
||||
elseif( mg_villages.forest_trees ) then
|
||||
for _,v in ipairs( mg_villages.forest_trees ) do
|
||||
if( wood_type == "forest:"..v.."_wood" ) then
|
||||
table.insert( replacements, {'default:sapling', "forest:"..v.."_sapling"});
|
||||
end
|
||||
end
|
||||
|
||||
elseif( mg_villages.tinytrees_trees ) then
|
||||
for _,v in ipairs( mg_villages.tinytrees_trees ) do
|
||||
if( wood_type == "trees:wood_"..v ) then
|
||||
table.insert( replacements, {'default:sapling', "trees:sapling_"..v});
|
||||
end
|
||||
|
||||
end
|
||||
elseif( mg_villages.realtest_trees ) then
|
||||
for _,v in ipairs( mg_villages.realtest_trees ) do
|
||||
if( wood_type == 'trees:'..v..'_planks' ) then
|
||||
table.insert( replacements, {'default:sapling', "trees:"..v.."_sapling"});
|
||||
|
|
Loading…
Reference in New Issue