},
top = {
"beds_bed_top_top.png^[transformR90",
- "default_wood.png",
+ "default_wood.png",
"beds_bed_side_top_r.png",
"beds_bed_side_top_r.png^[transformfx",
"beds_bed_side_top.png",
-- Callbacks
-- Only register respawn callback if respawn enabled
-if enable_respawn then
+if enable_respawn then
-- respawn player at bed if enabled and valid position is found
minetest.register_on_respawnplayer(function(player)
local name = player:get_player_name()
--
local function active_formspec(fuel_percent, item_percent)
- local formspec =
+ local formspec =
"size[8,8.5]"..
default.gui_bg..
default.gui_bg_img..
default.player_attached[player:get_player_name()] = false
default.player_set_model(player, "character.b3d")
player:set_local_animation({x=0, y=79}, {x=168, y=187}, {x=189, y=198}, {x=200, y=219}, 30)
-
+
-- set GUI
if not minetest.setting_getbool("creative_mode") then
player:set_inventory_formspec(default.gui_survival_form)
if not name:find(":") then
name = "doors:" .. name
end
-
+
local name_closed = name
local name_opened = name.."_open"
end
local nn_def = minetest.registered_nodes[nn.name] or nil
pos.y = pos.y - 1
-
+
if nn_def and nn_def.walkable and minetest.get_item_group(nn.name, "plant") == 0 then
minetest.set_node(pos, {name = base})
return
if minetest.get_item_group(nn.name, "plant") == 0 and minetest.get_item_group(nn.name, "seed") == 0 then
minetest.set_node(pos, {name = base})
end
-
+
-- if its wet turn it back into dry soil
elseif wet_lvl == 1 then
minetest.set_node(pos, {name = dry})
})
-for i = 1, 5 do
+for i = 1, 5 do
minetest.override_item("default:grass_"..i, {drop = {
max_items = 1,
items = {
}
}})
end
-
+
minetest.override_item("default:junglegrass", {drop = {
max_items = 1,
items = {
sethome.get = function(name)
local pos = homepos[name]
if pos then
- return vector.new(pos)
+ return vector.new(pos)
else
- return nil
+ return nil
end
end