write something there
30
mods/minetest_game/flowers/README.txt
Normal file
|
@ -0,0 +1,30 @@
|
|||
Minetest Game mod: flowers
|
||||
==========================
|
||||
See license.txt for license information.
|
||||
|
||||
Authors of source code
|
||||
----------------------
|
||||
Originally by Ironzorg (MIT) and VanessaE (MIT)
|
||||
Various Minetest Game developers and contributors (MIT)
|
||||
|
||||
Authors of media (textures)
|
||||
---------------------------
|
||||
RHRhino (CC BY-SA 3.0):
|
||||
flowers_dandelion_white.png
|
||||
flowers_geranium.png
|
||||
flowers_rose.png
|
||||
flowers_tulip.png
|
||||
flowers_viola.png
|
||||
|
||||
Gambit (CC BY-SA 3.0):
|
||||
flowers_mushroom_brown.png
|
||||
flowers_mushroom_red.png
|
||||
flowers_waterlily.png
|
||||
|
||||
yyt16384 (CC BY-SA 3.0):
|
||||
flowers_waterlily_bottom.png -- Derived from Gambit's texture
|
||||
|
||||
paramat (CC BY-SA 3.0):
|
||||
flowers_dandelion_yellow.png -- Derived from RHRhino's texture
|
||||
flowers_tulip_black.png -- Derived from RHRhino's texture
|
||||
flowers_chrysanthemum_green.png
|
336
mods/minetest_game/flowers/init.lua
Normal file
|
@ -0,0 +1,336 @@
|
|||
-- flowers/init.lua
|
||||
|
||||
-- Minetest Game mod: flowers
|
||||
-- See README.txt for licensing and other information.
|
||||
|
||||
|
||||
-- Namespace for functions
|
||||
|
||||
flowers = {}
|
||||
|
||||
-- Load support for MT game translation.
|
||||
local S = minetest.get_translator("flowers")
|
||||
|
||||
|
||||
-- Map Generation
|
||||
|
||||
dofile(minetest.get_modpath("flowers") .. "/mapgen.lua")
|
||||
|
||||
|
||||
--
|
||||
-- Flowers
|
||||
--
|
||||
|
||||
-- Aliases for original flowers mod
|
||||
|
||||
minetest.register_alias("flowers:flower_rose", "flowers:rose")
|
||||
minetest.register_alias("flowers:flower_tulip", "flowers:tulip")
|
||||
minetest.register_alias("flowers:flower_dandelion_yellow", "flowers:dandelion_yellow")
|
||||
minetest.register_alias("flowers:flower_geranium", "flowers:geranium")
|
||||
minetest.register_alias("flowers:flower_viola", "flowers:viola")
|
||||
minetest.register_alias("flowers:flower_dandelion_white", "flowers:dandelion_white")
|
||||
|
||||
|
||||
-- Flower registration
|
||||
|
||||
local function add_simple_flower(name, desc, box, f_groups)
|
||||
-- Common flowers' groups
|
||||
f_groups.snappy = 3
|
||||
f_groups.flower = 1
|
||||
f_groups.flora = 1
|
||||
f_groups.attached_node = 1
|
||||
|
||||
minetest.register_node("flowers:" .. name, {
|
||||
description = desc,
|
||||
drawtype = "plantlike",
|
||||
waving = 1,
|
||||
tiles = {"flowers_" .. name .. ".png"},
|
||||
inventory_image = "flowers_" .. name .. ".png",
|
||||
wield_image = "flowers_" .. name .. ".png",
|
||||
sunlight_propagates = true,
|
||||
paramtype = "light",
|
||||
walkable = false,
|
||||
buildable_to = true,
|
||||
groups = f_groups,
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = box
|
||||
}
|
||||
})
|
||||
end
|
||||
|
||||
flowers.datas = {
|
||||
{
|
||||
"rose",
|
||||
S("Red Rose"),
|
||||
{-2 / 16, -0.5, -2 / 16, 2 / 16, 5 / 16, 2 / 16},
|
||||
{color_red = 1, flammable = 1}
|
||||
},
|
||||
{
|
||||
"tulip",
|
||||
S("Orange Tulip"),
|
||||
{-2 / 16, -0.5, -2 / 16, 2 / 16, 3 / 16, 2 / 16},
|
||||
{color_orange = 1, flammable = 1}
|
||||
},
|
||||
{
|
||||
"dandelion_yellow",
|
||||
S("Yellow Dandelion"),
|
||||
{-4 / 16, -0.5, -4 / 16, 4 / 16, -2 / 16, 4 / 16},
|
||||
{color_yellow = 1, flammable = 1}
|
||||
},
|
||||
{
|
||||
"chrysanthemum_green",
|
||||
S("Green Chrysanthemum"),
|
||||
{-4 / 16, -0.5, -4 / 16, 4 / 16, -1 / 16, 4 / 16},
|
||||
{color_green = 1, flammable = 1}
|
||||
},
|
||||
{
|
||||
"geranium",
|
||||
S("Blue Geranium"),
|
||||
{-2 / 16, -0.5, -2 / 16, 2 / 16, 2 / 16, 2 / 16},
|
||||
{color_blue = 1, flammable = 1}
|
||||
},
|
||||
{
|
||||
"viola",
|
||||
S("Viola"),
|
||||
{-5 / 16, -0.5, -5 / 16, 5 / 16, -1 / 16, 5 / 16},
|
||||
{color_violet = 1, flammable = 1}
|
||||
},
|
||||
{
|
||||
"dandelion_white",
|
||||
S("White Dandelion"),
|
||||
{-5 / 16, -0.5, -5 / 16, 5 / 16, -2 / 16, 5 / 16},
|
||||
{color_white = 1, flammable = 1}
|
||||
},
|
||||
{
|
||||
"tulip_black",
|
||||
S("Black Tulip"),
|
||||
{-2 / 16, -0.5, -2 / 16, 2 / 16, 3 / 16, 2 / 16},
|
||||
{color_black = 1, flammable = 1}
|
||||
},
|
||||
}
|
||||
|
||||
for _,item in pairs(flowers.datas) do
|
||||
add_simple_flower(unpack(item))
|
||||
end
|
||||
|
||||
|
||||
-- Flower spread
|
||||
-- Public function to enable override by mods
|
||||
|
||||
function flowers.flower_spread(pos, node)
|
||||
pos.y = pos.y - 1
|
||||
local under = minetest.get_node(pos)
|
||||
pos.y = pos.y + 1
|
||||
-- Replace flora with dry shrub in desert sand and silver sand,
|
||||
-- as this is the only way to generate them.
|
||||
-- However, preserve grasses in sand dune biomes.
|
||||
if minetest.get_item_group(under.name, "sand") == 1 and
|
||||
under.name ~= "default:sand" then
|
||||
minetest.set_node(pos, {name = "default:dry_shrub"})
|
||||
return
|
||||
end
|
||||
|
||||
if minetest.get_item_group(under.name, "soil") == 0 then
|
||||
return
|
||||
end
|
||||
|
||||
local light = minetest.get_node_light(pos)
|
||||
if not light or light < 13 then
|
||||
return
|
||||
end
|
||||
|
||||
local pos0 = vector.subtract(pos, 4)
|
||||
local pos1 = vector.add(pos, 4)
|
||||
-- Testing shows that a threshold of 3 results in an appropriate maximum
|
||||
-- density of approximately 7 flora per 9x9 area.
|
||||
if #minetest.find_nodes_in_area(pos0, pos1, "group:flora") > 3 then
|
||||
return
|
||||
end
|
||||
|
||||
local soils = minetest.find_nodes_in_area_under_air(
|
||||
pos0, pos1, "group:soil")
|
||||
local num_soils = #soils
|
||||
if num_soils >= 1 then
|
||||
for si = 1, math.min(3, num_soils) do
|
||||
local soil = soils[math.random(num_soils)]
|
||||
local soil_name = minetest.get_node(soil).name
|
||||
local soil_above = {x = soil.x, y = soil.y + 1, z = soil.z}
|
||||
light = minetest.get_node_light(soil_above)
|
||||
if light and light >= 13 and
|
||||
-- Only spread to same surface node
|
||||
soil_name == under.name and
|
||||
-- Desert sand is in the soil group
|
||||
soil_name ~= "default:desert_sand" then
|
||||
minetest.set_node(soil_above, {name = node.name})
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
minetest.register_abm({
|
||||
label = "Flower spread",
|
||||
nodenames = {"group:flora"},
|
||||
interval = 13,
|
||||
chance = 300,
|
||||
action = function(...)
|
||||
flowers.flower_spread(...)
|
||||
end,
|
||||
})
|
||||
|
||||
|
||||
--
|
||||
-- Mushrooms
|
||||
--
|
||||
|
||||
minetest.register_node("flowers:mushroom_red", {
|
||||
description = S("Red Mushroom"),
|
||||
tiles = {"flowers_mushroom_red.png"},
|
||||
inventory_image = "flowers_mushroom_red.png",
|
||||
wield_image = "flowers_mushroom_red.png",
|
||||
drawtype = "plantlike",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
buildable_to = true,
|
||||
groups = {mushroom = 1, snappy = 3, attached_node = 1, flammable = 1},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
on_use = minetest.item_eat(-5),
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-4 / 16, -0.5, -4 / 16, 4 / 16, -1 / 16, 4 / 16},
|
||||
}
|
||||
})
|
||||
|
||||
minetest.register_node("flowers:mushroom_brown", {
|
||||
description = S("Brown Mushroom"),
|
||||
tiles = {"flowers_mushroom_brown.png"},
|
||||
inventory_image = "flowers_mushroom_brown.png",
|
||||
wield_image = "flowers_mushroom_brown.png",
|
||||
drawtype = "plantlike",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
walkable = false,
|
||||
buildable_to = true,
|
||||
groups = {mushroom = 1, food_mushroom = 1, snappy = 3, attached_node = 1, flammable = 1},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
on_use = minetest.item_eat(1),
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-3 / 16, -0.5, -3 / 16, 3 / 16, -2 / 16, 3 / 16},
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
-- Mushroom spread and death
|
||||
|
||||
function flowers.mushroom_spread(pos, node)
|
||||
--[[if minetest.get_node_light(pos, 0.5) > 3 then
|
||||
if minetest.get_node_light(pos, nil) == 15 then
|
||||
minetest.remove_node(pos)
|
||||
end
|
||||
return
|
||||
end]]
|
||||
local positions = minetest.find_nodes_in_area_under_air(
|
||||
{x = pos.x - 1, y = pos.y - 2, z = pos.z - 1},
|
||||
{x = pos.x + 1, y = pos.y + 1, z = pos.z + 1},
|
||||
{"group:soil", "group:tree"})
|
||||
if #positions == 0 then
|
||||
return
|
||||
end
|
||||
local pos2 = positions[math.random(#positions)]
|
||||
pos2.y = pos2.y + 1
|
||||
if minetest.get_node_light(pos2, 0.5) <= 3 then
|
||||
minetest.set_node(pos2, {name = node.name})
|
||||
end
|
||||
end
|
||||
|
||||
minetest.register_abm({
|
||||
label = "Mushroom spread",
|
||||
nodenames = {"group:mushroom"},
|
||||
interval = 11,
|
||||
chance = 150,
|
||||
action = function(...)
|
||||
flowers.mushroom_spread(...)
|
||||
end,
|
||||
})
|
||||
|
||||
|
||||
-- These old mushroom related nodes can be simplified now
|
||||
|
||||
minetest.register_alias("flowers:mushroom_spores_brown", "flowers:mushroom_brown")
|
||||
minetest.register_alias("flowers:mushroom_spores_red", "flowers:mushroom_red")
|
||||
minetest.register_alias("flowers:mushroom_fertile_brown", "flowers:mushroom_brown")
|
||||
minetest.register_alias("flowers:mushroom_fertile_red", "flowers:mushroom_red")
|
||||
minetest.register_alias("mushroom:brown_natural", "flowers:mushroom_brown")
|
||||
minetest.register_alias("mushroom:red_natural", "flowers:mushroom_red")
|
||||
|
||||
|
||||
--
|
||||
-- Waterlily
|
||||
--
|
||||
|
||||
local waterlily_def = {
|
||||
description = S("Waterlily"),
|
||||
drawtype = "nodebox",
|
||||
paramtype = "light",
|
||||
paramtype2 = "facedir",
|
||||
tiles = {"flowers_waterlily.png", "flowers_waterlily_bottom.png"},
|
||||
inventory_image = "flowers_waterlily.png",
|
||||
wield_image = "flowers_waterlily.png",
|
||||
use_texture_alpha = "clip",
|
||||
liquids_pointable = true,
|
||||
walkable = false,
|
||||
buildable_to = true,
|
||||
floodable = true,
|
||||
groups = {snappy = 3, flower = 1, flammable = 1},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
node_placement_prediction = "",
|
||||
node_box = {
|
||||
type = "fixed",
|
||||
fixed = {-0.5, -31 / 64, -0.5, 0.5, -15 / 32, 0.5}
|
||||
},
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-7 / 16, -0.5, -7 / 16, 7 / 16, -15 / 32, 7 / 16}
|
||||
},
|
||||
|
||||
on_place = function(itemstack, placer, pointed_thing)
|
||||
local pos = pointed_thing.above
|
||||
local node = minetest.get_node(pointed_thing.under)
|
||||
local def = minetest.registered_nodes[node.name]
|
||||
|
||||
if def and def.on_rightclick then
|
||||
return def.on_rightclick(pointed_thing.under, node, placer, itemstack,
|
||||
pointed_thing)
|
||||
end
|
||||
|
||||
if def and def.liquidtype == "source" and
|
||||
minetest.get_item_group(node.name, "water") > 0 then
|
||||
local player_name = placer and placer:get_player_name() or ""
|
||||
if not minetest.is_protected(pos, player_name) then
|
||||
minetest.set_node(pos, {name = "flowers:waterlily" ..
|
||||
(def.waving == 3 and "_waving" or ""),
|
||||
param2 = math.random(0, 3)})
|
||||
if not minetest.is_creative_enabled(player_name) then
|
||||
itemstack:take_item()
|
||||
end
|
||||
else
|
||||
minetest.chat_send_player(player_name, "Node is protected")
|
||||
minetest.record_protection_violation(pos, player_name)
|
||||
end
|
||||
end
|
||||
|
||||
return itemstack
|
||||
end
|
||||
}
|
||||
|
||||
local waterlily_waving_def = table.copy(waterlily_def)
|
||||
waterlily_waving_def.waving = 3
|
||||
waterlily_waving_def.drop = "flowers:waterlily"
|
||||
waterlily_waving_def.groups.not_in_creative_inventory = 1
|
||||
|
||||
minetest.register_node("flowers:waterlily", waterlily_def)
|
||||
minetest.register_node("flowers:waterlily_waving", waterlily_waving_def)
|
||||
|
63
mods/minetest_game/flowers/license.txt
Normal file
|
@ -0,0 +1,63 @@
|
|||
License of source code
|
||||
----------------------
|
||||
|
||||
The MIT License (MIT)
|
||||
Copyright (C) 2012-2016 Ironzorg, VanessaE
|
||||
Copyright (C) 2012-2016 Various Minetest Game developers and contributors
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this
|
||||
software and associated documentation files (the "Software"), to deal in the Software
|
||||
without restriction, including without limitation the rights to use, copy, modify, merge,
|
||||
publish, distribute, sublicense, and/or sell copies of the Software, and to permit
|
||||
persons to whom the Software is furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all copies or
|
||||
substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
|
||||
INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
|
||||
PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE
|
||||
FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
|
||||
OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||
DEALINGS IN THE SOFTWARE.
|
||||
|
||||
For more details:
|
||||
https://opensource.org/licenses/MIT
|
||||
|
||||
|
||||
Licenses of media (textures)
|
||||
----------------------------
|
||||
|
||||
Attribution-ShareAlike 3.0 Unported (CC BY-SA 3.0)
|
||||
Copyright (C) 2014-2016 RHRhino
|
||||
Copyright (C) 2015-2016 Gambit
|
||||
Copyright (C) 2016 yyt16384
|
||||
Copyright (C) 2017 paramat
|
||||
|
||||
You are free to:
|
||||
Share — copy and redistribute the material in any medium or format.
|
||||
Adapt — remix, transform, and build upon the material for any purpose, even commercially.
|
||||
The licensor cannot revoke these freedoms as long as you follow the license terms.
|
||||
|
||||
Under the following terms:
|
||||
|
||||
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.
|
||||
|
||||
No additional restrictions — You may not apply legal terms or technological measures that
|
||||
legally restrict others from doing anything the license permits.
|
||||
|
||||
Notices:
|
||||
|
||||
You do not have to comply with the license for elements of the material in the public
|
||||
domain or where your use is permitted by an applicable exception or limitation.
|
||||
No warranties are given. The license may not give you all of the permissions necessary
|
||||
for your intended use. For example, other rights such as publicity, privacy, or moral
|
||||
rights may limit how you use the material.
|
||||
|
||||
For more details:
|
||||
http://creativecommons.org/licenses/by-sa/3.0/
|
12
mods/minetest_game/flowers/locale/flowers.de.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=Rote Rose
|
||||
Orange Tulip=Orange Tulpe
|
||||
Yellow Dandelion=Gelber Löwenzahn
|
||||
Green Chrysanthemum=Grüne Chrysantheme
|
||||
Blue Geranium=Blaue Geranie
|
||||
Viola=Veilchen
|
||||
White Dandelion=Weißer Löwenzahn
|
||||
Black Tulip=Schwarze Tulpe
|
||||
Red Mushroom=Roter Pilz
|
||||
Brown Mushroom=Brauner Pilz
|
||||
Waterlily=Wasserlilie
|
12
mods/minetest_game/flowers/locale/flowers.eo.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=Ruĝa rozo
|
||||
Orange Tulip=Oranĝkolora tulipo
|
||||
Yellow Dandelion=Flava leontodo
|
||||
Green Chrysanthemum=Verda krizantemo
|
||||
Blue Geranium=Blua geranio
|
||||
Viola=Violo
|
||||
White Dandelion=Blanka leontodo
|
||||
Black Tulip=Nigra tulipo
|
||||
Red Mushroom=Ruĝa fungo
|
||||
Brown Mushroom=Bruna fungo
|
||||
Waterlily=Nimfeo
|
12
mods/minetest_game/flowers/locale/flowers.es.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=Rosa roja
|
||||
Orange Tulip=Tulipán naranja
|
||||
Yellow Dandelion=Diente de León amarillo
|
||||
Green Chrysanthemum=Crisantemo verde
|
||||
Blue Geranium=Geranio azul
|
||||
Viola=Violeta
|
||||
White Dandelion=Diente de León blanco
|
||||
Black Tulip=Tulipán negro
|
||||
Red Mushroom=Champiñón rojo
|
||||
Brown Mushroom=Champiñón café
|
||||
Waterlily=Nenúfar
|
12
mods/minetest_game/flowers/locale/flowers.fr.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=Rose rouge
|
||||
Orange Tulip=Tulipe orange
|
||||
Yellow Dandelion=Pissenlit jaune
|
||||
Green Chrysanthemum=Chrysanthème vert
|
||||
Blue Geranium=Géranium bleu
|
||||
Viola=Violette
|
||||
White Dandelion=Pissenlit blanc
|
||||
Black Tulip=Tulipe noire
|
||||
Red Mushroom=Champignon rouge
|
||||
Brown Mushroom=Champignon brun
|
||||
Waterlily=Nénuphar
|
12
mods/minetest_game/flowers/locale/flowers.id.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=Mawar Merah
|
||||
Orange Tulip=Tulip Oranye
|
||||
Yellow Dandelion=Dandelion Kuning
|
||||
Green Chrysanthemum=Krisan Hijau
|
||||
Blue Geranium=Geranium Biru
|
||||
Viola=Viola
|
||||
White Dandelion=Dandelion Putih
|
||||
Black Tulip=Tulip Hitam
|
||||
Red Mushroom=Jamur Merah
|
||||
Brown Mushroom=Jamur Cokelat
|
||||
Waterlily=Teratai
|
12
mods/minetest_game/flowers/locale/flowers.it.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=Rosa rossa
|
||||
Orange Tulip=Tulipano arancione
|
||||
Yellow Dandelion=Dente di leone giallo
|
||||
Green Chrysanthemum=Crisantemo verde
|
||||
Blue Geranium=Geranio blu
|
||||
Viola=Viola
|
||||
White Dandelion=Dente di leone bianco
|
||||
Black Tulip=Tulipano nero
|
||||
Red Mushroom=Fungo rosso
|
||||
Brown Mushroom=Fungo marrone
|
||||
Waterlily=Ninfea
|
12
mods/minetest_game/flowers/locale/flowers.ja.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=赤色のバラ
|
||||
Orange Tulip=橙色のチューリップ
|
||||
Yellow Dandelion=黄色のタンポポ
|
||||
Green Chrysanthemum=緑色のキク
|
||||
Blue Geranium=青色のゼラニウム
|
||||
Viola=ビオラ
|
||||
White Dandelion=白色のタンポポ
|
||||
Black Tulip=黒色のチューリップ
|
||||
Red Mushroom=赤色のキノコ
|
||||
Brown Mushroom=茶色のキノコ
|
||||
Waterlily=スイレン
|
12
mods/minetest_game/flowers/locale/flowers.jbo.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=lo xunre rozgu
|
||||
Orange Tulip=lo narju tujli
|
||||
Yellow Dandelion=lo pelxu spatrtaraksaku
|
||||
Green Chrysanthemum=lo crino xrisantemo
|
||||
Blue Geranium=lo blanu plargoni
|
||||
Viola=lo spatrvi'ola
|
||||
White Dandelion=lo blabi spatrtaraksaku
|
||||
Black Tulip=lo xekri tujli
|
||||
Red Mushroom=lo xunre ledgrute
|
||||
Brown Mushroom=lo bunre ledgrute
|
||||
Waterlily=lo jacrulspa
|
12
mods/minetest_game/flowers/locale/flowers.lv.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=Sarkanā roze
|
||||
Orange Tulip=Oranžā tulpe
|
||||
Yellow Dandelion=Dzeltena pienene
|
||||
Green Chrysanthemum=Zaļā krizantema
|
||||
Blue Geranium=Zilā ģerānija
|
||||
Viola=Vijolīte
|
||||
White Dandelion=Balta pienene
|
||||
Black Tulip=Melnā tulpe
|
||||
Red Mushroom=Sarkanā sēne
|
||||
Brown Mushroom=Brūnā sēne
|
||||
Waterlily=Ūdensroze
|
12
mods/minetest_game/flowers/locale/flowers.ms.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=Ros Merah
|
||||
Orange Tulip=Tulip Jingga
|
||||
Yellow Dandelion=Dandelion Kuning
|
||||
Green Chrysanthemum=Kekwa Hijau
|
||||
Blue Geranium=Geranium Biru
|
||||
Viola=Violet
|
||||
White Dandelion=Dandelion Putih
|
||||
Black Tulip=Tulip Hitam
|
||||
Red Mushroom=Cendawan Merah
|
||||
Brown Mushroom=Cendawan Perang
|
||||
Waterlily=Teratai
|
12
mods/minetest_game/flowers/locale/flowers.pl.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=Czerwona róża
|
||||
Orange Tulip=Pomarańczowy tulipan
|
||||
Yellow Dandelion=Żółty mlecz
|
||||
Green Chrysanthemum=Zielona chryzantema
|
||||
Blue Geranium=Niebieska pelargonia
|
||||
Viola=Fiołek
|
||||
White Dandelion=Biały mlecz
|
||||
Black Tulip=Czarny tulipan
|
||||
Red Mushroom=Czerwony muchomor
|
||||
Brown Mushroom=Brązowy grzyb
|
||||
Waterlily=Lilia wodna
|
12
mods/minetest_game/flowers/locale/flowers.pt_BR.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=Rosa Vermelha
|
||||
Orange Tulip=Tulipa Laranja
|
||||
Yellow Dandelion=Dente-de-leão Amarelo
|
||||
Green Chrysanthemum=Crisântemo Verde
|
||||
Blue Geranium=Gerânio Azul
|
||||
Viola=Violeta
|
||||
White Dandelion=Dente-de-leão Branco
|
||||
Black Tulip=Tulipa Negra
|
||||
Red Mushroom=Cogumelo Vermelho
|
||||
Brown Mushroom=Cogumelo Marrom
|
||||
Waterlily=Nenúfar
|
12
mods/minetest_game/flowers/locale/flowers.ru.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=Красная роза
|
||||
Orange Tulip=Оранжевый тюльпан
|
||||
Yellow Dandelion=Жёлтый одуванчик
|
||||
Green Chrysanthemum=Зелёная хризантема
|
||||
Blue Geranium=Синяя герань
|
||||
Viola=Фиалка
|
||||
White Dandelion=Белый одуванчик
|
||||
Black Tulip=Чёрный тюльпан
|
||||
Red Mushroom=Красный гриб
|
||||
Brown Mushroom=Коричневый гриб
|
||||
Waterlily=Лилия
|
12
mods/minetest_game/flowers/locale/flowers.sk.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=Červená ruža
|
||||
Orange Tulip=Oranžový tulipán
|
||||
Yellow Dandelion=Žltá púpava
|
||||
Green Chrysanthemum=Zelená chryzantéma
|
||||
Blue Geranium=Modrý muškát
|
||||
Viola=Fialka
|
||||
White Dandelion=Biela púpava
|
||||
Black Tulip=Čierny tulipán
|
||||
Red Mushroom=Červená huba
|
||||
Brown Mushroom=Hnedá huba
|
||||
Waterlily=Lekno
|
12
mods/minetest_game/flowers/locale/flowers.sv.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=Röd ros
|
||||
Orange Tulip=Orange tulpan
|
||||
Yellow Dandelion=Gul maskros
|
||||
Green Chrysanthemum=Grön krysantemum
|
||||
Blue Geranium=Blå geranium
|
||||
Viola=Violett viola
|
||||
White Dandelion=Vit maskros
|
||||
Black Tulip=Svart tulpan
|
||||
Red Mushroom=Röd svamp
|
||||
Brown Mushroom=Brun svamp
|
||||
Waterlily=Näckros
|
12
mods/minetest_game/flowers/locale/flowers.uk.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=Червона троянда
|
||||
Orange Tulip=Помаранчевий тюльпан
|
||||
Yellow Dandelion=Жовта кульбаба
|
||||
Green Chrysanthemum=Зелена хризантема
|
||||
Blue Geranium=Синій журавець
|
||||
Viola=Фіалка
|
||||
White Dandelion=Біла кульбаба
|
||||
Black Tulip=Чорний тюльпан
|
||||
Red Mushroom=Червоний гриб
|
||||
Brown Mushroom=Коричневий гриб
|
||||
Waterlily=Латаття
|
12
mods/minetest_game/flowers/locale/flowers.zh_CN.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=红玫瑰
|
||||
Orange Tulip=橙郁金香
|
||||
Yellow Dandelion=黄蒲公英
|
||||
Green Chrysanthemum=绿菊花
|
||||
Blue Geranium=蓝天竺葵
|
||||
Viola=三色堇
|
||||
White Dandelion=白蒲公英
|
||||
Black Tulip=黑郁金香
|
||||
Red Mushroom=红蘑菇
|
||||
Brown Mushroom=棕蘑菇
|
||||
Waterlily=睡莲
|
12
mods/minetest_game/flowers/locale/flowers.zh_TW.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=紅玫瑰
|
||||
Orange Tulip=橙鬱金香
|
||||
Yellow Dandelion=黃蒲公英
|
||||
Green Chrysanthemum=綠菊花
|
||||
Blue Geranium=藍天竺葵
|
||||
Viola=三色堇
|
||||
White Dandelion=白蒲公英
|
||||
Black Tulip=黑鬱金香
|
||||
Red Mushroom=紅蘑菇
|
||||
Brown Mushroom=棕蘑菇
|
||||
Waterlily=睡蓮
|
12
mods/minetest_game/flowers/locale/template.txt
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: flowers
|
||||
Red Rose=
|
||||
Orange Tulip=
|
||||
Yellow Dandelion=
|
||||
Green Chrysanthemum=
|
||||
Blue Geranium=
|
||||
Viola=
|
||||
White Dandelion=
|
||||
Black Tulip=
|
||||
Red Mushroom=
|
||||
Brown Mushroom=
|
||||
Waterlily=
|
181
mods/minetest_game/flowers/mapgen.lua
Normal file
|
@ -0,0 +1,181 @@
|
|||
--
|
||||
-- Mgv6
|
||||
--
|
||||
|
||||
local function register_mgv6_flower(flower_name)
|
||||
minetest.register_decoration({
|
||||
name = "flowers:"..flower_name,
|
||||
deco_type = "simple",
|
||||
place_on = {"default:dirt_with_grass"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0,
|
||||
scale = 0.006,
|
||||
spread = {x = 100, y = 100, z = 100},
|
||||
seed = 436,
|
||||
octaves = 3,
|
||||
persist = 0.6
|
||||
},
|
||||
y_max = 30,
|
||||
y_min = 1,
|
||||
decoration = "flowers:"..flower_name,
|
||||
})
|
||||
end
|
||||
|
||||
local function register_mgv6_mushroom(mushroom_name)
|
||||
minetest.register_decoration({
|
||||
name = "flowers:"..mushroom_name,
|
||||
deco_type = "simple",
|
||||
place_on = {"default:dirt_with_grass"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0,
|
||||
scale = 0.04,
|
||||
spread = {x = 100, y = 100, z = 100},
|
||||
seed = 7133,
|
||||
octaves = 3,
|
||||
persist = 0.6
|
||||
},
|
||||
y_max = 30,
|
||||
y_min = 1,
|
||||
decoration = "flowers:"..mushroom_name,
|
||||
spawn_by = "default:tree",
|
||||
num_spawn_by = 1,
|
||||
})
|
||||
end
|
||||
|
||||
local function register_mgv6_waterlily()
|
||||
minetest.register_decoration({
|
||||
name = "flowers:waterlily",
|
||||
deco_type = "simple",
|
||||
place_on = {"default:dirt"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = -0.12,
|
||||
scale = 0.3,
|
||||
spread = {x = 100, y = 100, z = 100},
|
||||
seed = 33,
|
||||
octaves = 3,
|
||||
persist = 0.7
|
||||
},
|
||||
y_max = 0,
|
||||
y_min = 0,
|
||||
decoration = "flowers:waterlily_waving",
|
||||
param2 = 0,
|
||||
param2_max = 3,
|
||||
place_offset_y = 1,
|
||||
})
|
||||
end
|
||||
|
||||
function flowers.register_mgv6_decorations()
|
||||
register_mgv6_flower("rose")
|
||||
register_mgv6_flower("tulip")
|
||||
register_mgv6_flower("dandelion_yellow")
|
||||
register_mgv6_flower("geranium")
|
||||
register_mgv6_flower("viola")
|
||||
register_mgv6_flower("dandelion_white")
|
||||
|
||||
register_mgv6_mushroom("mushroom_brown")
|
||||
register_mgv6_mushroom("mushroom_red")
|
||||
|
||||
register_mgv6_waterlily()
|
||||
end
|
||||
|
||||
|
||||
--
|
||||
-- All other biome API mapgens
|
||||
--
|
||||
|
||||
local function register_flower(seed, flower_name)
|
||||
minetest.register_decoration({
|
||||
name = "flowers:"..flower_name,
|
||||
deco_type = "simple",
|
||||
place_on = {"default:dirt_with_grass"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = -0.02,
|
||||
scale = 0.04,
|
||||
spread = {x = 200, y = 200, z = 200},
|
||||
seed = seed,
|
||||
octaves = 3,
|
||||
persist = 0.6
|
||||
},
|
||||
biomes = {"grassland", "deciduous_forest"},
|
||||
y_max = 31000,
|
||||
y_min = 1,
|
||||
decoration = "flowers:"..flower_name,
|
||||
})
|
||||
end
|
||||
|
||||
local function register_mushroom(mushroom_name)
|
||||
minetest.register_decoration({
|
||||
name = "flowers:"..mushroom_name,
|
||||
deco_type = "simple",
|
||||
place_on = {"default:dirt_with_grass", "default:dirt_with_coniferous_litter"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = 0,
|
||||
scale = 0.006,
|
||||
spread = {x = 250, y = 250, z = 250},
|
||||
seed = 2,
|
||||
octaves = 3,
|
||||
persist = 0.66
|
||||
},
|
||||
biomes = {"deciduous_forest", "coniferous_forest"},
|
||||
y_max = 31000,
|
||||
y_min = 1,
|
||||
decoration = "flowers:"..mushroom_name,
|
||||
})
|
||||
end
|
||||
|
||||
local function register_waterlily()
|
||||
minetest.register_decoration({
|
||||
name = "default:waterlily",
|
||||
deco_type = "simple",
|
||||
place_on = {"default:dirt"},
|
||||
sidelen = 16,
|
||||
noise_params = {
|
||||
offset = -0.12,
|
||||
scale = 0.3,
|
||||
spread = {x = 200, y = 200, z = 200},
|
||||
seed = 33,
|
||||
octaves = 3,
|
||||
persist = 0.7
|
||||
},
|
||||
biomes = {"rainforest_swamp", "savanna_shore", "deciduous_forest_shore"},
|
||||
y_max = 0,
|
||||
y_min = 0,
|
||||
decoration = "flowers:waterlily_waving",
|
||||
param2 = 0,
|
||||
param2_max = 3,
|
||||
place_offset_y = 1,
|
||||
})
|
||||
end
|
||||
|
||||
function flowers.register_decorations()
|
||||
register_flower(436, "rose")
|
||||
register_flower(19822, "tulip")
|
||||
register_flower(1220999, "dandelion_yellow")
|
||||
register_flower(800081, "chrysanthemum_green")
|
||||
register_flower(36662, "geranium")
|
||||
register_flower(1133, "viola")
|
||||
register_flower(73133, "dandelion_white")
|
||||
register_flower(42, "tulip_black")
|
||||
|
||||
register_mushroom("mushroom_brown")
|
||||
register_mushroom("mushroom_red")
|
||||
|
||||
register_waterlily()
|
||||
end
|
||||
|
||||
|
||||
--
|
||||
-- Detect mapgen to select functions
|
||||
--
|
||||
|
||||
local mg_name = minetest.get_mapgen_setting("mg_name")
|
||||
if mg_name == "v6" then
|
||||
--flowers.register_mgv6_decorations()
|
||||
else
|
||||
--flowers.register_decorations()
|
||||
end
|
3
mods/minetest_game/flowers/mod.conf
Normal file
|
@ -0,0 +1,3 @@
|
|||
name = flowers
|
||||
description = Minetest Game mod: flowers
|
||||
depends = default
|
After Width: | Height: | Size: 235 B |
BIN
mods/minetest_game/flowers/textures/flowers_dandelion_white.png
Normal file
After Width: | Height: | Size: 142 B |
BIN
mods/minetest_game/flowers/textures/flowers_dandelion_yellow.png
Normal file
After Width: | Height: | Size: 138 B |
BIN
mods/minetest_game/flowers/textures/flowers_geranium.png
Normal file
After Width: | Height: | Size: 163 B |
BIN
mods/minetest_game/flowers/textures/flowers_mushroom_brown.png
Normal file
After Width: | Height: | Size: 155 B |
BIN
mods/minetest_game/flowers/textures/flowers_mushroom_red.png
Normal file
After Width: | Height: | Size: 167 B |
BIN
mods/minetest_game/flowers/textures/flowers_rose.png
Normal file
After Width: | Height: | Size: 136 B |
BIN
mods/minetest_game/flowers/textures/flowers_tulip.png
Normal file
After Width: | Height: | Size: 143 B |
BIN
mods/minetest_game/flowers/textures/flowers_tulip_black.png
Normal file
After Width: | Height: | Size: 172 B |
BIN
mods/minetest_game/flowers/textures/flowers_viola.png
Normal file
After Width: | Height: | Size: 153 B |
BIN
mods/minetest_game/flowers/textures/flowers_waterlily.png
Normal file
After Width: | Height: | Size: 403 B |
BIN
mods/minetest_game/flowers/textures/flowers_waterlily_bottom.png
Normal file
After Width: | Height: | Size: 327 B |