write something there
2
mods/biomes/frost_land/README.md
Normal file
|
@ -0,0 +1,2 @@
|
|||
# frost_land
|
||||
A simple and pleasant little mod, which adds a Frost Land biome with a few more objects.
|
15
mods/biomes/frost_land/crafting.lua
Normal file
|
@ -0,0 +1,15 @@
|
|||
------------Crafting
|
||||
minetest.register_craft({
|
||||
output = "frost_land:frost_land_wood 4",
|
||||
recipe = {
|
||||
{"frost_land:frost_land_tree"},
|
||||
}
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = "frost_land:frost_land_trapdoor 2",
|
||||
recipe = {
|
||||
{"nightshade:nightshade_wood", "nightshade:nightshade_wood", "nightshade:nightshade_wood"},
|
||||
{"nightshade:nightshade_wood", "nightshade:nightshade_wood", "nightshade:nightshade_wood"},
|
||||
}
|
||||
})
|
343
mods/biomes/frost_land/fireflies.lua
Normal file
|
@ -0,0 +1,343 @@
|
|||
|
||||
--------------------------------------------------------------------------------------------------------------------------------
|
||||
minetest.register_node("frost_land:blue_firefly", {
|
||||
description = "Blue Firefly",
|
||||
drawtype = "plantlike",
|
||||
tiles = {{
|
||||
name = "frost_land_blue_firefly_animated.png",
|
||||
animation = {
|
||||
type = "vertical_frames",
|
||||
aspect_w = 16,
|
||||
aspect_h = 16,
|
||||
length = 1.5
|
||||
},
|
||||
}},
|
||||
inventory_image = "frost_land_blue_firefly.png",
|
||||
wield_image = "frost_land_blue_firefly.png",
|
||||
waving = 1,
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
buildable_to = true,
|
||||
walkable = false,
|
||||
groups = {catchable = 1},
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-0.1, -0.1, -0.1, 0.1, 0.1, 0.1},
|
||||
},
|
||||
light_source = 6,
|
||||
floodable = true,
|
||||
on_place = function(itemstack, placer, pointed_thing)
|
||||
local player_name = placer:get_player_name()
|
||||
local pos = pointed_thing.above
|
||||
|
||||
if not minetest.is_protected(pos, player_name) and
|
||||
not minetest.is_protected(pointed_thing.under, player_name) and
|
||||
minetest.get_node(pos).name == "air" then
|
||||
minetest.set_node(pos, {name = "frost_land:blue_firefly"})
|
||||
minetest.get_node_timer(pos):start(1)
|
||||
itemstack:take_item()
|
||||
end
|
||||
return itemstack
|
||||
end,
|
||||
on_timer = function(pos, elapsed)
|
||||
if minetest.get_node_light(pos) > 11 then
|
||||
minetest.set_node(pos, {name = "frost_land:hidden_blue_firefly"})
|
||||
end
|
||||
minetest.get_node_timer(pos):start(30)
|
||||
end
|
||||
})
|
||||
|
||||
minetest.register_node("frost_land:hidden_blue_firefly", {
|
||||
description = "Hidden Blue Firefly",
|
||||
drawtype = "airlike",
|
||||
inventory_image = "frost_land_blue_firefly.png^default_invisible_node_overlay.png",
|
||||
wield_image = "frost_land_blue_firefly.png^default_invisible_node_overlay.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
pointable = false,
|
||||
diggable = false,
|
||||
buildable_to = true,
|
||||
drop = "",
|
||||
groups = {not_in_creative_inventory = 1},
|
||||
floodable = true,
|
||||
on_place = function(itemstack, placer, pointed_thing)
|
||||
local player_name = placer:get_player_name()
|
||||
local pos = pointed_thing.above
|
||||
|
||||
if not minetest.is_protected(pos, player_name) and
|
||||
not minetest.is_protected(pointed_thing.under, player_name) and
|
||||
minetest.get_node(pos).name == "air" then
|
||||
minetest.set_node(pos, {name = "frost_land:hidden_blue_firefly"})
|
||||
minetest.get_node_timer(pos):start(1)
|
||||
itemstack:take_item()
|
||||
end
|
||||
return itemstack
|
||||
end,
|
||||
on_timer = function(pos, elapsed)
|
||||
if minetest.get_node_light(pos) <= 11 then
|
||||
minetest.set_node(pos, {name = "frost_land:blue_firefly"})
|
||||
end
|
||||
minetest.get_node_timer(pos):start(30)
|
||||
end
|
||||
})
|
||||
|
||||
-------------------------------------------------------------------------------------------------------------------------------
|
||||
minetest.register_node("frost_land:pink_firefly", {
|
||||
description = "Pink Firefly",
|
||||
drawtype = "plantlike",
|
||||
tiles = {{
|
||||
name = "frost_land_pink_firefly_animated.png",
|
||||
animation = {
|
||||
type = "vertical_frames",
|
||||
aspect_w = 16,
|
||||
aspect_h = 16,
|
||||
length = 1.5
|
||||
},
|
||||
}},
|
||||
inventory_image = "frost_land_pink_firefly.png",
|
||||
wield_image = "frost_land_pink_firefly.png",
|
||||
waving = 1,
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
buildable_to = true,
|
||||
walkable = false,
|
||||
groups = {catchable = 1},
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-0.1, -0.1, -0.1, 0.1, 0.1, 0.1},
|
||||
},
|
||||
light_source = 6,
|
||||
floodable = true,
|
||||
on_place = function(itemstack, placer, pointed_thing)
|
||||
local player_name = placer:get_player_name()
|
||||
local pos = pointed_thing.above
|
||||
|
||||
if not minetest.is_protected(pos, player_name) and
|
||||
not minetest.is_protected(pointed_thing.under, player_name) and
|
||||
minetest.get_node(pos).name == "air" then
|
||||
minetest.set_node(pos, {name = "frost_land:pink_firefly"})
|
||||
minetest.get_node_timer(pos):start(1)
|
||||
itemstack:take_item()
|
||||
end
|
||||
return itemstack
|
||||
end,
|
||||
on_timer = function(pos, elapsed)
|
||||
if minetest.get_node_light(pos) > 11 then
|
||||
minetest.set_node(pos, {name = "frost_land:hidden_pink_firefly"})
|
||||
end
|
||||
minetest.get_node_timer(pos):start(30)
|
||||
end
|
||||
})
|
||||
|
||||
minetest.register_node("frost_land:hidden_pink_firefly", {
|
||||
description = "Hidden Pink Firefly",
|
||||
drawtype = "airlike",
|
||||
inventory_image = "frost_land_pink_firefly.png^default_invisible_node_overlay.png",
|
||||
wield_image = "frost_land_pink_firefly.png^default_invisible_node_overlay.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
pointable = false,
|
||||
diggable = false,
|
||||
buildable_to = true,
|
||||
drop = "",
|
||||
groups = {not_in_creative_inventory = 1},
|
||||
floodable = true,
|
||||
on_place = function(itemstack, placer, pointed_thing)
|
||||
local player_name = placer:get_player_name()
|
||||
local pos = pointed_thing.above
|
||||
|
||||
if not minetest.is_protected(pos, player_name) and
|
||||
not minetest.is_protected(pointed_thing.under, player_name) and
|
||||
minetest.get_node(pos).name == "air" then
|
||||
minetest.set_node(pos, {name = "frost_land:hidden_pink_firefly"})
|
||||
minetest.get_node_timer(pos):start(1)
|
||||
itemstack:take_item()
|
||||
end
|
||||
return itemstack
|
||||
end,
|
||||
on_timer = function(pos, elapsed)
|
||||
if minetest.get_node_light(pos) <= 11 then
|
||||
minetest.set_node(pos, {name = "frost_land:pink_firefly"})
|
||||
end
|
||||
minetest.get_node_timer(pos):start(30)
|
||||
end
|
||||
})
|
||||
|
||||
-------------------------------------------------------------------------------------------------------------------------------
|
||||
minetest.register_node("frost_land:cyan_firefly", {
|
||||
description = "Cyan Firefly",
|
||||
drawtype = "plantlike",
|
||||
tiles = {{
|
||||
name = "frost_land_cyan_firefly_animated.png",
|
||||
animation = {
|
||||
type = "vertical_frames",
|
||||
aspect_w = 16,
|
||||
aspect_h = 16,
|
||||
length = 1.5
|
||||
},
|
||||
}},
|
||||
inventory_image = "frost_land_cyan_firefly.png",
|
||||
wield_image = "frost_land_cyan_firefly.png",
|
||||
waving = 1,
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
buildable_to = true,
|
||||
walkable = false,
|
||||
groups = {catchable = 1},
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-0.1, -0.1, -0.1, 0.1, 0.1, 0.1},
|
||||
},
|
||||
light_source = 6,
|
||||
floodable = true,
|
||||
on_place = function(itemstack, placer, pointed_thing)
|
||||
local player_name = placer:get_player_name()
|
||||
local pos = pointed_thing.above
|
||||
|
||||
if not minetest.is_protected(pos, player_name) and
|
||||
not minetest.is_protected(pointed_thing.under, player_name) and
|
||||
minetest.get_node(pos).name == "air" then
|
||||
minetest.set_node(pos, {name = "frost_land:cyan_firefly"})
|
||||
minetest.get_node_timer(pos):start(1)
|
||||
itemstack:take_item()
|
||||
end
|
||||
return itemstack
|
||||
end,
|
||||
on_timer = function(pos, elapsed)
|
||||
if minetest.get_node_light(pos) > 11 then
|
||||
minetest.set_node(pos, {name = "frost_land:hidden_cyan_firefly"})
|
||||
end
|
||||
minetest.get_node_timer(pos):start(30)
|
||||
end
|
||||
})
|
||||
|
||||
minetest.register_node("frost_land:hidden_cyan_firefly", {
|
||||
description = "Hidden Cyan Firefly",
|
||||
drawtype = "airlike",
|
||||
inventory_image = "frost_land_cyan_firefly.png^default_invisible_node_overlay.png",
|
||||
wield_image = "frost_land_cyan_firefly.png^default_invisible_node_overlay.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
pointable = false,
|
||||
diggable = false,
|
||||
buildable_to = true,
|
||||
drop = "",
|
||||
groups = {not_in_creative_inventory = 1},
|
||||
floodable = true,
|
||||
on_place = function(itemstack, placer, pointed_thing)
|
||||
local player_name = placer:get_player_name()
|
||||
local pos = pointed_thing.above
|
||||
|
||||
if not minetest.is_protected(pos, player_name) and
|
||||
not minetest.is_protected(pointed_thing.under, player_name) and
|
||||
minetest.get_node(pos).name == "air" then
|
||||
minetest.set_node(pos, {name = "frost_land:hidden_cyan_firefly"})
|
||||
minetest.get_node_timer(pos):start(1)
|
||||
itemstack:take_item()
|
||||
end
|
||||
return itemstack
|
||||
end,
|
||||
on_timer = function(pos, elapsed)
|
||||
if minetest.get_node_light(pos) <= 11 then
|
||||
minetest.set_node(pos, {name = "frost_land:cyan_firefly"})
|
||||
end
|
||||
minetest.get_node_timer(pos):start(30)
|
||||
end
|
||||
})
|
||||
|
||||
------------------------------------------------------------------------------------------------------------------------------
|
||||
minetest.register_node("frost_land:white_firefly", {
|
||||
description = "White Firefly",
|
||||
drawtype = "plantlike",
|
||||
tiles = {{
|
||||
name = "frost_land_white_firefly_animated.png",
|
||||
animation = {
|
||||
type = "vertical_frames",
|
||||
aspect_w = 16,
|
||||
aspect_h = 16,
|
||||
length = 1.5
|
||||
},
|
||||
}},
|
||||
inventory_image = "frost_land_white_firefly.png",
|
||||
wield_image = "frost_land_white_firefly.png",
|
||||
waving = 1,
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
buildable_to = true,
|
||||
walkable = false,
|
||||
groups = {catchable = 1},
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-0.1, -0.1, -0.1, 0.1, 0.1, 0.1},
|
||||
},
|
||||
light_source = 6,
|
||||
floodable = true,
|
||||
on_place = function(itemstack, placer, pointed_thing)
|
||||
local player_name = placer:get_player_name()
|
||||
local pos = pointed_thing.above
|
||||
|
||||
if not minetest.is_protected(pos, player_name) and
|
||||
not minetest.is_protected(pointed_thing.under, player_name) and
|
||||
minetest.get_node(pos).name == "air" then
|
||||
minetest.set_node(pos, {name = "frost_land:white_firefly"})
|
||||
minetest.get_node_timer(pos):start(1)
|
||||
itemstack:take_item()
|
||||
end
|
||||
return itemstack
|
||||
end,
|
||||
on_timer = function(pos, elapsed)
|
||||
if minetest.get_node_light(pos) > 11 then
|
||||
minetest.set_node(pos, {name = "frost_land:hidden_white_firefly"})
|
||||
end
|
||||
minetest.get_node_timer(pos):start(30)
|
||||
end
|
||||
})
|
||||
|
||||
minetest.register_node("frost_land:hidden_white_firefly", {
|
||||
description = "Hidden White Firefly",
|
||||
drawtype = "airlike",
|
||||
inventory_image = "frost_land_white_firefly.png^default_invisible_node_overlay.png",
|
||||
wield_image = "frost_land_white_firefly.png^default_invisible_node_overlay.png",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
pointable = false,
|
||||
diggable = false,
|
||||
buildable_to = true,
|
||||
drop = "",
|
||||
groups = {not_in_creative_inventory = 1},
|
||||
floodable = true,
|
||||
on_place = function(itemstack, placer, pointed_thing)
|
||||
local player_name = placer:get_player_name()
|
||||
local pos = pointed_thing.above
|
||||
|
||||
if not minetest.is_protected(pos, player_name) and
|
||||
not minetest.is_protected(pointed_thing.under, player_name) and
|
||||
minetest.get_node(pos).name == "air" then
|
||||
minetest.set_node(pos, {name = "frost_land:hidden_white_firefly"})
|
||||
minetest.get_node_timer(pos):start(1)
|
||||
itemstack:take_item()
|
||||
end
|
||||
return itemstack
|
||||
end,
|
||||
on_timer = function(pos, elapsed)
|
||||
if minetest.get_node_light(pos) <= 11 then
|
||||
minetest.set_node(pos, {name = "frost_land:white_firefly"})
|
||||
end
|
||||
minetest.get_node_timer(pos):start(30)
|
||||
end
|
||||
})
|
||||
|
||||
minetest.register_decoration({
|
||||
deco_type = "simple",
|
||||
place_on = {"default:snow"},
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.02,
|
||||
biomes = {"frost_land"},
|
||||
decoration = {
|
||||
"frost_land:white_firefly", "frost_land:cyan_firefly", "frost_land:blue_firefly", "frost_land:pink_firefly",
|
||||
}
|
||||
})
|
BIN
mods/biomes/frost_land/frost_land.png
Normal file
After Width: | Height: | Size: 1 MiB |
7
mods/biomes/frost_land/init.lua
Normal file
|
@ -0,0 +1,7 @@
|
|||
local default_path = minetest.get_modpath("frost_land")
|
||||
|
||||
dofile(default_path.."/nodes.lua")
|
||||
dofile(default_path.."/mapgen.lua")
|
||||
--dofile(default_path.."/fireflies.lua")
|
||||
dofile(default_path.."/moreblocks.lua")
|
||||
dofile(default_path.."/crafting.lua")
|
18
mods/biomes/frost_land/license.txt
Normal file
|
@ -0,0 +1,18 @@
|
|||
License
|
||||
------------------------------------------------------------------------------------------------------------------------
|
||||
Copyright (C) 2021-2022: Atlante - AFL-1.1
|
||||
License for code: AFL-1.1
|
||||
|
||||
Attribution — You must give appropriate credit, provide a link to the license, and
|
||||
indicate if changes were made. You may do so in any reasonable manner, but not in any way
|
||||
that suggests the licensor endorses you or your use.
|
||||
|
||||
ShareAlike — If you remix, transform, or build upon the material, you must distribute
|
||||
your contributions under the same license as the original.
|
||||
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
|
||||
Anyone can fix the mod. My Discord "Atlante#1952" And my Mail Address "AtlanteEtDocteur@gmail.com"
|
||||
|
||||
|
158
mods/biomes/frost_land/mapgen.lua
Normal file
|
@ -0,0 +1,158 @@
|
|||
-- Frost Land
|
||||
|
||||
minetest.register_biome(asuna.biomes.frost_land.generate_definition())
|
||||
|
||||
minetest.register_decoration({
|
||||
name = "frost_land:frost_tree_1",
|
||||
deco_type = "schematic",
|
||||
place_on = {"frost_land:frost_land_grass"},
|
||||
place_offset_y = 0,
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.001265,
|
||||
biomes = {"frost_land"},
|
||||
y_max = 31000,
|
||||
y_min = -20,
|
||||
schematic = minetest.get_modpath("frost_land").."/schematics/frost_tree_1.mts",
|
||||
flags = "place_center_x, place_center_z",
|
||||
rotation = "random",
|
||||
})
|
||||
|
||||
minetest.register_decoration({
|
||||
name = "frost_land:frost_tree_2",
|
||||
deco_type = "schematic",
|
||||
place_on = {"frost_land:frost_land_grass"},
|
||||
place_offset_y = 0,
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.001265,
|
||||
biomes = {"frost_land"},
|
||||
y_max = 31000,
|
||||
y_min = -20,
|
||||
schematic = minetest.get_modpath("frost_land").."/schematics/frost_tree_2.mts",
|
||||
flags = "place_center_x, place_center_z",
|
||||
rotation = "random",
|
||||
})
|
||||
|
||||
minetest.register_decoration({
|
||||
name = "frost_land:frost_tree_3",
|
||||
deco_type = "schematic",
|
||||
place_on = {"frost_land:frost_land_grass"},
|
||||
place_offset_y = 0,
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.001265,
|
||||
biomes = {"frost_land"},
|
||||
y_max = 31000,
|
||||
y_min = -20,
|
||||
schematic = minetest.get_modpath("frost_land").."/schematics/frost_tree_3.mts",
|
||||
flags = "place_center_x, place_center_z",
|
||||
rotation = "random",
|
||||
})
|
||||
|
||||
|
||||
|
||||
minetest.register_decoration({
|
||||
name = "frost_land:ice_1",
|
||||
deco_type = "schematic",
|
||||
place_on = {"frost_land:frost_land_grass"},
|
||||
place_offset_y = 0,
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.002265,
|
||||
biomes = {"frost_land"},
|
||||
y_max = 31000,
|
||||
y_min = -20,
|
||||
schematic = minetest.get_modpath("frost_land").."/schematics/ice_1.mts",
|
||||
flags = "place_center_x, place_center_z",
|
||||
rotation = "random",
|
||||
})
|
||||
|
||||
minetest.register_decoration({
|
||||
name = "frost_land:ice_2",
|
||||
deco_type = "schematic",
|
||||
place_on = {"frost_land:frost_land_grass"},
|
||||
place_offset_y = 0,
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.002265,
|
||||
biomes = {"frost_land"},
|
||||
y_max = 31000,
|
||||
y_min = -20,
|
||||
schematic = minetest.get_modpath("frost_land").."/schematics/ice_2.mts",
|
||||
flags = "place_center_x, place_center_z",
|
||||
rotation = "random",
|
||||
})
|
||||
|
||||
minetest.register_decoration({
|
||||
name = "frost_land:ice_3",
|
||||
deco_type = "schematic",
|
||||
place_on = {"frost_land:frost_land_grass"},
|
||||
place_offset_y = 0,
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.002265,
|
||||
biomes = {"frost_land"},
|
||||
y_max = 31000,
|
||||
y_min = -20,
|
||||
schematic = minetest.get_modpath("frost_land").."/schematics/ice_3.mts",
|
||||
flags = "place_center_x, place_center_z",
|
||||
rotation = "random",
|
||||
})
|
||||
|
||||
minetest.register_decoration({
|
||||
name = "frost_land:tree_4",
|
||||
deco_type = "schematic",
|
||||
place_on = {"frost_land:frost_land_grass"},
|
||||
place_offset_y = 0,
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.002265,
|
||||
biomes = {"frost_land"},
|
||||
y_max = 31000,
|
||||
y_min = -20,
|
||||
schematic = minetest.get_modpath("frost_land").."/schematics/tree_4.mts",
|
||||
flags = "place_center_x, place_center_z",
|
||||
rotation = "random",
|
||||
})
|
||||
|
||||
minetest.register_decoration({
|
||||
name = "frost_land:tree_5",
|
||||
deco_type = "schematic",
|
||||
place_on = {"frost_land:frost_land_grass"},
|
||||
place_offset_y = 0,
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.002265,
|
||||
biomes = {"frost_land"},
|
||||
y_max = 31000,
|
||||
y_min = -20,
|
||||
schematic = minetest.get_modpath("frost_land").."/schematics/tree_5.mts",
|
||||
flags = "place_center_x, place_center_z",
|
||||
rotation = "random",
|
||||
})
|
||||
|
||||
minetest.register_decoration({
|
||||
name = "frost_land:igloo",
|
||||
deco_type = "schematic",
|
||||
place_on = {"frost_land:frost_land_grass"},
|
||||
place_offset_y = -2,
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.000165,
|
||||
biomes = {"frost_land"},
|
||||
y_max = 31000,
|
||||
y_min = -20,
|
||||
schematic = minetest.get_modpath("frost_land").."/schematics/igloo.mts",
|
||||
flags = "place_center_x, place_center_z",
|
||||
rotation = "random",
|
||||
})
|
||||
|
||||
minetest.register_decoration({
|
||||
name = "frost_land:bush",
|
||||
deco_type = "schematic",
|
||||
place_on = {"frost_land:frost_land_grass"},
|
||||
place_offset_y = 0,
|
||||
sidelen = 16,
|
||||
fill_ratio = 0.002165,
|
||||
biomes = {"frost_land"},
|
||||
y_max = 31000,
|
||||
y_min = -20,
|
||||
schematic = minetest.get_modpath("frost_land").."/schematics/bush.mts",
|
||||
flags = "place_center_x, place_center_z",
|
||||
rotation = "random",
|
||||
})
|
||||
|
||||
|
||||
|
8
mods/biomes/frost_land/mod.conf
Normal file
|
@ -0,0 +1,8 @@
|
|||
|
||||
author = Atlante
|
||||
name = frost_land
|
||||
|
||||
description = Adds a frost_land biome with a few more objects.
|
||||
title = Frost Land
|
||||
depends = default
|
||||
optional_depends = moreblocks, bonemeal
|
21
mods/biomes/frost_land/moreblocks.lua
Normal file
|
@ -0,0 +1,21 @@
|
|||
-----------------Moreblock
|
||||
if minetest.get_modpath("moreblocks") then
|
||||
|
||||
stairsplus:register_all("frost_land_wood", "wood", "frost_land:frost_land_wood", {
|
||||
description = "Frost Land Wood",
|
||||
tiles = {"frost_land_wood.png"},
|
||||
groups = {choppy = 3, oddly_breakable_by_hand = 2, flammable = 3, wood = 1},
|
||||
sounds = default.node_sound_wood_defaults(),
|
||||
})
|
||||
|
||||
stairsplus:register_all("frost_land_tree", "tree", "frost_land:frost_land_tree", {
|
||||
description = "Japanese Tree",
|
||||
tiles = {"frost_land_tree_top.png", "frost_land_tree_top.png",
|
||||
"frost_land_tree.png"},
|
||||
groups = {choppy = 3, oddly_breakable_by_hand = 2, flammable = 3, wood = 1},
|
||||
sounds = default.node_sound_wood_defaults(),
|
||||
})
|
||||
|
||||
|
||||
|
||||
end
|
210
mods/biomes/frost_land/nodes.lua
Normal file
|
@ -0,0 +1,210 @@
|
|||
local modpath = minetest.get_modpath("frost_land")
|
||||
|
||||
minetest.register_node("frost_land:frost_land_grass", {
|
||||
description = "Frost Land Grass",
|
||||
tiles = {"frost_land_grass.png", "default_dirt.png",
|
||||
{name = "default_dirt.png^frost_land_grass_side.png",
|
||||
tileable_vertical = false}},
|
||||
groups = {crumbly = 3, soil = 1, spreading_dirt_type = 1},
|
||||
drop = "default:dirt",
|
||||
sounds = default.node_sound_dirt_defaults({
|
||||
footstep = {name = "default_snow_footstep", gain = 0.25},
|
||||
}),
|
||||
})
|
||||
|
||||
minetest.register_node("frost_land:frost_land_wood", {
|
||||
description = "Frost Land Wood",
|
||||
paramtype2 = "facedir",
|
||||
place_param2 = 0,
|
||||
tiles = {"frost_land_wood.png"},
|
||||
is_ground_content = false,
|
||||
groups = {choppy = 2, oddly_breakable_by_hand = 2, flammable = 2, wood = 1},
|
||||
sounds = default.node_sound_wood_defaults(),
|
||||
})
|
||||
|
||||
minetest.register_node("frost_land:frost_land_tree", {
|
||||
description = "Frost Land Tree",
|
||||
tiles = {"frost_land_tree_top.png", "frost_land_tree_top.png",
|
||||
"frost_land_tree.png"},
|
||||
paramtype2 = "facedir",
|
||||
is_ground_content = false,
|
||||
groups = {tree = 1, choppy = 2, oddly_breakable_by_hand = 1, flammable = 2},
|
||||
sounds = default.node_sound_wood_defaults(),
|
||||
|
||||
on_place = minetest.rotate_node
|
||||
})
|
||||
|
||||
doors.register_trapdoor("frost_land:frost_land_trapdoor", {
|
||||
description = "Frost Land Trapdoor",
|
||||
inventory_image = "frost_land_trapdoor.png",
|
||||
wield_image = "frost_land_trapdoor.png",
|
||||
tile_front = "frost_land_trapdoor.png",
|
||||
tile_side = "frost_land_trapdoor_side.png",
|
||||
gain_open = 0.06,
|
||||
gain_close = 0.13,
|
||||
groups = {choppy = 2, oddly_breakable_by_hand = 2, flammable = 2, door = 1},
|
||||
})
|
||||
|
||||
|
||||
doors.register("frost_land_door", {
|
||||
tiles = {{ name = "doors_frost_land_door.png", backface_culling = true }},
|
||||
description = "Frost Land Door",
|
||||
inventory_image = "doors_item_frost_land.png",
|
||||
groups = {node = 1, choppy = 2, oddly_breakable_by_hand = 2, flammable = 2},
|
||||
gain_open = 0.06,
|
||||
gain_close = 0.13,
|
||||
recipe = {
|
||||
{"frost_land:frost_land_wood", "frost_land:frost_land_wood"},
|
||||
{"frost_land:frost_land_wood", "frost_land:frost_land_wood"},
|
||||
{"frost_land:frost_land_wood", "frost_land:frost_land_wood"},
|
||||
}
|
||||
})
|
||||
|
||||
stairs.register_stair_and_slab(
|
||||
"frost_land_wood",
|
||||
"frost_land:frost_land_wood",
|
||||
{choppy = 2, oddly_breakable_by_hand = 2, flammable = 2},
|
||||
{"frost_land_wood.png"},
|
||||
"Frost Land Wood Stair",
|
||||
"Frost Land Wood Slab",
|
||||
default.node_sound_wood_defaults(),
|
||||
true
|
||||
)
|
||||
|
||||
doors.register_fencegate("frost_land:gate_frost_land", {
|
||||
description = "Frost Land Wood Fence Gate",
|
||||
texture = "frost_land_wood.png",
|
||||
material = "frost_land:frost_land_wood",
|
||||
groups = {choppy = 2, oddly_breakable_by_hand = 2, flammable = 2}
|
||||
})
|
||||
|
||||
default.register_fence("frost_land:fence_frost_land_wood", {
|
||||
description = "Frost Land Wood Fence",
|
||||
texture = "frost_land_wood.png",
|
||||
inventory_image = "frost_land_fence_overlay.png^frost_land_wood.png^" ..
|
||||
"frost_land_fence_overlay.png^[makealpha:255,126,126",
|
||||
wield_image = "frost_land_fence_overlay.png^frost_land_wood.png^" ..
|
||||
"frost_land_fence_overlay.png^[makealpha:255,126,126",
|
||||
material = "frost_land:frost_land_wood",
|
||||
groups = {choppy = 3, oddly_breakable_by_hand = 2, flammable = 3},
|
||||
sounds = default.node_sound_wood_defaults()
|
||||
})
|
||||
|
||||
default.register_fence_rail("frost_land:fence_rail_frost_land_wood", {
|
||||
description = "Frost Land Wood Fence Rail",
|
||||
texture = "frost_land_wood.png",
|
||||
inventory_image = "frost_land_fence_rail_overlay.png^frost_land_wood.png^" ..
|
||||
"frost_land_fence_rail_overlay.png^[makealpha:255,126,126",
|
||||
wield_image = "frost_land_fence_rail_overlay.png^frost_land_wood.png^" ..
|
||||
"frost_land_fence_rail_overlay.png^[makealpha:255,126,126",
|
||||
material = "frost_land:frost_land_wood",
|
||||
groups = {choppy = 3, oddly_breakable_by_hand = 2, flammable = 3},
|
||||
sounds = default.node_sound_wood_defaults()
|
||||
})
|
||||
|
||||
--[[
|
||||
Trees
|
||||
]]
|
||||
|
||||
local trees = {
|
||||
{
|
||||
name = "Frigid",
|
||||
grow_function = function(pos)
|
||||
minetest.remove_node(pos)
|
||||
minetest.place_schematic({x = pos.x-3, y = pos.y, z = pos.z-3}, modpath.."/schematics/frost_tree_1.mts", "random", nil, false)
|
||||
end,
|
||||
},
|
||||
{
|
||||
name = "Icy",
|
||||
grow_function = function(pos)
|
||||
minetest.remove_node(pos)
|
||||
minetest.place_schematic({x = pos.x-4, y = pos.y, z = pos.z-4}, modpath.."/schematics/tree_4.mts", "random", nil, false)
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
||||
for index,def in ipairs(trees) do
|
||||
local sapling = "frost_land:frost_land_sapling_" .. index
|
||||
local image = "frost_land_sapling_" .. index .. ".png"
|
||||
local leaves = "frost_land:frost_land_leaves_" .. index
|
||||
|
||||
-- Register leaves
|
||||
minetest.register_node("frost_land:frost_land_leaves_" .. index, {
|
||||
description = def.name .. " Frost Land Leaves",
|
||||
drawtype = "allfaces_optional",
|
||||
waving = 1,
|
||||
tiles = {"frost_leaves_" .. index .. ".png"},
|
||||
paramtype = "light",
|
||||
is_ground_content = false,
|
||||
groups = {snappy = 3, leafdecay = 3, flammable = 2, leaves = 1},
|
||||
drop = {
|
||||
max_items = 1,
|
||||
items = {
|
||||
{items = {sapling}, rarity = 20},
|
||||
{items = {leaves}}
|
||||
}
|
||||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
|
||||
after_place_node = default.after_place_leaves,
|
||||
})
|
||||
|
||||
-- Register sapling
|
||||
minetest.register_node(sapling, {
|
||||
description = def.name .. " Frost Land Sapling",
|
||||
drawtype = "plantlike",
|
||||
tiles = {image},
|
||||
inventory_image = image,
|
||||
wield_image = image,
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
on_timer = function(pos)
|
||||
if not default.can_grow(pos) then
|
||||
-- try a bit later again
|
||||
minetest.get_node_timer(pos):start(math.random(240, 600))
|
||||
else
|
||||
def.grow_function(pos)
|
||||
end
|
||||
end,
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-4 / 16, -0.5, -4 / 16, 4 / 16, 2 / 16, 4 / 16}
|
||||
},
|
||||
groups = {snappy = 2, dig_immediate = 3, flammable = 2,
|
||||
attached_node = 1, sapling = 1},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
|
||||
on_construct = function(pos)
|
||||
minetest.get_node_timer(pos):start(math.random(300, 1500))
|
||||
end,
|
||||
|
||||
on_place = function(itemstack, placer, pointed_thing)
|
||||
itemstack = default.sapling_on_place(itemstack, placer, pointed_thing,
|
||||
sapling,
|
||||
-- minp, maxp to be checked, relative to sapling pos
|
||||
{x = -1, y = 0, z = -1},
|
||||
{x = 1, y = 1, z = 1},
|
||||
-- maximum interval of interior volume check
|
||||
2)
|
||||
|
||||
return itemstack
|
||||
end,
|
||||
})
|
||||
|
||||
-- Register sapling crafting recipe
|
||||
minetest.register_craft({
|
||||
output = sapling,
|
||||
recipe = {
|
||||
{"", leaves, ""},
|
||||
{leaves, "default:stick", leaves}
|
||||
},
|
||||
})
|
||||
|
||||
-- Add bonemeal integration if supported
|
||||
if minetest.get_modpath("bonemeal") ~= nil then
|
||||
bonemeal:add_sapling({
|
||||
{sapling, def.grow_function, "soil"},
|
||||
})
|
||||
end
|
||||
end
|
BIN
mods/biomes/frost_land/schematics/bush.mts
Normal file
BIN
mods/biomes/frost_land/schematics/frost_tree_1.mts
Normal file
BIN
mods/biomes/frost_land/schematics/frost_tree_2.mts
Normal file
BIN
mods/biomes/frost_land/schematics/frost_tree_3.mts
Normal file
BIN
mods/biomes/frost_land/schematics/ice_1.mts
Normal file
BIN
mods/biomes/frost_land/schematics/ice_2.mts
Normal file
BIN
mods/biomes/frost_land/schematics/ice_3.mts
Normal file
BIN
mods/biomes/frost_land/schematics/igloo.mts
Normal file
BIN
mods/biomes/frost_land/schematics/tree_4.mts
Normal file
BIN
mods/biomes/frost_land/schematics/tree_5.mts
Normal file
BIN
mods/biomes/frost_land/textures/doors_frost_land_door.png
Normal file
After Width: | Height: | Size: 1.7 KiB |
BIN
mods/biomes/frost_land/textures/doors_item_frost_land.png
Normal file
After Width: | Height: | Size: 499 B |
BIN
mods/biomes/frost_land/textures/frost_land_blue_firefly.png
Normal file
After Width: | Height: | Size: 5 KiB |
After Width: | Height: | Size: 5.4 KiB |
BIN
mods/biomes/frost_land/textures/frost_land_cyan_firefly.png
Normal file
After Width: | Height: | Size: 5.4 KiB |
After Width: | Height: | Size: 6 KiB |
BIN
mods/biomes/frost_land/textures/frost_land_fence_overlay.png
Normal file
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 4.8 KiB |
BIN
mods/biomes/frost_land/textures/frost_land_grass.png
Normal file
After Width: | Height: | Size: 5.5 KiB |
BIN
mods/biomes/frost_land/textures/frost_land_grass_side.png
Normal file
After Width: | Height: | Size: 5.4 KiB |
BIN
mods/biomes/frost_land/textures/frost_land_pink_firefly.png
Normal file
After Width: | Height: | Size: 5.4 KiB |
After Width: | Height: | Size: 5.9 KiB |
BIN
mods/biomes/frost_land/textures/frost_land_sapling.png
Normal file
After Width: | Height: | Size: 5.9 KiB |
BIN
mods/biomes/frost_land/textures/frost_land_sapling_1.png
Normal file
After Width: | Height: | Size: 5.9 KiB |
BIN
mods/biomes/frost_land/textures/frost_land_sapling_2.png
Normal file
After Width: | Height: | Size: 290 B |
BIN
mods/biomes/frost_land/textures/frost_land_trapdoor.png
Normal file
After Width: | Height: | Size: 533 B |
BIN
mods/biomes/frost_land/textures/frost_land_trapdoor_side.png
Normal file
After Width: | Height: | Size: 106 B |
BIN
mods/biomes/frost_land/textures/frost_land_tree.png
Normal file
After Width: | Height: | Size: 6.4 KiB |
BIN
mods/biomes/frost_land/textures/frost_land_tree_top.png
Normal file
After Width: | Height: | Size: 6 KiB |
BIN
mods/biomes/frost_land/textures/frost_land_white_firefly.png
Normal file
After Width: | Height: | Size: 4.9 KiB |
After Width: | Height: | Size: 5.2 KiB |
BIN
mods/biomes/frost_land/textures/frost_land_wood.png
Normal file
After Width: | Height: | Size: 6 KiB |
BIN
mods/biomes/frost_land/textures/frost_leaves_1.png
Normal file
After Width: | Height: | Size: 6.4 KiB |
BIN
mods/biomes/frost_land/textures/frost_leaves_2.png
Normal file
After Width: | Height: | Size: 6.1 KiB |