Skip to content

Commit

Permalink
Melting and freezing
Browse files Browse the repository at this point in the history
  • Loading branch information
proller committed Jul 27, 2013
1 parent 90fde97 commit 8313321
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 9 deletions.
24 changes: 16 additions & 8 deletions mods/default/nodes.lua
Expand Up @@ -427,6 +427,7 @@ minetest.register_node("default:water_flowing", {
},
alpha = WATER_ALPHA,
paramtype = "light",
paramtype2 = "flowingliquid",
walkable = false,
pointable = false,
diggable = false,
Expand All @@ -436,8 +437,9 @@ minetest.register_node("default:water_flowing", {
liquid_alternative_flowing = "default:water_flowing",
liquid_alternative_source = "default:water_source",
liquid_viscosity = WATER_VISC,
freezemelt = "default:snow",
post_effect_color = {a=64, r=100, g=100, b=200},
groups = {water=3, liquid=3, puts_out_fire=1, not_in_creative_inventory=1},
groups = {water=3, liquid=3, puts_out_fire=1, not_in_creative_inventory=1, freezes=1, melt_around=1},
})

minetest.register_node("default:water_source", {
Expand Down Expand Up @@ -466,8 +468,9 @@ minetest.register_node("default:water_source", {
liquid_alternative_flowing = "default:water_flowing",
liquid_alternative_source = "default:water_source",
liquid_viscosity = WATER_VISC,
freezemelt = "default:ice",
post_effect_color = {a=64, r=100, g=100, b=200},
groups = {water=3, liquid=3, puts_out_fire=1},
groups = {water=3, liquid=3, puts_out_fire=1, freezes=1},
})

minetest.register_node("default:lava_flowing", {
Expand All @@ -488,6 +491,7 @@ minetest.register_node("default:lava_flowing", {
},
},
paramtype = "light",
paramtype2 = "flowingliquid",
light_source = LIGHT_MAX - 1,
walkable = false,
pointable = false,
Expand Down Expand Up @@ -558,7 +562,7 @@ minetest.register_node("default:torch", {
wall_bottom = {-0.1, -0.5, -0.1, 0.1, -0.5+0.6, 0.1},
wall_side = {-0.5, -0.3, -0.1, -0.5+0.3, 0.3, 0.1},
},
groups = {choppy=2,dig_immediate=3,flammable=1,attached_node=1},
groups = {choppy=2,dig_immediate=3,flammable=1,attached_node=1,hot=2},
legacy_wallmounted = true,
sounds = default.node_sound_defaults(),
})
Expand Down Expand Up @@ -833,7 +837,7 @@ minetest.register_node("default:furnace_active", {
paramtype2 = "facedir",
light_source = 8,
drop = "default:furnace",
groups = {cracky=2, not_in_creative_inventory=1},
groups = {cracky=2, not_in_creative_inventory=1,hot=1},
legacy_facedir_simple = true,
sounds = default.node_sound_stone_defaults(),
on_construct = function(pos)
Expand Down Expand Up @@ -1272,7 +1276,8 @@ minetest.register_node("default:ice", {
tiles = {"default_ice.png"},
is_ground_content = true,
paramtype = "light",
groups = {cracky=3},
freezemelt = "default:water_source",
groups = {cracky=3, melts=1},
sounds = default.node_sound_glass_defaults(),
})

Expand All @@ -1284,14 +1289,16 @@ minetest.register_node("default:snow", {
is_ground_content = true,
paramtype = "light",
buildable_to = true,
leveled = 1,
drawtype = "nodebox",
freezemelt = "default:water_flowing",
node_box = {
type = "fixed",
type = "leveled",
fixed = {
{-0.5, -0.5, -0.5, 0.5, -0.5+2/16, 0.5},
},
},
groups = {crumbly=3,falling_node=1},
groups = {crumbly=3,falling_node=1, melts=1, float=1},
sounds = default.node_sound_dirt_defaults({
footstep = {name="default_snow_footstep", gain=0.25},
dug = {name="default_snow_footstep", gain=0.75},
Expand All @@ -1309,7 +1316,8 @@ minetest.register_node("default:snowblock", {
description = "Snow Block",
tiles = {"default_snow.png"},
is_ground_content = true,
groups = {crumbly=3},
freezemelt = "default:water_source",
groups = {crumbly=3, melts=1},
sounds = default.node_sound_dirt_defaults({
footstep = {name="default_snow_footstep", gain=0.25},
dug = {name="default_snow_footstep", gain=0.75},
Expand Down
2 changes: 1 addition & 1 deletion mods/fire/init.lua
Expand Up @@ -9,7 +9,7 @@ minetest.register_node("fire:basic_flame", {
}},
inventory_image = "fire_basic_flame.png",
light_source = 14,
groups = {igniter=2,dig_immediate=3},
groups = {igniter=2,dig_immediate=3,hot=3},
drop = '',
walkable = false,
buildable_to = true,
Expand Down

0 comments on commit 8313321

Please sign in to comment.