-- =================================================================== local reg_alias = ocutil.safe_register_alias local reg_item = ocutil.safe_register_item local reg_node = ocutil.safe_register_node local needitem local neednode -- =================================================================== neednode = "snow:cobble" -- reg_node (neednode, { description = "Icy Snow" , tiles = { "snow_cobble.png" } , is_ground_content = true, liquidtype = "none" , paramtype = "light" , sunlight_propagates = true, paramtype2 = "facedir" , -- I made this a little harder to dig than snow blocks because -- I imagine snow brick as being much more dense and solid than -- fluffy snow. ~ LazyJ groups = { cracky=2, crumbly=2, choppy=2, oddly_breakable_by_hand=2, melts=1, icemaker=1, cooks_into_ice=1 } , sounds = default.sound_dirt ({ footstep = {name="default_snow_footstep" , gain=0.25} , dig = {name="default_dig_crumbly" , gain=0.4} , dug = {name="default_snow_footstep" , gain=0.75} , place = {name="default_place_node" , gain=1.0} }), -- The "on_construct" part below, thinking in terms of layers, dirt_with_snow could also -- double as dirt_with_frost which adds subtlety to the winterscape. ~ LazyJ on_construct = function(pos) pos.y = pos.y - 1 if minetest.get_node(pos).name == "default:dirt_with_grass" or minetest.get_node(pos).name == "default:dirt" then minetest.set_node(pos, {name="default:dirt_with_snow"}) end end }) reg_alias ("snow:snow_cobble" , neednode) -- =================================================================== neednode = "snow:needles" -- reg_node (neednode, { description = "Snowy Pine Needles" , drawtype = "allfaces_optional" , visual_scale = 1.3 , tiles = { "snow_needles.png" } , waving = 1 , paramtype = "light" , groups = { snappy=3, leafdecay=5 } , sounds = default.sound_leaves() , }) reg_alias ("snow:snow_needles" , neednode) -- =================================================================== needitem = "mobs:snowball" -- if ocutil.item_missing (needitem) then reg_item (needitem, { description = "Snowball" , inventory_image = "default_snowball.png" , }) end reg_alias ("snowball:snowball", "mobs:snowball") -- =================================================================== -- End of file.