2019-04-29 01:36:06 +02:00
|
|
|
--[[
|
|
|
|
**********************************************
|
|
|
|
*** Flex default ***
|
|
|
|
**********************************************
|
|
|
|
]]--
|
|
|
|
|
|
|
|
-- Load support for intllib.
|
2019-11-21 17:24:41 +01:00
|
|
|
local S = cucina_vegana.get_translator
|
2019-04-29 01:36:06 +02:00
|
|
|
|
|
|
|
local dname = S("Flax")
|
|
|
|
local pname = "flax"
|
|
|
|
local step = 6
|
|
|
|
|
|
|
|
-- flex
|
|
|
|
farming.register_plant("cucina_vegana:" .. pname, {
|
|
|
|
description = dname .. " " .. S("Seed"),
|
|
|
|
inventory_image = "cucina_vegana_" .. pname .. "_seed.png",
|
|
|
|
steps = step,
|
2019-07-02 21:38:03 +02:00
|
|
|
minlight = cucina_vegana.plant_settings.flax_light,
|
2019-04-29 01:36:06 +02:00
|
|
|
fertility = {"grassland"},
|
2019-06-03 19:35:14 +02:00
|
|
|
groups = {flammable = 4, attached_node = 1},
|
2019-04-29 01:36:06 +02:00
|
|
|
})
|
|
|
|
|
|
|
|
-- Register for Mapgen
|
|
|
|
minetest.register_node("cucina_vegana:wild_" .. pname, {
|
|
|
|
description = S("Wild") .. " " .. dname,
|
|
|
|
paramtype = "light",
|
|
|
|
walkable = false,
|
2019-07-16 22:59:13 +02:00
|
|
|
drop = {
|
|
|
|
items = {
|
2019-04-29 01:36:06 +02:00
|
|
|
{items = {"cucina_vegana:seed_" .. pname .. " 4"}},
|
2019-11-20 21:15:58 +01:00
|
|
|
{items = {"cucina_vegana:" .. pname .. " 2"}},
|
2019-04-29 01:36:06 +02:00
|
|
|
}
|
|
|
|
},
|
|
|
|
drawtype = "plantlike",
|
|
|
|
paramtype2 = "facedir",
|
|
|
|
sunlight_propagates = true,
|
|
|
|
tiles = {"cucina_vegana_" .. pname .. "_" .. step .. ".png"},
|
2019-06-03 19:35:14 +02:00
|
|
|
groups = {snappy = 3, dig_immediate=1, flammable=2, plant=1, attached_node = 1, growing = 1},
|
2019-04-29 01:36:06 +02:00
|
|
|
sounds = default.node_sound_leaves_defaults(),
|
|
|
|
selection_box = {
|
|
|
|
type = "fixed",
|
|
|
|
fixed = {
|
|
|
|
{-0.5, -0.5, -0.5, 0.5, -0.35, 0.5}, -- side f
|
|
|
|
},
|
|
|
|
},
|
|
|
|
})
|
|
|
|
|
2019-08-28 22:44:21 +02:00
|
|
|
cucina_vegana.add_group("cucina_vegana:seed_" .. pname, {seed_flax = 1})
|
2019-06-13 01:44:28 +02:00
|
|
|
|
2019-07-02 21:38:03 +02:00
|
|
|
if(cucina_vegana.plant_settings.bonemeal) then
|
2019-07-16 23:56:14 +02:00
|
|
|
table.insert(cucina_vegana.plant_settings.bonemeal_list,
|
|
|
|
{"cucina_vegana:" .. pname .. "_", step, "cucina_vegana:seed_" .. pname})
|
2019-07-16 22:59:13 +02:00
|
|
|
|
2019-07-02 21:38:03 +02:00
|
|
|
end -- if(cucina_vegana.plant_settings.bonemeal
|
2019-05-01 18:05:53 +02:00
|
|
|
|
2020-03-04 21:18:20 +01:00
|
|
|
-- Register @ farming_nextgen
|
|
|
|
if cucina_vegana.farming_ng then
|
|
|
|
cucina_vegana.register_farming_ng(pname, step)
|
2019-07-16 22:59:13 +02:00
|
|
|
|
2020-03-04 21:18:20 +01:00
|
|
|
end -- if(cucina_vegana.farming_ng
|
2019-04-29 01:36:06 +02:00
|
|
|
|
|
|
|
minetest.register_alias("cucina_vegana:flex_1", "cucina_vegana:" .. pname .. "_1")
|
|
|
|
minetest.register_alias("cucina_vegana:flex_2", "cucina_vegana:" .. pname .. "_2")
|
|
|
|
minetest.register_alias("cucina_vegana:flex_3", "cucina_vegana:" .. pname .. "_3")
|
|
|
|
minetest.register_alias("cucina_vegana:flex_4", "cucina_vegana:" .. pname .. "_4")
|
|
|
|
minetest.register_alias("cucina_vegana:flex_5", "cucina_vegana:" .. pname .. "_5")
|
|
|
|
minetest.register_alias("cucina_vegana:flex_6", "cucina_vegana:" .. pname .. "_" .. step)
|
|
|
|
minetest.register_alias("cucina_vegana:wild_flex", "cucina_vegana:wild_" .. pname)
|
|
|
|
minetest.register_alias("cucina_vegana:seed_flex", "cucina_vegana:seed_" .. pname)
|
2019-11-20 21:15:58 +01:00
|
|
|
minetest.register_alias("cucina_vegana:flex_raw", "cucina_vegana:" .. pname)
|