wood.lua 7.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291
  1. local S = ethereal.intllib
  2. -- sakura trunk
  3. minetest.register_node("ethereal:sakura_trunk", {
  4. description = S("Sakura Trunk"),
  5. tiles = {
  6. "ethereal_sakura_trunk_top.png",
  7. "ethereal_sakura_trunk_top.png",
  8. "ethereal_sakura_trunk.png"
  9. },
  10. groups = {tree = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2},
  11. sounds = default.node_sound_wood_defaults(),
  12. paramtype2 = "facedir",
  13. on_place = minetest.rotate_node,
  14. })
  15. -- sakura wood
  16. minetest.register_node("ethereal:sakura_wood", {
  17. description = S("Sakura Wood"),
  18. tiles = {"ethereal_sakura_wood.png"},
  19. is_ground_content = false,
  20. groups = {wood = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 3},
  21. sounds = default.node_sound_wood_defaults(),
  22. })
  23. minetest.register_craft({
  24. output = "ethereal:sakura_wood 4",
  25. recipe = {{"ethereal:sakura_trunk"}}
  26. })
  27. -- willow trunk
  28. minetest.register_node("ethereal:willow_trunk", {
  29. description = S("Willow Trunk"),
  30. tiles = {
  31. "willow_trunk_top.png",
  32. "willow_trunk_top.png",
  33. "willow_trunk.png"
  34. },
  35. groups = {tree = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2},
  36. sounds = default.node_sound_wood_defaults(),
  37. paramtype2 = "facedir",
  38. on_place = minetest.rotate_node,
  39. })
  40. -- willow wood
  41. minetest.register_node("ethereal:willow_wood", {
  42. description = S("Willow Wood"),
  43. tiles = {"willow_wood.png"},
  44. is_ground_content = false,
  45. groups = {wood = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 3},
  46. sounds = default.node_sound_wood_defaults(),
  47. })
  48. minetest.register_craft({
  49. output = "ethereal:willow_wood 4",
  50. recipe = {{"ethereal:willow_trunk"}}
  51. })
  52. -- redwood trunk
  53. minetest.register_node("ethereal:redwood_trunk", {
  54. description = S("Redwood Trunk"),
  55. tiles = {
  56. "redwood_trunk_top.png",
  57. "redwood_trunk_top.png",
  58. "redwood_trunk.png"
  59. },
  60. groups = {tree = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2},
  61. sounds = default.node_sound_wood_defaults(),
  62. paramtype2 = "facedir",
  63. on_place = minetest.rotate_node,
  64. })
  65. -- redwood wood
  66. minetest.register_node("ethereal:redwood_wood", {
  67. description = S("Redwood Wood"),
  68. tiles = {"redwood_wood.png"},
  69. is_ground_content = false,
  70. groups = {wood = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 3},
  71. sounds = default.node_sound_wood_defaults(),
  72. })
  73. minetest.register_craft({
  74. output = "ethereal:redwood_wood 4",
  75. recipe = {{"ethereal:redwood_trunk"}},
  76. })
  77. -- frost trunk
  78. minetest.register_node("ethereal:frost_tree", {
  79. description = S("Frost Tree"),
  80. tiles = {
  81. "ethereal_frost_tree_top.png",
  82. "ethereal_frost_tree_top.png",
  83. "ethereal_frost_tree.png"
  84. },
  85. groups = {tree = 1, choppy = 2, oddly_breakable_by_hand = 1, put_out_fire = 1},
  86. sounds = default.node_sound_wood_defaults(),
  87. paramtype2 = "facedir",
  88. on_place = minetest.rotate_node,
  89. })
  90. -- frost wood
  91. minetest.register_node("ethereal:frost_wood", {
  92. description = S("Frost Wood"),
  93. tiles = {"frost_wood.png"},
  94. is_ground_content = false,
  95. groups = {wood = 1, choppy = 2, oddly_breakable_by_hand = 1, put_out_fire = 1},
  96. sounds = default.node_sound_wood_defaults(),
  97. })
  98. minetest.register_craft({
  99. output = "ethereal:frost_wood 4",
  100. recipe = {{"ethereal:frost_tree"}}
  101. })
  102. -- healing trunk
  103. minetest.register_node("ethereal:yellow_trunk", {
  104. description = S("Healing Tree Trunk"),
  105. tiles = {
  106. "yellow_tree_top.png",
  107. "yellow_tree_top.png",
  108. "yellow_tree.png"
  109. },
  110. groups = {tree = 1, choppy = 2, oddly_breakable_by_hand = 1, put_out_fire = 1},
  111. sounds = default.node_sound_wood_defaults(),
  112. paramtype2 = "facedir",
  113. on_place = minetest.rotate_node,
  114. })
  115. -- healing wood
  116. minetest.register_node("ethereal:yellow_wood", {
  117. description = S("Healing Tree Wood"),
  118. tiles = {"yellow_wood.png"},
  119. is_ground_content = false,
  120. groups = {wood = 1, choppy = 2, oddly_breakable_by_hand = 1, put_out_fire = 1},
  121. sounds = default.node_sound_wood_defaults(),
  122. })
  123. minetest.register_craft({
  124. output = "ethereal:yellow_wood 4",
  125. recipe = {{"ethereal:yellow_trunk"}}
  126. })
  127. -- palm trunk (thanks to VanessaE for palm textures)
  128. minetest.register_node("ethereal:palm_trunk", {
  129. description = S("Palm Trunk"),
  130. tiles = {
  131. "moretrees_palm_trunk_top.png",
  132. "moretrees_palm_trunk_top.png",
  133. "moretrees_palm_trunk.png"
  134. },
  135. groups = {tree = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2},
  136. sounds = default.node_sound_wood_defaults(),
  137. paramtype2 = "facedir",
  138. on_place = minetest.rotate_node,
  139. })
  140. -- palm wood
  141. minetest.register_node("ethereal:palm_wood", {
  142. description = S("Palm Wood"),
  143. tiles = {"moretrees_palm_wood.png"},
  144. is_ground_content = false,
  145. groups = {wood = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 3},
  146. sounds = default.node_sound_wood_defaults(),
  147. })
  148. minetest.register_craft({
  149. output = "ethereal:palm_wood 4",
  150. recipe = {{"ethereal:palm_trunk"}}
  151. })
  152. -- banana trunk
  153. minetest.register_node("ethereal:banana_trunk", {
  154. description = S("Banana Trunk"),
  155. tiles = {
  156. "banana_trunk_top.png",
  157. "banana_trunk_top.png",
  158. "banana_trunk.png"
  159. },
  160. groups = {tree = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2},
  161. sounds = default.node_sound_wood_defaults(),
  162. paramtype2 = "facedir",
  163. on_place = minetest.rotate_node,
  164. })
  165. -- banana wood
  166. minetest.register_node("ethereal:banana_wood", {
  167. description = S("Banana Wood"),
  168. tiles = {"banana_wood.png"},
  169. is_ground_content = false,
  170. groups = {wood = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 3},
  171. sounds = default.node_sound_wood_defaults(),
  172. })
  173. minetest.register_craft({
  174. output = "ethereal:banana_wood 4",
  175. recipe = {{"ethereal:banana_trunk"}}
  176. })
  177. -- scorched trunk
  178. minetest.register_node("ethereal:scorched_tree", {
  179. description = S("Scorched Tree"),
  180. tiles = {
  181. "scorched_tree_top.png",
  182. "scorched_tree_top.png",
  183. "scorched_tree.png"
  184. },
  185. groups = {tree = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 1},
  186. sounds = default.node_sound_wood_defaults(),
  187. paramtype2 = "facedir",
  188. on_place = minetest.rotate_node,
  189. })
  190. minetest.register_craft({
  191. output = "ethereal:scorched_tree 8",
  192. recipe = {
  193. {"group:tree", "group:tree", "group:tree"},
  194. {"group:tree", "default:torch", "group:tree"},
  195. {"group:tree", "group:tree", "group:tree"},
  196. }
  197. })
  198. -- mushroom trunk
  199. minetest.register_node("ethereal:mushroom_trunk", {
  200. description = S("Mushroom"),
  201. tiles = {
  202. "mushroom_trunk_top.png",
  203. "mushroom_trunk_top.png",
  204. "mushroom_trunk.png"
  205. },
  206. groups = {tree = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2},
  207. sounds = default.node_sound_wood_defaults(),
  208. paramtype2 = "facedir",
  209. on_place = minetest.rotate_node,
  210. })
  211. -- birch trunk (thanks to VanessaE for birch textures)
  212. minetest.register_node("ethereal:birch_trunk", {
  213. description = S("Birch Trunk"),
  214. tiles = {
  215. "moretrees_birch_trunk_top.png",
  216. "moretrees_birch_trunk_top.png",
  217. "moretrees_birch_trunk.png"
  218. },
  219. groups = {tree = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2},
  220. sounds = default.node_sound_wood_defaults(),
  221. paramtype2 = "facedir",
  222. on_place = minetest.rotate_node,
  223. })
  224. -- birch wood
  225. minetest.register_node("ethereal:birch_wood", {
  226. description = S("Birch Wood"),
  227. tiles = {"moretrees_birch_wood.png"},
  228. is_ground_content = false,
  229. groups = {wood = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 3},
  230. sounds = default.node_sound_wood_defaults(),
  231. })
  232. minetest.register_craft({
  233. output = "ethereal:birch_wood 4",
  234. recipe = {{"ethereal:birch_trunk"}}
  235. })
  236. -- Bamboo (thanks to Nelo-slay on DeviantArt for the free Bamboo base image)
  237. minetest.register_node("ethereal:bamboo", {
  238. description = S("Bamboo"),
  239. drawtype = "plantlike",
  240. tiles = {"bamboo.png"},
  241. inventory_image = "bamboo.png",
  242. wield_image = "bamboo.png",
  243. paramtype = "light",
  244. sunlight_propagates = true,
  245. walkable = true,
  246. selection_box = {
  247. type = "fixed",
  248. fixed = {-0.3, -0.5, -0.3, 0.3, 0.5, 0.3}
  249. },
  250. groups = {choppy = 3, oddly_breakable_by_hand = 1, flammable = 2},--tree = 1
  251. sounds = default.node_sound_leaves_defaults(),
  252. after_dig_node = function(pos, node, metadata, digger)
  253. default.dig_up(pos, node, digger)
  254. end,
  255. })
  256. minetest.register_craft({
  257. type = "fuel",
  258. recipe = "ethereal:bamboo",
  259. burntime = 1,
  260. })