Disable treespawning on mapgen
[minetest_hades.git] / mods / default / nodes.lua
blob6956a36134483d77c95acd19ffb4e0d69fc9d202
1 -- mods/default/nodes.lua
4 minetest.register_node("default:stone", {
5 description = "Stone",
6 tiles = {"default_stone.png"},
7 is_ground_content = true,
8 groups = {cracky=3, stone=1},
9 drop = 'default:cobble',
10 legacy_mineral = true,
11 sounds = default.node_sound_stone_defaults(),
14 minetest.register_node("default:mossystone", {
15 description = "Mossystone",
16 tiles = {"default_mossystone.png"},
17 is_ground_content = true,
18 groups = {cracky=3, stone=1},
19 drop = 'default:mossycobble',
20 legacy_mineral = true,
21 sounds = default.node_sound_stone_defaults(),
24 minetest.register_node("default:chondrit", {
25 description = "Chondrit",
26 tiles = {"default_chondrit.png"},
27 is_ground_content = true,
28 groups = {cracky=2, stone=1},
29 drop = 'default:chondrit',
30 sounds = default.node_sound_stone_defaults(),
33 minetest.register_node("default:chondrit_block", {
34 description = "Chondrit Block",
35 tiles = {"default_chondrit_block.png"},
36 is_ground_content = true,
37 groups = {cracky=2},
38 sounds = default.node_sound_stone_defaults(),
41 minetest.register_node("default:chondrit_brick", {
42 description = "Chondrit Brick",
43 tiles = {"default_chondrit_brick.png"},
44 groups = {cracky=2, stone=1},
45 sounds = default.node_sound_stone_defaults(),
48 minetest.register_node("default:tuff", {
49 description = "Tuff",
50 tiles = {"default_tuff.png"},
51 is_ground_content = true,
52 groups = {cracky=3},
53 drop = 'default:tuff',
54 sounds = default.node_sound_stone_defaults(),
57 minetest.register_node("default:tuff_block", {
58 description = "Tuff Block",
59 tiles = {"default_tuff_block.png"},
60 is_ground_content = true,
61 groups = {cracky=3},
62 sounds = default.node_sound_stone_defaults(),
65 minetest.register_node("default:tuff_brick", {
66 description = "Tuff Brick",
67 tiles = {"default_tuff_brick.png"},
68 groups = {cracky=3},
69 sounds = default.node_sound_stone_defaults(),
72 minetest.register_node("default:tuff_baked", {
73 description = "Burned Tuff",
74 tiles = {"default_tuff_baked.png"},
75 is_ground_content = true,
76 groups = {cracky=3},
77 drop = 'default:tuff_baked',
78 sounds = default.node_sound_stone_defaults(),
81 minetest.register_node("default:tuff_baked_block", {
82 description = "Burned Tuff Block",
83 tiles = {"default_tuff_baked_block.png"},
84 is_ground_content = true,
85 groups = {cracky=3},
86 sounds = default.node_sound_stone_defaults(),
89 minetest.register_node("default:tuff_baked_brick", {
90 description = "Burned Tuff Brick",
91 tiles = {"default_tuff_baked_brick.png"},
92 groups = {cracky=3},
93 sounds = default.node_sound_stone_defaults(),
96 minetest.register_node("default:mossytuff", {
97 description = "Mossytuff",
98 tiles = {"default_mossytuff.png"},
99 is_ground_content = true,
100 groups = {cracky=3},
101 drop = 'default:mossytuff',
102 legacy_mineral = true,
103 sounds = default.node_sound_stone_defaults(),
106 minetest.register_node("default:marble", {
107 description = "Marble",
108 tiles = {"default_marble.png"},
109 is_ground_content = true,
110 groups = {cracky=3, stone=1},
111 drop = 'default:marble',
112 sounds = default.node_sound_stone_defaults(),
115 minetest.register_node("default:marble_block", {
116 description = "Marble Block",
117 tiles = {"default_marble_block.png"},
118 is_ground_content = true,
119 groups = {cracky=3},
120 sounds = default.node_sound_stone_defaults(),
123 minetest.register_node("default:marble_brick", {
124 description = "Marble Brick",
125 tiles = {"default_marble_brick.png"},
126 groups = {cracky=3, stone=1},
127 sounds = default.node_sound_stone_defaults(),
130 minetest.register_node("default:essexit", {
131 description = "Essexit",
132 tiles = {"default_essexit.png"},
133 is_ground_content = true,
134 groups = {cracky=1, stone=1},
135 drop = 'default:essexit',
136 sounds = default.node_sound_stone_defaults(),
139 minetest.register_node("default:essexit_block", {
140 description = "Essexit Block",
141 tiles = {"default_essexit_block.png"},
142 is_ground_content = true,
143 groups = {cracky=2,},
144 sounds = default.node_sound_stone_defaults(),
147 minetest.register_node("default:essexit_brick", {
148 description = "Essexit Brick",
149 tiles = {"default_essexit_brick.png"},
150 groups = {cracky=1, stone=1},
151 sounds = default.node_sound_stone_defaults(),
154 minetest.register_node("default:desert_stone", {
155 description = "Burned Stone",
156 tiles = {"default_desert_stone.png"},
157 is_ground_content = true,
158 groups = {cracky=3, stone=1},
159 drop = 'default:desert_stone',
160 legacy_mineral = true,
161 sounds = default.node_sound_stone_defaults(),
164 minetest.register_node("default:desert_stone_block", {
165 description = "Burned Stone Block",
166 tiles = {"default_desert_stone_block.png"},
167 is_ground_content = true,
168 groups = {cracky=3},
169 sounds = default.node_sound_stone_defaults(),
172 minetest.register_node("default:obsidianbrick", {
173 description = "Obsidian Brick",
174 tiles = {"default_obsidian_brick.png"},
175 sounds = default.node_sound_stone_defaults(),
176 groups = {cracky=1,level=2},
178 -- floors
180 minetest.register_node("default:floor_chondrit_stone", {
181 description = "Chondrit - Stone Floor",
182 tiles = {"default_floor_chondrit_stone.png"},
183 is_ground_content = true,
184 groups = {cracky=3, stone=1},
185 drop = 'default:floor_chondrit_stone',
186 sounds = default.node_sound_stone_defaults(),
189 minetest.register_node("default:floor_chondrit_stone2", {
190 description = "Chondrit - Stone Floor 2",
191 tiles = {"default_floor_chondrit_stone2.png"},
192 is_ground_content = true,
193 groups = {cracky=3, stone=1},
194 drop = 'default:floor_chondrit_stone2',
195 sounds = default.node_sound_stone_defaults(),
198 minetest.register_node("default:floor_bstone_stone", {
199 description = "Burned Stone - Stone Floor",
200 tiles = {"default_floor_bstone_stone.png"},
201 is_ground_content = true,
202 groups = {cracky=3, stone=1},
203 drop = 'default:floor_bstone_stone',
204 sounds = default.node_sound_stone_defaults(),
207 minetest.register_node("default:floor_btuff_tuff", {
208 description = "Burned Tuff - Tuff Floor",
209 tiles = {"default_floor_btuff_tuff.png"},
210 is_ground_content = true,
211 groups = {cracky=3},
212 drop = 'default:floor_btuff_tuff',
213 sounds = default.node_sound_stone_defaults(),
216 minetest.register_node("default:floor_bstone_sandstone", {
217 description = "Burned Stone - Sandstone Floor",
218 tiles = {"default_floor_bstone_sandstone.png"},
219 is_ground_content = true,
220 groups = {cracky=3, stone=1},
221 drop = 'default:floor_bstone_sandstone',
222 sounds = default.node_sound_stone_defaults(),
225 minetest.register_node("default:floor_bstone_sandstone2", {
226 description = "Burned Stone - Sandstone Floor 2",
227 tiles = {"default_floor_bstone_sandstone2.png"},
228 is_ground_content = true,
229 groups = {cracky=3, stone=1},
230 drop = 'default:floor_bstone_sandstone2',
231 sounds = default.node_sound_stone_defaults(),
234 minetest.register_node("default:floor_marble_essexit", {
235 description = "Marble - Essexit Floor",
236 tiles = {"default_floor_marble_essexit.png"},
237 is_ground_content = true,
238 groups = {cracky=2, stone=1},
239 drop = 'default:floor_marble_essexit',
240 sounds = default.node_sound_stone_defaults(),
243 minetest.register_node("default:floor_marble_essexit2", {
244 description = "Marble - Essexit Floor 2",
245 tiles = {"default_floor_marble_essexit2.png"},
246 is_ground_content = true,
247 groups = {cracky=2, stone=1},
248 drop = 'default:floor_marble_essexit2',
249 sounds = default.node_sound_stone_defaults(),
252 minetest.register_node("default:floor_essexit_gold", {
253 description = "Essexit - Gold Floor",
254 tiles = {"default_floor_essexit_gold.png"},
255 is_ground_content = true,
256 groups = {cracky=2, stone=1},
257 drop = 'default:floor_essexit_gold',
258 sounds = default.node_sound_stone_defaults(),
261 minetest.register_node("default:floor_essexit_gold2", {
262 description = "Essexit - Gold Floor 2",
263 tiles = {"default_floor_essexit_gold2.png"},
264 is_ground_content = true,
265 groups = {cracky=2, stone=1},
266 drop = 'default:floor_essexit_gold2',
267 sounds = default.node_sound_stone_defaults(),
270 minetest.register_node("default:floor_wood_jungle", {
271 description = "Junglewood - Wood Floor",
272 tiles = {"default_floor_wood_jungle.png"},
273 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
274 sounds = default.node_sound_wood_defaults(),
277 minetest.register_node("default:floor_wood_pale", {
278 description = "Wood - Pale Floor",
279 tiles = {"default_floor_wood_pale.png"},
280 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
281 sounds = default.node_sound_wood_defaults(),
284 minetest.register_node("default:floor_pale_jungle", {
285 description = "Junglewood - Pale Floor",
286 tiles = {"default_floor_pale_jungle.png"},
287 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
288 sounds = default.node_sound_wood_defaults(),
291 --minerals
293 minetest.register_node("default:stone_with_coal", {
294 description = "Coal Ore",
295 tiles = {"default_stone.png^default_mineral_coal.png"},
296 is_ground_content = true,
297 groups = {cracky=3},
298 drop = 'default:coal_lump',
299 sounds = default.node_sound_stone_defaults(),
303 minetest.register_node("default:stone_with_iron", {
304 description = "Iron Ore",
305 tiles = {"default_stone.png^default_mineral_iron.png"},
306 is_ground_content = true,
307 groups = {cracky=2},
308 drop = 'default:iron_lump',
309 sounds = default.node_sound_stone_defaults(),
312 minetest.register_node("default:stone_with_tin", {
313 description = "Tin Ore",
314 tiles = {"default_stone.png^default_mineral_tin.png"},
315 is_ground_content = true,
316 groups = {cracky=2},
317 drop = 'default:tin_lump',
318 sounds = default.node_sound_stone_defaults(),
321 minetest.register_node("default:stone_with_copper", {
322 description = "Copper Ore",
323 tiles = {"default_stone.png^default_mineral_copper.png"},
324 is_ground_content = true,
325 groups = {cracky=2},
326 drop = 'default:copper_lump',
327 sounds = default.node_sound_stone_defaults(),
331 minetest.register_node("default:stone_with_mese", {
332 description = "Mese Ore",
333 tiles = {"default_stone.png^default_mineral_mese.png"},
334 is_ground_content = true,
335 groups = {cracky=1},
336 drop = "default:mese_crystal",
337 sounds = default.node_sound_stone_defaults(),
341 minetest.register_node("default:stone_with_gold", {
342 description = "Gold Ore",
343 tiles = {"default_stone.png^default_mineral_gold.png"},
344 is_ground_content = true,
345 groups = {cracky=2},
346 drop = "default:gold_lump",
347 sounds = default.node_sound_stone_defaults(),
351 minetest.register_node("default:stone_with_diamond", {
352 description = "Diamond Ore",
353 tiles = {"default_stone.png^default_mineral_diamond.png"},
354 is_ground_content = true,
355 groups = {cracky=1},
356 drop = "default:diamond",
357 sounds = default.node_sound_stone_defaults(),
361 minetest.register_node("default:stonebrick", {
362 description = "Stone Brick",
363 tiles = {"default_stone_brick.png"},
364 groups = {cracky=2, stone=1},
365 sounds = default.node_sound_stone_defaults(),
369 minetest.register_node("default:desert_stonebrick", {
370 description = "Burned Stone Brick",
371 tiles = {"default_desert_stone_brick.png"},
372 groups = {cracky=2, stone=1},
373 sounds = default.node_sound_stone_defaults(),
377 minetest.register_node("default:dirt_with_grass", {
378 description = "Dirt with Grass",
379 tiles = {"default_grass.png", "default_dirt.png", "default_dirt.png^default_grass_side.png"},
380 is_ground_content = true,
381 groups = {crumbly=3,soil=1},
382 drop = 'default:dirt',
383 sounds = default.node_sound_dirt_defaults({
384 footstep = {name="default_grass_footstep", gain=0.25},
389 minetest.register_node("default:dirt_with_grass_footsteps", {
390 description = "Dirt with Grass and Footsteps",
391 tiles = {"default_grass_footsteps.png", "default_dirt.png", "default_dirt.png^default_grass_side.png"},
392 is_ground_content = true,
393 groups = {crumbly=3,soil=1,not_in_creative_inventory=1},
394 drop = 'default:dirt',
395 sounds = default.node_sound_dirt_defaults({
396 footstep = {name="default_grass_footstep", gain=0.25},
401 minetest.register_node("default:dirt_with_snow", {
402 description = "Dirt with Snow",
403 tiles = {"default_snow.png", "default_dirt.png", "default_dirt.png^default_snow_side.png"},
404 is_ground_content = true,
405 groups = {crumbly=3},
406 drop = 'default:dirt',
407 sounds = default.node_sound_dirt_defaults({
408 footstep = {name="default_snow_footstep", gain=0.25},
413 minetest.register_node("default:dirt", {
414 description = "Dirt",
415 tiles = {"default_dirt.png"},
416 is_ground_content = true,
417 groups = {crumbly=3,soil=1},
418 sounds = default.node_sound_dirt_defaults(),
422 minetest.register_abm({
423 nodenames = {"default:dirt"},
424 interval = 2,
425 chance = 200,
426 action = function(pos, node)
427 local above = {x=pos.x, y=pos.y+1, z=pos.z}
428 local name = minetest.get_node(above).name
429 local nodedef = minetest.registered_nodes[name]
430 if nodedef and (nodedef.sunlight_propagates or nodedef.paramtype == "light")
431 and nodedef.liquidtype == "none"
432 and (minetest.get_node_light(above) or 0) >= 13 then
433 if name == "default:snow" or name == "default:snowblock" then
434 minetest.set_node(pos, {name = "default:dirt_with_snow"})
435 else
436 minetest.set_node(pos, {name = "default:dirt_with_grass"})
443 minetest.register_abm({
444 nodenames = {"default:dirt_with_grass"},
445 interval = 2,
446 chance = 20,
447 action = function(pos, node)
448 local above = {x=pos.x, y=pos.y+1, z=pos.z}
449 local name = minetest.get_node(above).name
450 local nodedef = minetest.registered_nodes[name]
451 if name ~= "ignore" and nodedef
452 and not ((nodedef.sunlight_propagates or nodedef.paramtype == "light")
453 and nodedef.liquidtype == "none") then
454 minetest.set_node(pos, {name = "default:dirt"})
460 minetest.register_node("default:sand", {
461 description = "Volcanic Ash",
462 tiles = {"default_sand.png"},
463 is_ground_content = true,
464 groups = {crumbly=3, falling_node=1, sand=1},
465 sounds = default.node_sound_sand_defaults(),
468 minetest.register_node("default:sand_block", {
469 description = "Volcanic Ash Block",
470 tiles = {"default_sand_block.png"},
471 is_ground_content = true,
472 groups = {crumbly=3},
473 sounds = default.node_sound_sand_defaults(),
476 minetest.register_node("default:desert_sand", {
477 description = "Fertile Sand",
478 tiles = {"default_desert_sand.png"},
479 is_ground_content = true,
480 groups = {crumbly=3, falling_node=1, sand=1},
481 sounds = default.node_sound_sand_defaults(),
485 minetest.register_node("default:gravel", {
486 description = "Gravel",
487 tiles = {"default_gravel.png"},
488 is_ground_content = true,
489 groups = {crumbly=2, falling_node=1},
490 sounds = default.node_sound_dirt_defaults({
491 footstep = {name="default_gravel_footstep", gain=0.5},
492 dug = {name="default_gravel_footstep", gain=1.0},
496 minetest.register_node("default:gravel_block", {
497 description = "Gravel Block",
498 tiles = {"default_gravel_block.png"},
499 is_ground_content = true,
500 groups = {crumbly=2},
501 sounds = default.node_sound_dirt_defaults({
502 footstep = {name="default_gravel_footstep", gain=0.5},
503 dug = {name="default_gravel_footstep", gain=1.0},
507 minetest.register_node("default:gravel_volcanic", {
508 description = "Volcanic Gravel",
509 tiles = {"default_gravel_volcanic.png"},
510 is_ground_content = true,
511 groups = {crumbly=1},
512 sounds = default.node_sound_dirt_defaults({
513 footstep = {name="default_gravel_footstep", gain=0.5},
514 dug = {name="default_gravel_footstep", gain=1.0},
518 minetest.register_node("default:gravel_volcanic_block", {
519 description = "Volcanic Gravel Block",
520 tiles = {"default_gravel_volcanic_block.png"},
521 is_ground_content = true,
522 groups = {crumbly=2},
523 sounds = default.node_sound_dirt_defaults({
524 footstep = {name="default_gravel_footstep", gain=0.5},
525 dug = {name="default_gravel_footstep", gain=1.0},
530 minetest.register_node("default:sandstone", {
531 description = "Sandstone",
532 tiles = {"default_sandstone.png"},
533 is_ground_content = true,
534 groups = {crumbly=2,cracky=3},
535 sounds = default.node_sound_stone_defaults(),
539 minetest.register_node("default:sandstonebrick", {
540 description = "Sandstone Brick",
541 tiles = {"default_sandstone_brick.png"},
542 is_ground_content = true,
543 groups = {cracky=2},
544 sounds = default.node_sound_stone_defaults(),
548 minetest.register_node("default:clay", {
549 description = "Clay",
550 tiles = {"default_clay.png"},
551 is_ground_content = true,
552 groups = {crumbly=3},
553 drop = 'default:clay_lump 4',
554 sounds = default.node_sound_dirt_defaults(),
558 minetest.register_node("default:brick", {
559 description = "Brick Block (uncolored)",
560 tiles = {"default_brick.png"},
561 is_ground_content = false,
562 groups = {cracky=3, claybricks=1},
563 sounds = default.node_sound_stone_defaults(),
566 -- Colors are beautiful
568 minetest.register_node("default:brick_black", {
569 description = "Black Brick Block",
570 tiles = {"default_brick_black.png"},
571 is_ground_content = false,
572 groups = {cracky=3, claybricks=1},
573 sounds = default.node_sound_stone_defaults(),
576 minetest.register_node("default:brick_blue", {
577 description = "Blue Brick Block",
578 tiles = {"default_brick_blue.png"},
579 is_ground_content = false,
580 groups = {cracky=3, claybricks=1},
581 sounds = default.node_sound_stone_defaults(),
584 minetest.register_node("default:brick_brown", {
585 description = "Brown Brick Block",
586 tiles = {"default_brick_brown.png"},
587 is_ground_content = false,
588 groups = {cracky=3, claybricks=1},
589 sounds = default.node_sound_stone_defaults(),
592 minetest.register_node("default:brick_cyan", {
593 description = "Cyan Brick Block",
594 tiles = {"default_brick_cyan.png"},
595 is_ground_content = false,
596 groups = {cracky=3, claybricks=1},
597 sounds = default.node_sound_stone_defaults(),
600 minetest.register_node("default:brick_dark_green", {
601 description = "Darkgreen Brick Block",
602 tiles = {"default_brick_dark_green.png"},
603 is_ground_content = false,
604 groups = {cracky=3, claybricks=1},
605 sounds = default.node_sound_stone_defaults(),
608 minetest.register_node("default:brick_dark_grey", {
609 description = "Darkgrey Brick Block",
610 tiles = {"default_brick_dark_grey.png"},
611 is_ground_content = false,
612 groups = {cracky=3, claybricks=1},
613 sounds = default.node_sound_stone_defaults(),
616 minetest.register_node("default:brick_green", {
617 description = "Green Brick Block",
618 tiles = {"default_brick_green.png"},
619 is_ground_content = false,
620 groups = {cracky=3, claybricks=1},
621 sounds = default.node_sound_stone_defaults(),
624 minetest.register_node("default:brick_grey", {
625 description = "Grey Brick Block",
626 tiles = {"default_brick_grey.png"},
627 is_ground_content = false,
628 groups = {cracky=3, claybricks=1},
629 sounds = default.node_sound_stone_defaults(),
632 minetest.register_node("default:brick_magenta", {
633 description = "Magenta Brick Block",
634 tiles = {"default_brick_magenta.png"},
635 is_ground_content = false,
636 groups = {cracky=3, claybricks=1},
637 sounds = default.node_sound_stone_defaults(),
640 minetest.register_node("default:brick_orange", {
641 description = "Orange Brick Block",
642 tiles = {"default_brick_orange.png"},
643 is_ground_content = false,
644 groups = {cracky=3, claybricks=1},
645 sounds = default.node_sound_stone_defaults(),
648 minetest.register_node("default:brick_pink", {
649 description = "Pink Brick Block",
650 tiles = {"default_brick_pink.png"},
651 is_ground_content = false,
652 groups = {cracky=3, claybricks=1},
653 sounds = default.node_sound_stone_defaults(),
656 minetest.register_node("default:brick_red", {
657 description = "Red Brick Block",
658 tiles = {"default_brick_red.png"},
659 is_ground_content = false,
660 groups = {cracky=3, claybricks=1},
661 sounds = default.node_sound_stone_defaults(),
664 minetest.register_node("default:brick_violet", {
665 description = "Violet Brick Block",
666 tiles = {"default_brick_violet.png"},
667 is_ground_content = false,
668 groups = {cracky=3, claybricks=1},
669 sounds = default.node_sound_stone_defaults(),
672 minetest.register_node("default:brick_white", {
673 description = "White Brick Block",
674 tiles = {"default_brick_white.png"},
675 is_ground_content = false,
676 groups = {cracky=3, claybricks=1},
677 sounds = default.node_sound_stone_defaults(),
680 minetest.register_node("default:brick_yellow", {
681 description = "Yellow Brick Block",
682 tiles = {"default_brick_yellow.png"},
683 is_ground_content = false,
684 groups = {cracky=3, claybricks=1},
685 sounds = default.node_sound_stone_defaults(),
688 minetest.register_node("default:tree", {
689 description = "Tree",
690 tiles = {"default_tree_top.png", "default_tree_top.png", "default_tree.png"},
691 paramtype2 = "facedir",
692 is_ground_content = false,
693 groups = {tree=1,choppy=2,oddly_breakable_by_hand=1,flammable=2},
694 sounds = default.node_sound_wood_defaults(),
695 on_place = minetest.rotate_node
698 minetest.register_node("default:paletree",
699 {description = "Pale Tree",
700 paramtype = "light",
701 tiles = {"default_paletree_top.png", "default_paletree_top.png", "default_paletree.png"},
702 is_ground_content = false,
703 drawtype = "nodebox",
704 node_box = {
705 type = "fixed",
706 fixed = {
707 {-0.35,-0.5,-0.4,0.35,0.5,0.4},
708 {-0.4,-0.5,-0.35, 0.4,0.5,0.35},
709 {-0.25,-0.5,-0.45,0.25,0.5,0.45},
710 {-0.45,-0.5,-0.25, 0.45,0.5,0.25},
711 {-0.15,-0.5,-0.5,0.15,0.5,0.5},
712 {-0.5,-0.5,-0.15, 0.5,0.5,0.15},
715 groups = {tree = 1, snappy = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2},
716 sounds = default.node_sound_wood_defaults(),
719 minetest.register_node("default:tree_birch",
720 {description = "Birch Tree",
721 paramtype = "light",
722 tiles = {"default_tree_birch_top.png", "default_tree_birch_top.png", "default_tree_birch.png"},
723 is_ground_content = false,
724 drawtype = "nodebox",
725 node_box = {
726 type = "fixed",
727 fixed = {
728 {-0.35,-0.5,-0.4,0.35,0.5,0.4},
729 {-0.4,-0.5,-0.35, 0.4,0.5,0.35},
730 {-0.25,-0.5,-0.45,0.25,0.5,0.45},
731 {-0.45,-0.5,-0.25, 0.45,0.5,0.25},
732 {-0.15,-0.5,-0.5,0.15,0.5,0.5},
733 {-0.5,-0.5,-0.15, 0.5,0.5,0.15},
736 groups = {tree = 1, snappy = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2},
737 sounds = default.node_sound_wood_defaults(),
741 minetest.register_node("default:jungletree", {
742 description = "Jungle Tree",
743 paramtype = "light",
744 tiles = {"default_jungletree_top.png", "default_jungletree_top.png", "default_jungletree.png"},
745 is_ground_content = false,
746 drawtype = "nodebox",
747 node_box = {
748 type = "fixed",
749 fixed = {
750 {-0.35,-0.5,-0.4,0.35,0.5,0.4},
751 {-0.4,-0.5,-0.35, 0.4,0.5,0.35},
752 {-0.25,-0.5,-0.45,0.25,0.5,0.45},
753 {-0.45,-0.5,-0.25, 0.45,0.5,0.25},
754 {-0.15,-0.5,-0.5,0.15,0.5,0.5},
755 {-0.5,-0.5,-0.15, 0.5,0.5,0.15},
758 groups = {tree=1,choppy=2,oddly_breakable_by_hand=1,flammable=2},
759 sounds = default.node_sound_wood_defaults(),
760 on_place = minetest.rotate_node
764 minetest.register_node("default:junglewood", {
765 description = "Junglewood Planks",
766 tiles = {"default_junglewood.png"},
767 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
768 sounds = default.node_sound_wood_defaults(),
772 minetest.register_node("default:jungleleaves", {
773 description = "Jungle Leaves",
774 drawtype = "allfaces_optional",
775 visual_scale = 1.3,
776 tiles = {"default_jungleleaves.png"},
777 paramtype = "light",
778 waving = 1,
779 is_ground_content = false,
780 groups = {snappy=3, leafdecay=3, flammable=2, leaves=1},
781 drop = {
782 max_items = 1,
783 items = {
785 -- player will get sapling with 1/20 chance
786 items = {'default:junglesapling'},
787 rarity = 25,
790 -- player will get leaves only if he get no saplings,
791 -- this is because max_items is 1
792 items = {'default:jungleleaves'},
796 sounds = default.node_sound_leaves_defaults(),
800 minetest.register_node("default:junglesapling", {
801 description = "Simple Jungletree Sapling",
802 drawtype = "plantlike",
803 visual_scale = 1.0,
804 tiles = {"default_junglesapling.png"},
805 inventory_image = "default_junglesapling.png",
806 wield_image = "default_junglesapling.png",
807 paramtype = "light",
808 walkable = false,
809 selection_box = {
810 type = "fixed",
811 fixed = {-0.3, -0.5, -0.3, 0.3, 0.35, 0.3}
813 groups = {snappy=2,dig_immediate=3,flammable=2,attached_node=1, sapling=1},
814 sounds = default.node_sound_leaves_defaults(),
818 minetest.register_node("default:junglegrass", {
819 description = "Jungle Grass",
820 drawtype = "plantlike",
821 visual_scale = 1.3,
822 tiles = {"default_junglegrass.png"},
823 inventory_image = "default_junglegrass.png",
824 wield_image = "default_junglegrass.png",
825 paramtype = "light",
826 walkable = false,
827 buildable_to = true,
828 is_ground_content = true,
829 groups = {snappy=3,flammable=2,flora=1,attached_node=1},
830 sounds = default.node_sound_leaves_defaults(),
831 selection_box = {
832 type = "fixed",
833 fixed = {-0.5, -0.5, -0.5, 0.5, -5/16, 0.5},
838 minetest.register_node("default:leaves", {
839 description = "Leaves",
840 drawtype = "allfaces_optional",
841 visual_scale = 1.3,
842 tiles = {"default_leaves.png"},
843 paramtype = "light",
844 waving = 1,
845 is_ground_content = false,
846 groups = {snappy=3, leafdecay=3, flammable=2, leaves=1},
847 drop = {
848 max_items = 1,
849 items = {
851 -- player will get sapling with 1/20 chance
852 items = {'default:sapling'},
853 rarity = 20,
856 -- player will get leaves only if he get no saplings,
857 -- this is because max_items is 1
858 items = {'default:leaves'},
862 sounds = default.node_sound_leaves_defaults(),
866 minetest.register_node("default:cactus", {
867 description = "Cactus",
868 tiles = {"default_cactus_top.png", "default_cactus_top.png", "default_cactus_side.png"},
869 paramtype = "light",
870 paramtype2 = "facedir",
871 is_ground_content = true,
872 drawtype = "nodebox",
873 node_box = {
874 type = "fixed",
875 fixed = {
876 {-0.35,-0.5,-0.4,0.35,0.5,0.4},
877 {-0.4,-0.5,-0.35, 0.4,0.5,0.35},
878 {-0.25,-0.5,-0.45,0.25,0.5,0.45},
879 {-0.45,-0.5,-0.25, 0.45,0.5,0.25},
880 {-0.15,-0.5,-0.5,0.15,0.5,0.5},
881 {-0.5,-0.5,-0.15, 0.5,0.5,0.15},
884 groups = {snappy=1,choppy=3,flammable=2},
885 sounds = default.node_sound_wood_defaults(),
886 on_place = minetest.rotate_node
890 minetest.register_node("default:cactus_block", {
891 description = "Cactus Block",
892 tiles = {"default_cactus_block.png"},
893 is_ground_content = true,
894 light_source = 5,
895 groups = {snappy=1,choppy=3,flammable=2},
896 sounds = default.node_sound_stone_defaults(),
899 minetest.register_node("default:cactus_brick", {
900 description = "Cactus Brick",
901 tiles = {"default_cactus_brick.png"},
902 is_ground_content = true,
903 light_source = 5,
904 groups = {snappy=1,choppy=3,flammable=2},
905 sounds = default.node_sound_stone_defaults(),
908 minetest.register_node("default:sugarcane", {
909 description = "Sugarcane",
910 drawtype = "plantlike",
911 tiles = {"default_sugarcane.png"},
912 inventory_image = "default_sugarcane.png",
913 wield_image = "default_sugarcane.png",
914 paramtype = "light",
915 walkable = false,
916 is_ground_content = true,
917 selection_box = {
918 type = "fixed",
919 fixed = {-0.3, -0.5, -0.3, 0.3, 0.5, 0.3}
921 groups = {snappy=3,flammable=2},
922 sounds = default.node_sound_leaves_defaults(),
924 after_dig_node = function(pos, node, metadata, digger)
925 default.dig_up(pos, node, digger)
926 end,
929 minetest.register_node("default:papyrus", {
930 description = "Papyrus",
931 drawtype = "plantlike",
932 tiles = {"default_papyrus.png"},
933 inventory_image = "default_papyrus.png",
934 wield_image = "default_papyrus.png",
935 paramtype = "light",
936 walkable = false,
937 is_ground_content = true,
938 selection_box = {
939 type = "fixed",
940 fixed = {-0.3, -0.5, -0.3, 0.3, 0.5, 0.3}
942 groups = {snappy=3,flammable=2},
943 sounds = default.node_sound_leaves_defaults(),
945 after_dig_node = function(pos, node, metadata, digger)
946 default.dig_up(pos, node, digger)
947 end,
951 minetest.register_node("default:bookshelf", {
952 description = "Bookshelf",
953 tiles = {"default_wood.png", "default_wood.png", "default_bookshelf.png"},
954 is_ground_content = false,
955 groups = {choppy=3,oddly_breakable_by_hand=2,flammable=3},
956 sounds = default.node_sound_wood_defaults(),
960 minetest.register_node("default:glass", {
961 description = "Glass",
962 drawtype = "glasslike",
963 tiles = {"default_glass.png"},
964 inventory_image = minetest.inventorycube("default_glass.png"),
965 paramtype = "light",
966 sunlight_propagates = true,
967 is_ground_content = false,
968 groups = {cracky=3,oddly_breakable_by_hand=3},
969 sounds = default.node_sound_glass_defaults(),
972 minetest.register_node("default:fence_rusty", {
973 description = "Rusty Fence",
974 drawtype = "fencelike",
975 tiles = {"default_rusty.png"},
976 inventory_image = "default_fence_rusty.png",
977 wield_image = "default_fence_rusty.png",
978 paramtype = "light",
979 is_ground_content = false,
980 selection_box = {
981 type = "fixed",
982 fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7},
984 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=2, woodfence=1},
985 sounds = default.node_sound_stone_defaults(),
988 -- rusty fence
990 minetest.register_node("default:fence_wood", {
991 description = "Wooden Fence",
992 drawtype = "fencelike",
993 tiles = {"default_wood.png"},
994 inventory_image = "default_fence.png",
995 wield_image = "default_fence.png",
996 paramtype = "light",
997 is_ground_content = false,
998 selection_box = {
999 type = "fixed",
1000 fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7},
1002 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=2, woodfence=1},
1003 sounds = default.node_sound_wood_defaults(),
1006 -- colored Fences
1008 minetest.register_node("default:fence_wood_black", {
1009 description = "Black Wooden Fence",
1010 drawtype = "fencelike",
1011 tiles = {"default_colwood_black.png"},
1012 inventory_image = "default_fence_black.png",
1013 wield_image = "default_fence_black.png",
1014 paramtype = "light",
1015 is_ground_content = false,
1016 selection_box = {
1017 type = "fixed",
1018 fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7},
1020 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=2, woodfence=1},
1021 sounds = default.node_sound_wood_defaults(),
1024 minetest.register_node("default:fence_wood_blue", {
1025 description = "Blue Wooden Fence",
1026 drawtype = "fencelike",
1027 tiles = {"default_colwood_blue.png"},
1028 inventory_image = "default_fence_blue.png",
1029 wield_image = "default_fence_blue.png",
1030 paramtype = "light",
1031 is_ground_content = false,
1032 selection_box = {
1033 type = "fixed",
1034 fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7},
1036 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=2, woodfence=1},
1037 sounds = default.node_sound_wood_defaults(),
1040 minetest.register_node("default:fence_wood_brown", {
1041 description = "Brown Wooden Fence",
1042 drawtype = "fencelike",
1043 tiles = {"default_colwood_brown.png"},
1044 inventory_image = "default_fence_brown.png",
1045 wield_image = "default_fence_brown.png",
1046 paramtype = "light",
1047 is_ground_content = false,
1048 selection_box = {
1049 type = "fixed",
1050 fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7},
1052 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=2, woodfence=1},
1053 sounds = default.node_sound_wood_defaults(),
1056 minetest.register_node("default:fence_wood_cyan", {
1057 description = "Cyan Wooden Fence",
1058 drawtype = "fencelike",
1059 tiles = {"default_colwood_cyan.png"},
1060 inventory_image = "default_fence_cyan.png",
1061 wield_image = "default_fence_cyan.png",
1062 paramtype = "light",
1063 is_ground_content = false,
1064 selection_box = {
1065 type = "fixed",
1066 fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7},
1068 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=2, woodfence=1},
1069 sounds = default.node_sound_wood_defaults(),
1072 minetest.register_node("default:fence_wood_dark_green", {
1073 description = "Darkgreen Wooden Fence",
1074 drawtype = "fencelike",
1075 tiles = {"default_colwood_dark_green.png"},
1076 inventory_image = "default_fence_dark_green.png",
1077 wield_image = "default_fence_dark_green.png",
1078 paramtype = "light",
1079 is_ground_content = false,
1080 selection_box = {
1081 type = "fixed",
1082 fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7},
1084 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=2, woodfence=1},
1085 sounds = default.node_sound_wood_defaults(),
1088 minetest.register_node("default:fence_wood_dark_grey", {
1089 description = "Darkgrey Wooden Fence",
1090 drawtype = "fencelike",
1091 tiles = {"default_colwood_dark_grey.png"},
1092 inventory_image = "default_fence_dark_grey.png",
1093 wield_image = "default_fence_dark_grey.png",
1094 paramtype = "light",
1095 is_ground_content = false,
1096 selection_box = {
1097 type = "fixed",
1098 fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7},
1100 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=2, woodfence=1},
1101 sounds = default.node_sound_wood_defaults(),
1104 minetest.register_node("default:fence_wood_green", {
1105 description = "Green Wooden Fence",
1106 drawtype = "fencelike",
1107 tiles = {"default_colwood_green.png"},
1108 inventory_image = "default_fence_green.png",
1109 wield_image = "default_fence_green.png",
1110 paramtype = "light",
1111 is_ground_content = false,
1112 selection_box = {
1113 type = "fixed",
1114 fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7},
1116 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=2, woodfence=1},
1117 sounds = default.node_sound_wood_defaults(),
1120 minetest.register_node("default:fence_wood_grey", {
1121 description = "Grey Wooden Fence",
1122 drawtype = "fencelike",
1123 tiles = {"default_colwood_grey.png"},
1124 inventory_image = "default_fence_grey.png",
1125 wield_image = "default_fence_grey.png",
1126 paramtype = "light",
1127 is_ground_content = false,
1128 selection_box = {
1129 type = "fixed",
1130 fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7},
1132 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=2, woodfence=1},
1133 sounds = default.node_sound_wood_defaults(),
1136 minetest.register_node("default:fence_wood_magenta", {
1137 description = "Magenta Wooden Fence",
1138 drawtype = "fencelike",
1139 tiles = {"default_colwood_magenta.png"},
1140 inventory_image = "default_fence_magenta.png",
1141 wield_image = "default_fence_magenta.png",
1142 paramtype = "light",
1143 is_ground_content = false,
1144 selection_box = {
1145 type = "fixed",
1146 fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7},
1148 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=2, woodfence=1},
1149 sounds = default.node_sound_wood_defaults(),
1152 minetest.register_node("default:fence_wood_orange", {
1153 description = "Orange Wooden Fence",
1154 drawtype = "fencelike",
1155 tiles = {"default_colwood_orange.png"},
1156 inventory_image = "default_fence_orange.png",
1157 wield_image = "default_fence_orange.png",
1158 paramtype = "light",
1159 is_ground_content = false,
1160 selection_box = {
1161 type = "fixed",
1162 fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7},
1164 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=2, woodfence=1},
1165 sounds = default.node_sound_wood_defaults(),
1168 minetest.register_node("default:fence_wood_pink", {
1169 description = "Pink Wooden Fence",
1170 drawtype = "fencelike",
1171 tiles = {"default_colwood_pink.png"},
1172 inventory_image = "default_fence_pink.png",
1173 wield_image = "default_fence_pink.png",
1174 paramtype = "light",
1175 is_ground_content = false,
1176 selection_box = {
1177 type = "fixed",
1178 fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7},
1180 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=2, woodfence=1},
1181 sounds = default.node_sound_wood_defaults(),
1184 minetest.register_node("default:fence_wood_red", {
1185 description = "Red Wooden Fence",
1186 drawtype = "fencelike",
1187 tiles = {"default_colwood_red.png"},
1188 inventory_image = "default_fence_red.png",
1189 wield_image = "default_fence_red.png",
1190 paramtype = "light",
1191 is_ground_content = false,
1192 selection_box = {
1193 type = "fixed",
1194 fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7},
1196 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=2, woodfence=1},
1197 sounds = default.node_sound_wood_defaults(),
1200 minetest.register_node("default:fence_wood_violet", {
1201 description = "Violet Wooden Fence",
1202 drawtype = "fencelike",
1203 tiles = {"default_colwood_violet.png"},
1204 inventory_image = "default_fence_violet.png",
1205 wield_image = "default_fence_violet.png",
1206 paramtype = "light",
1207 is_ground_content = false,
1208 selection_box = {
1209 type = "fixed",
1210 fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7},
1212 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=2, woodfence=1},
1213 sounds = default.node_sound_wood_defaults(),
1216 minetest.register_node("default:fence_wood_white", {
1217 description = "White Wooden Fence",
1218 drawtype = "fencelike",
1219 tiles = {"default_colwood_white.png"},
1220 inventory_image = "default_fence_white.png",
1221 wield_image = "default_fence_white.png",
1222 paramtype = "light",
1223 is_ground_content = false,
1224 selection_box = {
1225 type = "fixed",
1226 fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7},
1228 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=2, woodfence=1},
1229 sounds = default.node_sound_wood_defaults(),
1232 minetest.register_node("default:fence_wood_yellow", {
1233 description = "Yellow Wooden Fence",
1234 drawtype = "fencelike",
1235 tiles = {"default_colwood_yellow.png"},
1236 inventory_image = "default_fence_yellow.png",
1237 wield_image = "default_fence_yellow.png",
1238 paramtype = "light",
1239 is_ground_content = false,
1240 selection_box = {
1241 type = "fixed",
1242 fixed = {-1/7, -1/2, -1/7, 1/7, 1/2, 1/7},
1244 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=2, woodfence=1},
1245 sounds = default.node_sound_wood_defaults(),
1248 minetest.register_node("default:rail", {
1249 description = "Rail",
1250 drawtype = "raillike",
1251 tiles = {"default_rail.png", "default_rail_curved.png", "default_rail_t_junction.png", "default_rail_crossing.png"},
1252 inventory_image = "default_rail.png",
1253 wield_image = "default_rail.png",
1254 paramtype = "light",
1255 walkable = false,
1256 is_ground_content = false,
1257 selection_box = {
1258 type = "fixed",
1259 -- but how to specify the dimensions for curved and sideways rails?
1260 fixed = {-1/2, -1/2, -1/2, 1/2, -1/2+1/16, 1/2},
1262 groups = {bendy=2,dig_immediate=2,attached_node=1},
1266 minetest.register_node("default:ladder", {
1267 description = "Ladder",
1268 drawtype = "signlike",
1269 tiles = {"default_ladder.png"},
1270 inventory_image = "default_ladder.png",
1271 wield_image = "default_ladder.png",
1272 paramtype = "light",
1273 paramtype2 = "wallmounted",
1274 walkable = false,
1275 climbable = true,
1276 is_ground_content = false,
1277 selection_box = {
1278 type = "wallmounted",
1279 --wall_top = = <default>
1280 --wall_bottom = = <default>
1281 --wall_side = = <default>
1283 groups = {choppy=2,oddly_breakable_by_hand=3,flammable=2},
1284 legacy_wallmounted = true,
1285 sounds = default.node_sound_wood_defaults(),
1288 minetest.register_node("default:ladder_bronze", {
1289 description = "Bronze Ladder",
1290 drawtype = "signlike",
1291 tiles = {"default_ladder_bronze.png"},
1292 inventory_image = "default_ladder_bronze.png",
1293 wield_image = "default_ladder_bronze.png",
1294 paramtype = "light",
1295 paramtype2 = "wallmounted",
1296 walkable = false,
1297 climbable = true,
1298 is_ground_content = false,
1299 selection_box = {
1300 type = "wallmounted",
1301 --wall_top = = <default>
1302 --wall_bottom = = <default>
1303 --wall_side = = <default>
1305 groups = {choppy=2,oddly_breakable_by_hand=3},
1306 legacy_wallmounted = true,
1307 sounds = default.node_sound_stone_defaults(),
1311 minetest.register_node("default:wood", {
1312 description = "Wooden Planks",
1313 tiles = {"default_wood.png"},
1314 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
1315 sounds = default.node_sound_wood_defaults(),
1318 minetest.register_node("default:palewood", {
1319 description = "Pale Wooden Planks",
1320 tiles = {"default_palewood.png"},
1321 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
1322 sounds = default.node_sound_wood_defaults(),
1325 -- colored wood
1327 minetest.register_node("default:colwood_black", {
1328 description = "Black Wooden Planks",
1329 tiles = {"default_colwood_black.png"},
1330 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
1331 sounds = default.node_sound_wood_defaults(),
1334 minetest.register_node("default:colwood_blue", {
1335 description = "Blue Wooden Planks",
1336 tiles = {"default_colwood_blue.png"},
1337 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
1338 sounds = default.node_sound_wood_defaults(),
1341 minetest.register_node("default:colwood_brown", {
1342 description = "Brown Wooden Planks",
1343 tiles = {"default_colwood_brown.png"},
1344 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
1345 sounds = default.node_sound_wood_defaults(),
1348 minetest.register_node("default:colwood_cyan", {
1349 description = "Cyan Wooden Planks",
1350 tiles = {"default_colwood_cyan.png"},
1351 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
1352 sounds = default.node_sound_wood_defaults(),
1355 minetest.register_node("default:colwood_dark_green", {
1356 description = "Darkgreen Wooden Planks",
1357 tiles = {"default_colwood_dark_green.png"},
1358 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
1359 sounds = default.node_sound_wood_defaults(),
1362 minetest.register_node("default:colwood_dark_grey", {
1363 description = "Darkgrey Wooden Planks",
1364 tiles = {"default_colwood_dark_grey.png"},
1365 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
1366 sounds = default.node_sound_wood_defaults(),
1369 minetest.register_node("default:colwood_green", {
1370 description = "Green Wooden Planks",
1371 tiles = {"default_colwood_green.png"},
1372 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
1373 sounds = default.node_sound_wood_defaults(),
1376 minetest.register_node("default:colwood_grey", {
1377 description = "Grey Wooden Planks",
1378 tiles = {"default_colwood_grey.png"},
1379 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
1380 sounds = default.node_sound_wood_defaults(),
1383 minetest.register_node("default:colwood_magenta", {
1384 description = "Magenta Wooden Planks",
1385 tiles = {"default_colwood_magenta.png"},
1386 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
1387 sounds = default.node_sound_wood_defaults(),
1390 minetest.register_node("default:colwood_orange", {
1391 description = "Orange Wooden Planks",
1392 tiles = {"default_colwood_orange.png"},
1393 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
1394 sounds = default.node_sound_wood_defaults(),
1397 minetest.register_node("default:colwood_pink", {
1398 description = "Pink Wooden Planks",
1399 tiles = {"default_colwood_pink.png"},
1400 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
1401 sounds = default.node_sound_wood_defaults(),
1404 minetest.register_node("default:colwood_red", {
1405 description = "Red Wooden Planks",
1406 tiles = {"default_colwood_red.png"},
1407 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
1408 sounds = default.node_sound_wood_defaults(),
1411 minetest.register_node("default:colwood_violet", {
1412 description = "Violet Wooden Planks",
1413 tiles = {"default_colwood_violet.png"},
1414 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
1415 sounds = default.node_sound_wood_defaults(),
1418 minetest.register_node("default:colwood_white", {
1419 description = "White Wooden Planks",
1420 tiles = {"default_colwood_white.png"},
1421 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
1422 sounds = default.node_sound_wood_defaults(),
1425 minetest.register_node("default:colwood_yellow", {
1426 description = "Yellow Wooden Planks",
1427 tiles = {"default_colwood_yellow.png"},
1428 groups = {choppy=2,oddly_breakable_by_hand=2,flammable=3,wood=1},
1429 sounds = default.node_sound_wood_defaults(),
1435 minetest.register_node("default:cloud", {
1436 description = "Cloud",
1437 tiles = {"default_cloud.png"},
1438 sounds = default.node_sound_defaults(),
1439 groups = {not_in_creative_inventory=1},
1443 minetest.register_node("default:water_flowing", {
1444 description = "Flowing Water",
1445 inventory_image = minetest.inventorycube("default_water.png"),
1446 drawtype = "flowingliquid",
1447 tiles = {"default_water.png"},
1448 special_tiles = {
1450 image="default_water_flowing_animated.png",
1451 backface_culling=false,
1452 animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=0.8}
1455 image="default_water_flowing_animated.png",
1456 backface_culling=true,
1457 animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=0.8}
1460 alpha = WATER_ALPHA,
1461 paramtype = "light",
1462 paramtype2 = "flowingliquid",
1463 walkable = false,
1464 pointable = false,
1465 diggable = false,
1466 buildable_to = true,
1467 drop = "",
1468 drowning = 1,
1469 liquidtype = "flowing",
1470 liquid_alternative_flowing = "default:water_flowing",
1471 liquid_alternative_source = "default:water_source",
1472 liquid_viscosity = WATER_VISC,
1473 freezemelt = "default:snow",
1474 post_effect_color = {a=64, r=100, g=100, b=200},
1475 groups = {water=3, liquid=3, puts_out_fire=1, not_in_creative_inventory=1, freezes=1, melt_around=1},
1479 minetest.register_node("default:water_source", {
1480 description = "Water Source",
1481 inventory_image = minetest.inventorycube("default_water.png"),
1482 drawtype = "liquid",
1483 tiles = {
1484 {name="default_water_source_animated.png", animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=2.0}}
1486 special_tiles = {
1487 -- New-style water source material (mostly unused)
1489 name="default_water_source_animated.png",
1490 animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=2.0},
1491 backface_culling = false,
1494 alpha = WATER_ALPHA,
1495 paramtype = "light",
1496 walkable = false,
1497 pointable = false,
1498 diggable = false,
1499 buildable_to = true,
1500 drop = "",
1501 drowning = 1,
1502 liquidtype = "source",
1503 liquid_alternative_flowing = "default:water_flowing",
1504 liquid_alternative_source = "default:water_source",
1505 liquid_viscosity = WATER_VISC,
1506 freezemelt = "default:ice",
1507 post_effect_color = {a=64, r=100, g=100, b=200},
1508 groups = {water=3, liquid=3, puts_out_fire=1, freezes=1},
1512 minetest.register_node("default:lava_flowing", {
1513 description = "Flowing Lava",
1514 inventory_image = minetest.inventorycube("default_lava.png"),
1515 drawtype = "flowingliquid",
1516 tiles = {"default_lava.png"},
1517 special_tiles = {
1519 image="default_lava_flowing_animated.png",
1520 backface_culling=false,
1521 animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=3.3}
1524 image="default_lava_flowing_animated.png",
1525 backface_culling=true,
1526 animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=3.3}
1529 paramtype = "light",
1530 paramtype2 = "flowingliquid",
1531 light_source = LIGHT_MAX - 1,
1532 walkable = false,
1533 pointable = false,
1534 diggable = false,
1535 buildable_to = true,
1536 drop = "",
1537 drowning = 1,
1538 liquidtype = "flowing",
1539 liquid_alternative_flowing = "default:lava_flowing",
1540 liquid_alternative_source = "default:lava_source",
1541 liquid_viscosity = LAVA_VISC,
1542 liquid_renewable = false,
1543 damage_per_second = 2*2,
1544 post_effect_color = {a=192, r=255, g=64, b=0},
1545 groups = {lava=3, liquid=2, hot=3, igniter=1, not_in_creative_inventory=1},
1549 minetest.register_node("default:lava_source", {
1550 description = "Lava Source",
1551 inventory_image = minetest.inventorycube("default_lava.png"),
1552 drawtype = "liquid",
1553 tiles = {
1554 {name="default_lava_source_animated.png", animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=3.0}}
1556 special_tiles = {
1557 -- New-style lava source material (mostly unused)
1559 name="default_lava_source_animated.png",
1560 animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=3.0},
1561 backface_culling = false,
1564 paramtype = "light",
1565 light_source = LIGHT_MAX - 1,
1566 walkable = false,
1567 pointable = false,
1568 diggable = false,
1569 buildable_to = true,
1570 drop = "",
1571 drowning = 1,
1572 liquidtype = "source",
1573 liquid_alternative_flowing = "default:lava_flowing",
1574 liquid_alternative_source = "default:lava_source",
1575 liquid_viscosity = LAVA_VISC,
1576 liquid_renewable = false,
1577 damage_per_second = 2*2,
1578 post_effect_color = {a=192, r=255, g=64, b=0},
1579 groups = {lava=3, liquid=2, hot=3, igniter=1},
1583 minetest.register_node("default:torch_low", {
1584 description = "Weak Torch",
1585 drawtype = "torchlike",
1586 --tiles = {"default_torch_on_floor.png", "default_torch_on_ceiling.png", "default_torch.png"},
1587 tiles = {
1588 {name="default_torchlow_on_floor_animated.png", animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=3.0}},
1589 {name="default_torchlow_on_ceiling_animated.png", animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=3.0}},
1590 {name="default_torchlow_animated.png", animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=3.0}}
1592 inventory_image = "default_torchlow_on_floor.png",
1593 wield_image = "default_torchlow_on_floor.png",
1594 paramtype = "light",
1595 paramtype2 = "wallmounted",
1596 sunlight_propagates = true,
1597 is_ground_content = false,
1598 walkable = false,
1599 light_source = 8,
1600 selection_box = {
1601 type = "wallmounted",
1602 wall_top = {-0.1, 0.5-0.6, -0.1, 0.1, 0.5, 0.1},
1603 wall_bottom = {-0.1, -0.5, -0.1, 0.1, -0.5+0.6, 0.1},
1604 wall_side = {-0.5, -0.3, -0.1, -0.5+0.3, 0.3, 0.1},
1606 groups = {choppy=2,dig_immediate=3,flammable=1,attached_node=1,hot=2},
1607 legacy_wallmounted = true,
1608 sounds = default.node_sound_defaults(),
1611 minetest.register_node("default:torch", {
1612 description = "Bright Torch",
1613 drawtype = "torchlike",
1614 --tiles = {"default_torch_on_floor.png", "default_torch_on_ceiling.png", "default_torch.png"},
1615 tiles = {
1616 {name="default_torch_on_floor_animated.png", animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=3.0}},
1617 {name="default_torch_on_ceiling_animated.png", animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=3.0}},
1618 {name="default_torch_animated.png", animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=3.0}}
1620 inventory_image = "default_torch_on_floor.png",
1621 wield_image = "default_torch_on_floor.png",
1622 paramtype = "light",
1623 paramtype2 = "wallmounted",
1624 sunlight_propagates = true,
1625 is_ground_content = false,
1626 walkable = false,
1627 light_source = LIGHT_MAX-1,
1628 selection_box = {
1629 type = "wallmounted",
1630 wall_top = {-0.1, 0.5-0.6, -0.1, 0.1, 0.5, 0.1},
1631 wall_bottom = {-0.1, -0.5, -0.1, 0.1, -0.5+0.6, 0.1},
1632 wall_side = {-0.5, -0.3, -0.1, -0.5+0.3, 0.3, 0.1},
1634 groups = {choppy=2,dig_immediate=3,flammable=1,attached_node=1,hot=2},
1635 legacy_wallmounted = true,
1636 sounds = default.node_sound_defaults(),
1638 -- Lamps
1639 minetest.register_node("default:lamp_ceiling", {
1640 description = "Ceiling Lamp",
1641 drawtype = "nodebox",
1642 paramtype = "light",
1643 paramtype2 = "facedir",
1644 tiles = {"default_lamp.png"},
1645 sunlight_propagates = true,
1646 light_source = 14,
1647 walkable = false,
1648 groups = {snappy=2,cracky=3,oddly_breakable_by_hand=3},
1649 node_box = {
1650 type = "fixed",
1651 fixed = {
1652 {-0.25, 0.375, -0.25, 0.25, 0.5, 0.25},
1655 sounds = default.node_sound_glass_defaults(),
1658 minetest.register_node("default:lamp_wall", {
1659 description = "Wall Lamp",
1660 drawtype = "nodebox",
1661 paramtype = "light",
1662 paramtype2 = "facedir",
1663 tiles = {"default_lamp.png"},
1664 sunlight_propagates = true,
1665 light_source = 13,
1666 walkable = false,
1667 groups = {snappy=2,cracky=3,oddly_breakable_by_hand=3},
1668 node_box = {
1669 type = "fixed",
1670 fixed = {
1671 {-0.1875, -0.1875, 0.375, 0.1875, 0.1875, 0.5},
1674 sounds = default.node_sound_glass_defaults(),
1677 minetest.register_node("default:lamp_column", {
1678 description = "Column Lamp (Stairs)",
1679 drawtype = "nodebox",
1680 paramtype = "light",
1681 paramtype2 = "facedir",
1682 tiles = {"default_lamp_cl.png"},
1683 sunlight_propagates = true,
1684 light_source = 11,
1685 walkable = false,
1686 groups = {snappy=2,cracky=3,oddly_breakable_by_hand=3},
1687 node_box = {
1688 type = "fixed",
1689 fixed = {
1690 {-0.4375, -0.5, 0.0625, -0.0625, -0.375, 0.4375},
1693 sounds = default.node_sound_glass_defaults(),
1696 minetest.register_node("default:latern", {
1697 description = "Bronze Latern (stand)",
1698 drawtype = "nodebox",
1699 paramtype = "light",
1700 paramtype2 = "facedir",
1701 tiles = {
1702 "default_latern_top.png",
1703 "default_latern_top.png", -- bottom
1704 "default_latern_side.png",
1705 "default_latern_side.png",
1706 "default_latern_side.png",
1707 "default_latern_side.png",
1709 sunlight_propagates = true,
1710 light_source = 13,
1711 walkable = false,
1712 groups = {snappy=2,cracky=3,oddly_breakable_by_hand=3},
1713 node_box = {
1714 type = "fixed",
1715 fixed = {
1716 {-0.25, -0.1875, -0.25, 0.25, 0.1875, 0.25},
1717 {-0.1875, -0.25, -0.1875, 0.1875, 0.25, 0.1875},
1718 {-0.125, -0.3125, -0.125, 0.125, 0.3125, 0.125},
1719 {-0.0625, -0.5, -0.0625, 0.0625, 0.375, 0.0625},
1720 {-0.125, -0.5, -0.125, 0.125, -0.4375, 0.125},
1723 sounds = default.node_sound_glass_defaults(),
1726 minetest.register_node("default:laternrusty", {
1727 description = "Rusty Latern (stand)",
1728 drawtype = "nodebox",
1729 paramtype = "light",
1730 paramtype2 = "facedir",
1731 tiles = {
1732 "default_laternrusty_top.png",
1733 "default_laternrusty_top.png", -- bottom
1734 "default_laternrusty_side.png",
1735 "default_laternrusty_side.png",
1736 "default_laternrusty_side.png",
1737 "default_laternrusty_side.png",
1739 sunlight_propagates = true,
1740 light_source = 13,
1741 walkable = false,
1742 groups = {snappy=2,cracky=3,oddly_breakable_by_hand=3},
1743 node_box = {
1744 type = "fixed",
1745 fixed = {
1746 {-0.25, -0.1875, -0.25, 0.25, 0.1875, 0.25},
1747 {-0.1875, -0.25, -0.1875, 0.1875, 0.25, 0.1875},
1748 {-0.125, -0.3125, -0.125, 0.125, 0.3125, 0.125},
1749 {-0.0625, -0.5, -0.0625, 0.0625, 0.375, 0.0625},
1750 {-0.125, -0.5, -0.125, 0.125, -0.4375, 0.125},
1753 sounds = default.node_sound_glass_defaults(),
1756 minetest.register_node("default:sign_wall", {
1757 description = "Sign",
1758 drawtype = "signlike",
1759 tiles = {"default_sign_wall.png"},
1760 inventory_image = "default_sign_wall.png",
1761 wield_image = "default_sign_wall.png",
1762 paramtype = "light",
1763 paramtype2 = "wallmounted",
1764 sunlight_propagates = true,
1765 is_ground_content = false,
1766 walkable = false,
1767 selection_box = {
1768 type = "wallmounted",
1769 --wall_top = <default>
1770 --wall_bottom = <default>
1771 --wall_side = <default>
1773 groups = {choppy=2,dig_immediate=2,attached_node=1},
1774 legacy_wallmounted = true,
1775 sounds = default.node_sound_defaults(),
1776 on_construct = function(pos)
1777 --local n = minetest.get_node(pos)
1778 local meta = minetest.get_meta(pos)
1779 meta:set_string("formspec", "field[text;;${text}]")
1780 meta:set_string("infotext", "\"\"")
1781 end,
1782 on_receive_fields = function(pos, formname, fields, sender)
1783 --print("Sign at "..minetest.pos_to_string(pos).." got "..dump(fields))
1784 if minetest.is_protected(pos, sender:get_player_name()) then
1785 minetest.record_protection_violation(pos, sender:get_player_name())
1786 return
1788 local meta = minetest.get_meta(pos)
1789 fields.text = fields.text or ""
1790 minetest.log("action", (sender:get_player_name() or "").." wrote \""..fields.text..
1791 "\" to sign at "..minetest.pos_to_string(pos))
1792 meta:set_string("text", fields.text)
1793 meta:set_string("infotext", '"'..fields.text..'"')
1794 end,
1798 default.chest_formspec =
1799 "size[8,9]"..
1800 "list[current_name;main;0,0;8,4;]"..
1801 "list[current_player;main;0,5;8,4;]"..
1802 "background[-0.5,-0.65;9,10.35;".."chestui.png".."]"..
1803 default.gui_slots
1805 function default.get_locked_chest_formspec(pos)
1806 local spos = pos.x .. "," .. pos.y .. "," ..pos.z
1807 local formspec =
1808 "size[8,9]"..
1809 "list[nodemeta:".. spos .. ";main;0,0;8,4;]"..
1810 "list[current_player;main;0,5;8,4;]"..
1811 "background[-0.5,-0.65;9,10.35;".."chestui.png".."]"..
1812 default.gui_slots
1813 return formspec
1819 minetest.register_node("default:chest", {
1820 description = "Chest",
1821 tiles = {"default_chest_top.png", "default_chest_top.png", "default_chest_side.png",
1822 "default_chest_side.png", "default_chest_side.png", "default_chest_front.png"},
1823 paramtype2 = "facedir",
1824 groups = {choppy=2,oddly_breakable_by_hand=2, chests=1},
1825 legacy_facedir_simple = true,
1826 is_ground_content = false,
1827 sounds = default.node_sound_wood_defaults(),
1828 on_construct = function(pos)
1829 local meta = minetest.get_meta(pos)
1830 meta:set_string("formspec",default.chest_formspec)
1831 meta:set_string("infotext", "Chest")
1832 local inv = meta:get_inventory()
1833 inv:set_size("main", 8*4)
1834 end,
1835 can_dig = function(pos,player)
1836 local meta = minetest.get_meta(pos);
1837 local inv = meta:get_inventory()
1838 return inv:is_empty("main")
1839 end,
1840 on_metadata_inventory_move = function(pos, from_list, from_index, to_list, to_index, count, player)
1841 minetest.log("action", player:get_player_name()..
1842 " moves stuff in chest at "..minetest.pos_to_string(pos))
1843 end,
1844 on_metadata_inventory_put = function(pos, listname, index, stack, player)
1845 minetest.log("action", player:get_player_name()..
1846 " moves stuff to chest at "..minetest.pos_to_string(pos))
1847 end,
1848 on_metadata_inventory_take = function(pos, listname, index, stack, player)
1849 minetest.log("action", player:get_player_name()..
1850 " takes stuff from chest at "..minetest.pos_to_string(pos))
1851 end,
1855 local function has_locked_chest_privilege(meta, player)
1856 if player:get_player_name() ~= meta:get_string("owner") then
1857 return false
1859 return true
1863 minetest.register_node("default:chest_locked", {
1864 description = "Locked Chest",
1865 tiles = {"default_chest_top.png", "default_chest_top.png", "default_chest_side.png",
1866 "default_chest_side.png", "default_chest_side.png", "default_chest_lock.png"},
1867 paramtype2 = "facedir",
1868 groups = {choppy=2,oddly_breakable_by_hand=2, lchests=1},
1869 legacy_facedir_simple = true,
1870 is_ground_content = false,
1871 sounds = default.node_sound_wood_defaults(),
1872 after_place_node = function(pos, placer)
1873 local meta = minetest.get_meta(pos)
1874 meta:set_string("owner", placer:get_player_name() or "")
1875 meta:set_string("infotext", "Locked Chest (owned by "..
1876 meta:get_string("owner")..")")
1877 end,
1878 on_construct = function(pos)
1879 local meta = minetest.get_meta(pos)
1880 meta:set_string("infotext", "Locked Chest")
1881 meta:set_string("owner", "")
1882 local inv = meta:get_inventory()
1883 inv:set_size("main", 8*4)
1884 end,
1885 can_dig = function(pos,player)
1886 local meta = minetest.get_meta(pos);
1887 local inv = meta:get_inventory()
1888 return inv:is_empty("main") and has_locked_chest_privilege(meta, player)
1889 end,
1890 allow_metadata_inventory_move = function(pos, from_list, from_index, to_list, to_index, count, player)
1891 local meta = minetest.get_meta(pos)
1892 if not has_locked_chest_privilege(meta, player) then
1893 minetest.log("action", player:get_player_name()..
1894 " tried to access a locked chest belonging to "..
1895 meta:get_string("owner").." at "..
1896 minetest.pos_to_string(pos))
1897 return 0
1899 return count
1900 end,
1901 allow_metadata_inventory_put = function(pos, listname, index, stack, player)
1902 local meta = minetest.get_meta(pos)
1903 if not has_locked_chest_privilege(meta, player) then
1904 minetest.log("action", player:get_player_name()..
1905 " tried to access a locked chest belonging to "..
1906 meta:get_string("owner").." at "..
1907 minetest.pos_to_string(pos))
1908 return 0
1910 return stack:get_count()
1911 end,
1912 allow_metadata_inventory_take = function(pos, listname, index, stack, player)
1913 local meta = minetest.get_meta(pos)
1914 if not has_locked_chest_privilege(meta, player) then
1915 minetest.log("action", player:get_player_name()..
1916 " tried to access a locked chest belonging to "..
1917 meta:get_string("owner").." at "..
1918 minetest.pos_to_string(pos))
1919 return 0
1921 return stack:get_count()
1922 end,
1923 on_metadata_inventory_move = function(pos, from_list, from_index, to_list, to_index, count, player)
1924 minetest.log("action", player:get_player_name()..
1925 " moves stuff in locked chest at "..minetest.pos_to_string(pos))
1926 end,
1927 on_metadata_inventory_put = function(pos, listname, index, stack, player)
1928 minetest.log("action", player:get_player_name()..
1929 " moves stuff to locked chest at "..minetest.pos_to_string(pos))
1930 end,
1931 on_metadata_inventory_take = function(pos, listname, index, stack, player)
1932 minetest.log("action", player:get_player_name()..
1933 " takes stuff from locked chest at "..minetest.pos_to_string(pos))
1934 end,
1935 on_rightclick = function(pos, node, clicker)
1936 local meta = minetest.get_meta(pos)
1937 if has_locked_chest_privilege(meta, clicker) then
1938 minetest.show_formspec(
1939 clicker:get_player_name(),
1940 "default:chest_locked",
1941 default.get_locked_chest_formspec(pos)
1944 end,
1947 minetest.register_node("default:cobble", {
1948 description = "Cobblestone",
1949 tiles = {"default_cobble.png"},
1950 is_ground_content = true,
1951 groups = {cracky=3, stone=2},
1952 sounds = default.node_sound_stone_defaults(),
1955 minetest.register_node("default:cobble_block", {
1956 description = "Cobblestone Block",
1957 tiles = {"default_cobble_block.png"},
1958 is_ground_content = true,
1959 groups = {cracky=3, stone=2},
1960 sounds = default.node_sound_stone_defaults(),
1963 minetest.register_node("default:mossycobble", {
1964 description = "Mossy Cobblestone",
1965 tiles = {"default_mossycobble.png"},
1966 is_ground_content = true,
1967 groups = {cracky=3},
1968 sounds = default.node_sound_stone_defaults(),
1972 minetest.register_node("default:coalblock", {
1973 description = "Coal Block",
1974 tiles = {"default_coal_block.png"},
1975 is_ground_content = true,
1976 groups = {cracky=3},
1977 sounds = default.node_sound_stone_defaults(),
1981 minetest.register_node("default:steelblock", {
1982 description = "Steel Block",
1983 tiles = {"default_steel_block.png"},
1984 is_ground_content = true,
1985 groups = {cracky=1,level=2},
1986 sounds = default.node_sound_stone_defaults(),
1989 minetest.register_node("default:tinblock", {
1990 description = "Tin Block",
1991 tiles = {"default_tin_block.png"},
1992 is_ground_content = true,
1993 groups = {cracky=1,level=2},
1994 sounds = default.node_sound_stone_defaults(),
1997 minetest.register_node("default:copperblock", {
1998 description = "Copper Block",
1999 tiles = {"default_copper_block.png"},
2000 is_ground_content = true,
2001 groups = {cracky=1,level=2},
2002 sounds = default.node_sound_stone_defaults(),
2006 minetest.register_node("default:bronzeblock", {
2007 description = "Bronze Block",
2008 tiles = {"default_bronze_block.png"},
2009 is_ground_content = true,
2010 groups = {cracky=1,level=2},
2011 sounds = default.node_sound_stone_defaults(),
2015 minetest.register_node("default:mese", {
2016 description = "Mese Block",
2017 tiles = {"default_mese_block.png"},
2018 is_ground_content = true,
2019 groups = {cracky=1,level=2},
2020 sounds = default.node_sound_stone_defaults(),
2022 minetest.register_alias("default:mese_block", "default:mese")
2025 minetest.register_node("default:goldblock", {
2026 description = "Gold Block",
2027 tiles = {"default_gold_block.png"},
2028 is_ground_content = true,
2029 groups = {cracky=1},
2030 sounds = default.node_sound_stone_defaults(),
2033 minetest.register_node("default:emerald_block", {
2034 description = "Emerald Block",
2035 tiles = {"default_emerald_block.png"},
2036 is_ground_content = true,
2037 groups = {cracky=1,level=2},
2038 sounds = default.node_sound_stone_defaults(),
2041 minetest.register_node("default:sapphire_block", {
2042 description = "Sapphire Block",
2043 tiles = {"default_sapphire_block.png"},
2044 is_ground_content = true,
2045 groups = {cracky=1,level=2},
2046 sounds = default.node_sound_stone_defaults(),
2049 minetest.register_node("default:ruby_block", {
2050 description = "Ruby Block",
2051 tiles = {"default_ruby_block.png"},
2052 is_ground_content = true,
2053 groups = {cracky=1,level=2},
2054 sounds = default.node_sound_stone_defaults(),
2057 minetest.register_node("default:diamondblock", {
2058 description = "Diamond Block",
2059 tiles = {"default_diamond_block.png"},
2060 is_ground_content = true,
2061 groups = {cracky=1,level=3},
2062 sounds = default.node_sound_stone_defaults(),
2066 minetest.register_node("default:obsidian_glass", {
2067 description = "Obsidian Glass",
2068 drawtype = "glasslike",
2069 tiles = {"default_obsidian_glass.png"},
2070 paramtype = "light",
2071 is_ground_content = false,
2072 sunlight_propagates = true,
2073 sounds = default.node_sound_glass_defaults(),
2074 groups = {cracky=3,oddly_breakable_by_hand=3},
2078 minetest.register_node("default:obsidian", {
2079 description = "Obsidian",
2080 tiles = {"default_obsidian.png"},
2081 is_ground_content = true,
2082 sounds = default.node_sound_stone_defaults(),
2083 groups = {cracky=1,level=2},
2086 minetest.register_node("default:obsidian_block", {
2087 description = "Obsidian Block",
2088 tiles = {"default_obsidian_block.png"},
2089 is_ground_content = true,
2090 sounds = default.node_sound_stone_defaults(),
2091 groups = {cracky=2},
2095 minetest.register_node("default:nyancat", {
2096 description = "Nyan Cat",
2097 tiles = {"default_nc_side.png", "default_nc_side.png", "default_nc_side.png",
2098 "default_nc_side.png", "default_nc_back.png", "default_nc_front.png"},
2099 paramtype2 = "facedir",
2100 groups = {cracky=2},
2101 is_ground_content = false,
2102 legacy_facedir_simple = true,
2103 sounds = default.node_sound_defaults(),
2107 minetest.register_node("default:nyancat_rainbow", {
2108 description = "Nyan Cat Rainbow",
2109 tiles = {"default_nc_rb.png^[transformR90", "default_nc_rb.png^[transformR90",
2110 "default_nc_rb.png", "default_nc_rb.png"},
2111 paramtype2 = "facedir",
2112 groups = {cracky=2},
2113 is_ground_content = false,
2114 sounds = default.node_sound_defaults(),
2118 minetest.register_node("default:sapling", {
2119 description = "Sapling",
2120 drawtype = "plantlike",
2121 visual_scale = 1.0,
2122 tiles = {"default_sapling.png"},
2123 inventory_image = "default_sapling.png",
2124 wield_image = "default_sapling.png",
2125 paramtype = "light",
2126 walkable = false,
2127 is_ground_content = true,
2128 selection_box = {
2129 type = "fixed",
2130 fixed = {-0.3, -0.5, -0.3, 0.3, 0.35, 0.3}
2132 groups = {snappy=2,dig_immediate=3,flammable=2,attached_node=1, sapling=1},
2133 sounds = default.node_sound_leaves_defaults(),
2137 minetest.register_node("default:apple", {
2138 description = "Apple (+2)",
2139 drawtype = "plantlike",
2140 visual_scale = 0.75,
2141 tiles = {"default_apple.png"},
2142 inventory_image = "default_apple.png",
2143 paramtype = "light",
2144 sunlight_propagates = true,
2145 walkable = false,
2146 is_ground_content = true,
2147 selection_box = {
2148 type = "fixed",
2149 fixed = {-0.2, -0.5, -0.2, 0.2, 0, 0.2}
2151 groups = {fleshy=3,dig_immediate=3,flammable=2,leafdecay=3,leafdecay_drop=1},
2152 on_use = minetest.item_eat(2),
2153 sounds = default.node_sound_leaves_defaults(),
2154 after_place_node = function(pos, placer, itemstack)
2155 if placer:is_player() then
2156 minetest.set_node(pos, {name="default:apple", param2=1})
2158 end,
2162 minetest.register_node("default:dry_shrub", {
2163 description = "Dry Shrub",
2164 drawtype = "plantlike",
2165 visual_scale = 1.0,
2166 tiles = {"default_dry_shrub.png"},
2167 inventory_image = "default_dry_shrub.png",
2168 wield_image = "default_dry_shrub.png",
2169 paramtype = "light",
2170 waving = 1,
2171 walkable = false,
2172 is_ground_content = true,
2173 buildable_to = true,
2174 groups = {snappy=3,flammable=3,attached_node=1},
2175 sounds = default.node_sound_leaves_defaults(),
2176 selection_box = {
2177 type = "fixed",
2178 fixed = {-0.5, -0.5, -0.5, 0.5, -5/16, 0.5},
2183 minetest.register_node("default:grass_1", {
2184 description = "Grass",
2185 drawtype = "plantlike",
2186 tiles = {"default_grass_1.png"},
2187 -- use a bigger inventory image
2188 inventory_image = "default_grass_3.png",
2189 wield_image = "default_grass_3.png",
2190 paramtype = "light",
2191 walkable = false,
2192 is_ground_content = true,
2193 buildable_to = true,
2194 groups = {snappy=3,flammable=3,flora=1,attached_node=1},
2195 sounds = default.node_sound_leaves_defaults(),
2196 selection_box = {
2197 type = "fixed",
2198 fixed = {-0.5, -0.5, -0.5, 0.5, -5/16, 0.5},
2200 on_place = function(itemstack, placer, pointed_thing)
2201 -- place a random grass node
2202 local stack = ItemStack("default:grass_"..math.random(1,5))
2203 local ret = minetest.item_place(stack, placer, pointed_thing)
2204 return ItemStack("default:grass_1 "..itemstack:get_count()-(1-ret:get_count()))
2205 end,
2209 minetest.register_node("default:grass_2", {
2210 description = "Grass",
2211 drawtype = "plantlike",
2212 tiles = {"default_grass_2.png"},
2213 inventory_image = "default_grass_2.png",
2214 wield_image = "default_grass_2.png",
2215 paramtype = "light",
2216 walkable = false,
2217 buildable_to = true,
2218 is_ground_content = true,
2219 drop = "default:grass_1",
2220 groups = {snappy=3,flammable=3,flora=1,attached_node=1,not_in_creative_inventory=1},
2221 sounds = default.node_sound_leaves_defaults(),
2222 selection_box = {
2223 type = "fixed",
2224 fixed = {-0.5, -0.5, -0.5, 0.5, -5/16, 0.5},
2227 minetest.register_node("default:grass_3", {
2228 description = "Grass",
2229 drawtype = "plantlike",
2230 tiles = {"default_grass_3.png"},
2231 inventory_image = "default_grass_3.png",
2232 wield_image = "default_grass_3.png",
2233 paramtype = "light",
2234 walkable = false,
2235 buildable_to = true,
2236 is_ground_content = true,
2237 drop = "default:grass_1",
2238 groups = {snappy=3,flammable=3,flora=1,attached_node=1,not_in_creative_inventory=1},
2239 sounds = default.node_sound_leaves_defaults(),
2240 selection_box = {
2241 type = "fixed",
2242 fixed = {-0.5, -0.5, -0.5, 0.5, -5/16, 0.5},
2247 minetest.register_node("default:grass_4", {
2248 description = "Grass",
2249 drawtype = "plantlike",
2250 tiles = {"default_grass_4.png"},
2251 inventory_image = "default_grass_4.png",
2252 wield_image = "default_grass_4.png",
2253 paramtype = "light",
2254 walkable = false,
2255 buildable_to = true,
2256 is_ground_content = true,
2257 drop = "default:grass_1",
2258 groups = {snappy=3,flammable=3,flora=1,attached_node=1,not_in_creative_inventory=1},
2259 sounds = default.node_sound_leaves_defaults(),
2260 selection_box = {
2261 type = "fixed",
2262 fixed = {-0.5, -0.5, -0.5, 0.5, -5/16, 0.5},
2267 minetest.register_node("default:grass_5", {
2268 description = "Grass",
2269 drawtype = "plantlike",
2270 tiles = {"default_grass_5.png"},
2271 inventory_image = "default_grass_5.png",
2272 wield_image = "default_grass_5.png",
2273 paramtype = "light",
2274 walkable = false,
2275 buildable_to = true,
2276 is_ground_content = true,
2277 drop = "default:grass_1",
2278 groups = {snappy=3,flammable=3,flora=1,attached_node=1,not_in_creative_inventory=1},
2279 sounds = default.node_sound_leaves_defaults(),
2280 selection_box = {
2281 type = "fixed",
2282 fixed = {-0.5, -0.5, -0.5, 0.5, -5/16, 0.5},
2287 minetest.register_node("default:ice", {
2288 description = "Ice",
2289 tiles = {"default_ice.png"},
2290 is_ground_content = true,
2291 paramtype = "light",
2292 freezemelt = "default:water_source",
2293 groups = {cracky=3, melts=1},
2294 sounds = default.node_sound_glass_defaults(),
2298 minetest.register_node("default:snow", {
2299 description = "Snow",
2300 tiles = {"default_snow.png"},
2301 inventory_image = "default_snowball.png",
2302 wield_image = "default_snowball.png",
2303 is_ground_content = true,
2304 paramtype = "light",
2305 buildable_to = true,
2306 leveled = 7,
2307 drawtype = "nodebox",
2308 freezemelt = "default:water_flowing",
2309 node_box = {
2310 type = "leveled",
2311 fixed = {
2312 {-0.5, -0.5, -0.5, 0.5, -0.5+2/16, 0.5},
2315 groups = {crumbly=3,falling_node=1, melts=1, float=1},
2316 sounds = default.node_sound_dirt_defaults({
2317 footstep = {name="default_snow_footstep", gain=0.25},
2318 dug = {name="default_snow_footstep", gain=0.75},
2320 on_construct = function(pos)
2321 pos.y = pos.y - 1
2322 if minetest.get_node(pos).name == "default:dirt_with_grass" then
2323 minetest.set_node(pos, {name="default:dirt_with_snow"})
2325 end,
2327 minetest.register_alias("snow", "default:snow")
2330 minetest.register_node("default:snowblock", {
2331 description = "Snow Block",
2332 tiles = {"default_snow.png"},
2333 is_ground_content = true,
2334 freezemelt = "default:water_source",
2335 groups = {crumbly=3, melts=1},
2336 sounds = default.node_sound_dirt_defaults({
2337 footstep = {name="default_snow_footstep", gain=0.25},
2338 dug = {name="default_snow_footstep", gain=0.75},
2343 minetest.register_node("default:snag", {
2344 description = "Snag",
2345 tiles = {"default_tree.png", "default_tree.png", "default_tree.png"},
2346 paramtype = "light",
2347 -- paramtype2 = "facedir",
2348 is_ground_content = false,
2349 drawtype = "nodebox",
2350 node_box = {
2351 type = "fixed",
2352 fixed = {
2353 {-0.03125, -0.5, -0.03125, 0.03125, -0.0625, 0.03125},
2354 {0.03125, -0.15625, -0.03125, 0.09375, -0.09375, 0.03125},
2355 {0.0625, -0.1875, -0.03125, 0.125, 0.0625, 0.03125},
2356 {-0.09375, -0.21875, -0.03125, -0.03125, -0.15625, 0.03125},
2357 {-0.15625, -0.25, -0.03125, -0.09375, -0.125, 0.03125},
2358 {-0.03125, -0.34375, 0.03125, 0.03125, -0.28125, 0.09375},
2359 {-0.03125, -0.46875, -0.09375, 0.03125, -0.40625, -0.03125},
2360 {-0.03125, -0.375, 0.09375, 0.03125, -0.25, 0.15625},
2363 groups = {tree=1,choppy=2,oddly_breakable_by_hand=1,flammable=2},
2364 drop = {
2365 max_items = 1,
2366 items = {
2368 -- player will get sapling with 1/5 chance
2369 items = {'default:snag'},
2370 rarity = 5,
2373 -- player will get wood only if he get no saplings,
2374 -- this is because max_items is 1
2375 items = {'default:wood'},
2379 sounds = default.node_sound_wood_defaults(),
2380 on_place = minetest.rotate_node
2383 minetest.register_node("default:stone_with_emerald", {
2384 description = "Emerald Ore",
2385 tiles = {"default_stone.png^default_mineral_emerald.png"},
2386 is_ground_content = true,
2387 groups = {cracky=2},
2388 drop = "default:emerald",
2389 sounds = default.node_sound_stone_defaults(),
2392 minetest.register_node("default:stone_with_sapphire", {
2393 description = "Sapphire Ore",
2394 tiles = {"default_stone.png^default_mineral_sapphire.png"},
2395 is_ground_content = true,
2396 groups = {cracky=2},
2397 drop = "default:sapphire",
2398 sounds = default.node_sound_stone_defaults(),
2401 minetest.register_node("default:stone_with_ruby", {
2402 description = "Ruby Ore",
2403 tiles = {"default_stone.png^default_mineral_ruby.png"},
2404 is_ground_content = true,
2405 groups = {cracky=1},
2406 drop = "default:ruby",
2407 sounds = default.node_sound_stone_defaults(),