added new flowers

master
crazyginger72 2014-07-25 00:35:12 -04:00
parent 8efd50dece
commit 12321cea8f
18 changed files with 401 additions and 10 deletions

View File

@ -35,20 +35,26 @@ minetest.register_on_generated(function(minp, maxp, seed)
minetest.registered_nodes[nn].buildable_to then
nn = minetest.get_node({x=x,y=ground_y,z=z}).name
if nn == "default:dirt_with_grass" then
local flower_choice = pr:next(1, 6)
local flower_choice = pr:next(1, 110)
local flower
if flower_choice == 1 then
if flower_choice >= 1 and flower_choice <= 25 then
flower = "default:tulip"
elseif flower_choice == 2 then
flower = "default:rose"
elseif flower_choice == 3 then
elseif flower_choice >= 26 and flower_choice <= 32 then
flower = "default:rose_bush"
elseif flower_choice >= 33 and flower_choice <= 36 then
flower = "default:dandelion_yellow"
elseif flower_choice == 4 then
elseif flower_choice >= 37 and flower_choice <= 52 then
flower = "default:dandelion_white"
elseif flower_choice == 5 then
elseif flower_choice >= 53 and flower_choice <= 78 then
flower = "default:geranium"
elseif flower_choice == 6 then
elseif flower_choice >= 79 and flower_choice <= 89 then
flower = "default:viola"
elseif flower_choice >= 90 and flower_choice <= 100 then
flower = "default:dasie"
elseif flower_choice >= 101 and flower_choice <= 105 then
flower = "default:clover"
elseif flower_choice >= 106 and flower_choice <= 110 then
flower = "default:clover_purple"
end
minetest.set_node(p, {name=flower})
end

View File

@ -2,7 +2,7 @@
-- See README.txt for licensing and other information.
-- Map Generation
dofile(minetest.get_modpath("default").."/mapgen.lua")
dofile(minetest.get_modpath("default").."/flowergen.lua")
-- Aliases for original default mod
minetest.register_alias("default:flower_dandelion_white", "default:dandelion_white")
@ -12,6 +12,24 @@ minetest.register_alias("default:flower_rose", "default:rose")
minetest.register_alias("default:flower_tulip", "default:tulip")
minetest.register_alias("default:flower_viola", "default:viola")
minetest.register_node("default:dasie", {
description = "White Dasie",
drawtype = "plantlike",
tiles = { "flowers_dasie.png" },
inventory_image = "flowers_dasie.png",
wield_image = "flowers_dasie.png",
sunlight_propagates = true,
paramtype = "light",
walkable = false,
buildable_to = true,
groups = {snappy=3,flammable=2,flower=1,flora=1,attached_node=1,color_white=1},
sounds = default.node_sound_leaves_defaults(),
selection_box = {
type = "fixed",
fixed = { -0.15, -0.5, -0.15, 0.15, 0.2, 0.15 },
},
})
minetest.register_node("default:dandelion_white", {
description = "White Dandelion",
drawtype = "plantlike",
@ -165,3 +183,366 @@ minetest.register_abm({
end
end,
})
minetest.register_node("default:rose_bush", {
description = "Rosebush",
drawtype = "plantlike",
visual_scale = 1.5,
inventory_image = "gardening_rosebush.png",
wield_image = "gardening_rosebush.png",
tiles = {"gardening_rosebush.png"},
paramtype = "light",
walkable = false,
buildable_to = true,
is_ground_content = true,
groups = {snappy=3,flammable=3,attached_node=1},
sounds = default.node_sound_leaves_defaults(),
selection_box = {
type = "fixed",
fixed = {-0.5, -0.5, -0.5, 0.5, -2.5/16, 0.5},
},
})
minetest.register_craft({
output = 'default:rose_bush 2',
recipe = {
{'default:rose'},
{'default:leaves'},
{'default:rose'},
},
})
minetest.register_node("default:geranium_cluster", {
description = "Geranium cluster",
drawtype = "plantlike",
visual_scale = 1.1,
inventory_image = "gardening_geranium_cluster.png",
wield_image = "gardening_geranium_cluster.png",
tiles = {"gardening_geranium_cluster.png"},
paramtype = "light",
walkable = false,
buildable_to = true,
is_ground_content = true,
groups = {snappy=3,flammable=3,attached_node=1},
sounds = default.node_sound_leaves_defaults(),
selection_box = {
type = "fixed",
fixed = {-0.5, -0.5, -0.5, 0.5, -2.5/16, 0.5},
},
})
minetest.register_craft({
output = 'default:geranium_cluster 2',
recipe = {
{'default:geranium'},
{'default:leaves'},
{'default:geranium'},
},
})
minetest.register_node("default:violas_cluster", {
description = "Violas cluster",
drawtype = "plantlike",
visual_scale = 1.1,
inventory_image = "gardening_violas.png",
wield_image = "gardening_violas.png",
tiles = {"gardening_violas.png"},
paramtype = "light",
walkable = false,
buildable_to = true,
is_ground_content = true,
groups = {snappy=3,flammable=3,attached_node=1},
sounds = default.node_sound_leaves_defaults(),
selection_box = {
type = "fixed",
fixed = {-0.5, -0.5, -0.5, 0.5, -2.5/16, 0.5},
},
})
minetest.register_craft({
output = 'default:violas_cluster 2',
recipe = {
{'default:viola'},
{'default:leaves'},
{'default:viola'},
},
})
minetest.register_node('default:dandelions_cluster', {
description = "Dandelion cluster",
drawtype = "plantlike",
visual_scale = 1.1,
inventory_image = "gardening_dandelions.png",
wield_image = "gardening_dandelions.png",
tiles = {"gardening_dandelions.png"},
paramtype = "light",
walkable = false,
buildable_to = true,
is_ground_content = true,
groups = {snappy=3,flammable=3,attached_node=1},
sounds = default.node_sound_leaves_defaults(),
selection_box = {
type = "fixed",
fixed = {-0.5, -0.5, -0.5, 0.5, -2.5/16, 0.5},
},
})
minetest.register_craft({
output = 'default:dandelions_cluster',
recipe = {
{'default:dandelion_white', 'default:dandelion_white', 'default:dandelion_white'},
{'', 'default:leaves', ''},
{'', '', ''},
},
})
minetest.register_craft({
output = 'default:dandelions_cluster',
recipe = {
{'default:dandelion_yellow', 'default:dandelion_yellow', 'default:dandelion_yellow'},
{'', 'default:leaves', ''},
{'', '', ''},
},
})
minetest.register_craft({
output = 'default:dandelions_cluster',
recipe = {
{'default:dandelion_yellow', 'default:dandelion_white', 'default:dandelion_white'},
{'', 'default:leaves', ''},
{'', '', ''},
},
})
minetest.register_craft({
output = 'default:dandelions_cluster',
recipe = {
{'default:dandelion_yellow', 'default:dandelion_yellow', 'default:dandelion_white'},
{'', 'default:leaves', ''},
{'', '', ''},
},
})
minetest.register_craft({
output = 'default:dandelions_cluster',
recipe = {
{'default:dandelion_white', 'default:dandelion_yellow', 'default:dandelion_white'},
{'', 'default:leaves', ''},
{'', '', ''},
},
})
minetest.register_craft({
output = 'default:dandelions_cluster',
recipe = {
{'default:dandelion_yellow', 'default:dandelion_white', 'default:dandelion_yellow'},
{'', 'default:leaves', ''},
{'', '', ''},
},
})
minetest.register_craft({
output = 'default:dandelions_cluster',
recipe = {
{'default:dandelion_white', 'default:dandelion_white', 'default:dandelion_yellow'},
{'', 'default:leaves', ''},
{'', '', ''},
},
})
minetest.register_craft({
output = 'default:dandelions_cluster',
recipe = {
{'default:dandelion_white', 'default:dandelion_yellow', 'default:dandelion_yellow'},
{'', 'default:leaves', ''},
{'', '', ''},
},
})
minetest.register_node("default:tulip_cluster", {
description = "Tulip cluster",
drawtype = "plantlike",
visual_scale = 1.1,
inventory_image = "gardening_tulip_cluster.png",
wield_image = "gardening_tulip_cluster.png",
tiles = {"gardening_tulip_cluster.png"},
paramtype = "light",
walkable = false,
buildable_to = true,
is_ground_content = true,
groups = {snappy=3,flammable=3,attached_node=1},
sounds = default.node_sound_leaves_defaults(),
selection_box = {
type = "fixed",
fixed = {-0.5, -0.5, -0.5, 0.5, -2.5/16, 0.5},
},
})
minetest.register_craft({
output = 'default:tulip_cluster',
recipe = {
{'default:tulip'},
{'default:leaves'},
{'default:tulip'},
},
})
minetest.register_node("default:dasie_cluster", {
description = "Dasie cluster",
drawtype = "plantlike",
visual_scale = 1.1,
inventory_image = "gardening_dasie_cluster.png",
wield_image = "gardening_dasie_cluster.png",
tiles = {"gardening_dasie_cluster.png"},
paramtype = "light",
walkable = false,
buildable_to = true,
is_ground_content = true,
groups = {snappy=3,flammable=3,attached_node=1},
sounds = default.node_sound_leaves_defaults(),
selection_box = {
type = "fixed",
fixed = {-0.5, -0.5, -0.5, 0.5, -2.5/16, 0.5},
},
})
minetest.register_craft({
output = 'default:dasie_cluster',
recipe = {
{'default:dasie'},
{'default:leaves'},
{'default:dasie'},
},
})
inetest.register_node("default:clover", {
description = "Clover",
drawtype = "nodebox",
tiles = {'clover_top.png', 'default_grass.png', 'clover_side.png',},
paramtype = "light",
buildable_to = true,
walkable = true,
sounds = default.node_sound_dirt_defaults(),
groups = {snappy=1,choppy=2,oddly_breakable_by_hand=2,crumbly=3},
drawtype = "nodebox",
node_box = {
type = "fixed",
fixed = {
{-0.5, -0.5, -0.5, 0.5, -0.375, 0.5}, -- NodeBox1
{0.0625, -0.5, -0.4375, 0.4375, -0.3125, -0.1875}, -- NodeBox2
{-0.25, -0.5, -0.3125, 0.3125, -0.3125, -0.125}, -- NodeBox3
{-0.375, -0.5, 0.125, 0.0625, -0.3125, 0.4375}, -- NodeBox4
{0, -0.5, -0.0625, 0.3125, -0.3125, 0.1875}, -- NodeBox5
{-0.5, -0.5, -0.375, -0.375, -0.3125, 0.0625}, -- NodeBox6
{0.1875, -0.5, 0.3125, 0.4375, -0.3125, 0.4375}, -- NodeBox7
{0.125, -0.25, 0.4375, 0.1875, -0.1875, 0.5}, -- NodeBox8
{-0.375, -0.1875, 0.375, -0.3125, -0.125, 0.4375}, -- NodeBox9
{-0.0625, -0.25, 0.3125, 0, -0.1875, 0.375}, -- NodeBox10
{-0.3125, -0.25, 0.25, -0.25, -0.1875, 0.3125}, -- NodeBox11
{0.3125, -0.1875, 0.1875, 0.375, -0.125, 0.25}, -- NodeBox12
{0.0625, -0.1875, 0.125, 0.125, -0.125, 0.1875}, -- NodeBox13
{-0.5, -0.25, 0.0625, -0.4375, -0.1875, 0.125}, -- NodeBox14
{-0.1875, -0.1875, 0.0625, -0.125, -0.125, 0.125}, -- NodeBox15
{0.125, -0.25, -0.0625, 0.1875, -0.1875, 0}, -- NodeBox16
{0.3125, -0.1875, -0.125, 0.375, -0.125, -0.0625}, -- NodeBox17
{-0.375, -0.25, -0.125, -0.3125, -0.1875, -0.0625}, -- NodeBox18
{-0.125, -0.1875, -0.25, -0.0625, -0.125, -0.1875}, -- NodeBox19
{-0.25, -0.25, -0.3125, -0.1875, -0.1875, -0.25}, -- NodeBox20
{0.0625, -0.1875, -0.3125, 0.125, -0.125, -0.25}, -- NodeBox21
{-0.4375, -0.25, -0.375, -0.375, -0.1875, -0.3125}, -- NodeBox22
{0.375, -0.1875, -0.4375, 0.4375, -0.125, -0.375}, -- NodeBox23
{0.1875, -0.1875, -0.4375, 0.25, -0.125, -0.375}, -- NodeBox24
{-0.1875, -0.25, -0.5, -0.125, -0.1875, -0.4375}, -- NodeBox25
{0.147147, -0.5, 0.459459, 0.165165, -0.25, 0.477477}, -- NodeBox26
{-0.351351, -0.5, 0.387387, -0.333333, -0.1875, 0.405405}, -- NodeBox27
{-0.045045, -0.5, 0.334623, -0.027027, -0.228, 0.352659}, -- NodeBox28
{-0.285285, -0.5, 0.273273, -0.267267, -0.228, 0.292538}, -- NodeBox29
{0.345345, -0.5, 0.202357, 0.363363, -0.174, 0.220393}, -- NodeBox30
{0.0810811, -0.5, 0.130212, 0.0990991, -0.156, 0.148248}, -- NodeBox31
{-0.477477, -0.5, 0.0870871, -0.459459, -0.228, 0.105105}, -- NodeBox32
{-0.165165, -0.5, 0.0761028, -0.147147, -0.15, 0.0941392}, -- NodeBox33
{0.153153, -0.5, -0.0261028, 0.171171, -0.24, -0.0140786}, -- NodeBox34
{0.339339, -0.5, -0.0870871, 0.363363, -0.198, -0.098248}, -- NodeBox35
{-0.327327, -0.5, -0.0990991, -0.345345, -0.186, -0.0810811}, -- NodeBox36
{-0.105105, -0.5, -0.236526, -0.0870871, -0.162, -0.21849}, -- NodeBox37
{-0.225225, -0.5, -0.302659, -0.207207, -0.204, -0.284623}, -- NodeBox38
{0.0870871, -0.5, -0.302659, 0.105105, -0.138, -0.284623}, -- NodeBox39
{-0.423423, -0.5, -0.36278, -0.405405, -0.198, -0.350756}, -- NodeBox40
{0.399399, -0.5, -0.398853, 0.417417, -0.156, -0.386829}, -- NodeBox41
{0.201201, -0.5, -0.411411, 0.219219, -0.156, -0.392841}, -- NodeBox42
{-0.165165, -0.5, -0.483022, -0.153153, -0.216, -0.470998}, -- NodeBox43
}
},
selection_box = {
type = "fixed",
fixed = {
{-0.5, -0.5, -0.5, 0.5, -0.1875, 0.5},
},
},
})
inetest.register_node("default:clover_purple", {
description = "Purple Clover",
drawtype = "nodebox",
tiles = {'clover_purple_top.png', 'default_grass.png', 'clover_purple_side.png',},
paramtype = "light",
buildable_to = true,
walkable = true,
sounds = default.node_sound_dirt_defaults(),
groups = {snappy=1,choppy=2,oddly_breakable_by_hand=2,crumbly=3},
drawtype = "nodebox",
node_box = {
type = "fixed",
fixed = {
{-0.5, -0.5, -0.5, 0.5, -0.375, 0.5}, -- NodeBox1
{0.0625, -0.5, -0.4375, 0.4375, -0.3125, -0.1875}, -- NodeBox2
{-0.25, -0.5, -0.3125, 0.3125, -0.3125, -0.125}, -- NodeBox3
{-0.375, -0.5, 0.125, 0.0625, -0.3125, 0.4375}, -- NodeBox4
{0, -0.5, -0.0625, 0.3125, -0.3125, 0.1875}, -- NodeBox5
{-0.5, -0.5, -0.375, -0.375, -0.3125, 0.0625}, -- NodeBox6
{0.1875, -0.5, 0.3125, 0.4375, -0.3125, 0.4375}, -- NodeBox7
{0.125, -0.25, 0.4375, 0.1875, -0.1875, 0.5}, -- NodeBox8
{-0.375, -0.1875, 0.375, -0.3125, -0.125, 0.4375}, -- NodeBox9
{-0.0625, -0.25, 0.3125, 0, -0.1875, 0.375}, -- NodeBox10
{-0.3125, -0.25, 0.25, -0.25, -0.1875, 0.3125}, -- NodeBox11
{0.3125, -0.1875, 0.1875, 0.375, -0.125, 0.25}, -- NodeBox12
{0.0625, -0.1875, 0.125, 0.125, -0.125, 0.1875}, -- NodeBox13
{-0.5, -0.25, 0.0625, -0.4375, -0.1875, 0.125}, -- NodeBox14
{-0.1875, -0.1875, 0.0625, -0.125, -0.125, 0.125}, -- NodeBox15
{0.125, -0.25, -0.0625, 0.1875, -0.1875, 0}, -- NodeBox16
{0.3125, -0.1875, -0.125, 0.375, -0.125, -0.0625}, -- NodeBox17
{-0.375, -0.25, -0.125, -0.3125, -0.1875, -0.0625}, -- NodeBox18
{-0.125, -0.1875, -0.25, -0.0625, -0.125, -0.1875}, -- NodeBox19
{-0.25, -0.25, -0.3125, -0.1875, -0.1875, -0.25}, -- NodeBox20
{0.0625, -0.1875, -0.3125, 0.125, -0.125, -0.25}, -- NodeBox21
{-0.4375, -0.25, -0.375, -0.375, -0.1875, -0.3125}, -- NodeBox22
{0.375, -0.1875, -0.4375, 0.4375, -0.125, -0.375}, -- NodeBox23
{0.1875, -0.1875, -0.4375, 0.25, -0.125, -0.375}, -- NodeBox24
{-0.1875, -0.25, -0.5, -0.125, -0.1875, -0.4375}, -- NodeBox25
{0.147147, -0.5, 0.459459, 0.165165, -0.25, 0.477477}, -- NodeBox26
{-0.351351, -0.5, 0.387387, -0.333333, -0.1875, 0.405405}, -- NodeBox27
{-0.045045, -0.5, 0.334623, -0.027027, -0.228, 0.352659}, -- NodeBox28
{-0.285285, -0.5, 0.273273, -0.267267, -0.228, 0.292538}, -- NodeBox29
{0.345345, -0.5, 0.202357, 0.363363, -0.174, 0.220393}, -- NodeBox30
{0.0810811, -0.5, 0.130212, 0.0990991, -0.156, 0.148248}, -- NodeBox31
{-0.477477, -0.5, 0.0870871, -0.459459, -0.228, 0.105105}, -- NodeBox32
{-0.165165, -0.5, 0.0761028, -0.147147, -0.15, 0.0941392}, -- NodeBox33
{0.153153, -0.5, -0.0261028, 0.171171, -0.24, -0.0140786}, -- NodeBox34
{0.339339, -0.5, -0.0870871, 0.363363, -0.198, -0.098248}, -- NodeBox35
{-0.327327, -0.5, -0.0990991, -0.345345, -0.186, -0.0810811}, -- NodeBox36
{-0.105105, -0.5, -0.236526, -0.0870871, -0.162, -0.21849}, -- NodeBox37
{-0.225225, -0.5, -0.302659, -0.207207, -0.204, -0.284623}, -- NodeBox38
{0.0870871, -0.5, -0.302659, 0.105105, -0.138, -0.284623}, -- NodeBox39
{-0.423423, -0.5, -0.36278, -0.405405, -0.198, -0.350756}, -- NodeBox40
{0.399399, -0.5, -0.398853, 0.417417, -0.156, -0.386829}, -- NodeBox41
{0.201201, -0.5, -0.411411, 0.219219, -0.156, -0.392841}, -- NodeBox42
{-0.165165, -0.5, -0.483022, -0.153153, -0.216, -0.470998}, -- NodeBox43
}
},
selection_box = {
type = "fixed",
fixed = {
{-0.5, -0.5, -0.5, 0.5, -0.1875, 0.5},
},
},
})

View File

@ -186,7 +186,7 @@ if minetest.setting_get("enable_item_pickup") == "true" then
local inv = player:get_inventory()
for _, object in ipairs(minetest.env:get_objects_inside_radius(playerPosition, 3)) do
if isGood(object) and (object:get_luaentity().dropped_by ~= player:get_player_name() or object:get_luaentity().age > 3) and
if isGood(object) and (object:get_luaentity().dropped_by ~= player:get_player_name() or object:get_luaentity().age > 5) and
inv and
inv:room_for_item("main", ItemStack(object:get_luaentity().itemstring))
then

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.9 KiB

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 828 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

View File

@ -1,3 +1,7 @@
minetest.register_alias("homedecor:plastic_sheeting", "default:plastic_sheeting")
minetest.register_alias("homedecor:plastic_base", "default:plastic_base")
minetest.register_craftitem("default:plastic_sheeting", {
description = "Plastic sheet",
inventory_image = "homedecor_plastic_sheeting.png",

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 249 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 544 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 542 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 644 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 483 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 421 B