write something there
This commit is contained in:
commit
b4b6c08f4f
8546 changed files with 309825 additions and 0 deletions
22
mods/minetest_game/fireflies/README.txt
Normal file
22
mods/minetest_game/fireflies/README.txt
Normal file
|
@ -0,0 +1,22 @@
|
|||
Minetest Game mod: fireflies
|
||||
============================
|
||||
Adds fireflies to the world on mapgen, which can then be caught in a net and placed in
|
||||
bottles to provide light.
|
||||
|
||||
Authors of source code
|
||||
----------------------
|
||||
Shara RedCat (MIT)
|
||||
|
||||
Authors of media (textures)
|
||||
---------------------------
|
||||
Shara RedCat (CC BY-SA 3.0):
|
||||
fireflies_firefly.png
|
||||
fireflies_firefly_animated.png
|
||||
fireflies_bugnet.png
|
||||
fireflies_bottle.png
|
||||
fireflies_bottle_animated.png
|
||||
|
||||
fireflies_bugnet.png is modified from a texture by tenplus1 (CC0)
|
||||
|
||||
fireflies_bottle.png and fireflies_bottle_animated.png are
|
||||
modified from a texture by Vanessa Ezekowitz (CC BY-SA 3.0)
|
162
mods/minetest_game/fireflies/init.lua
Normal file
162
mods/minetest_game/fireflies/init.lua
Normal file
|
@ -0,0 +1,162 @@
|
|||
-- firefly/init.lua
|
||||
|
||||
-- Load support for MT game translation.
|
||||
local S = minetest.get_translator("fireflies")
|
||||
|
||||
-- Legacy compatibility, when pointabilities don't exist, pointable is set to true.
|
||||
local pointable_compat = not minetest.features.item_specific_pointabilities
|
||||
|
||||
minetest.register_node("fireflies:firefly", {
|
||||
description = S("Firefly"),
|
||||
drawtype = "plantlike",
|
||||
tiles = {{
|
||||
name = "fireflies_firefly_animated.png",
|
||||
animation = {
|
||||
type = "vertical_frames",
|
||||
aspect_w = 16,
|
||||
aspect_h = 16,
|
||||
length = 1.5
|
||||
},
|
||||
}},
|
||||
inventory_image = "fireflies_firefly.png",
|
||||
wield_image = "fireflies_firefly.png",
|
||||
waving = 1,
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
buildable_to = true,
|
||||
walkable = false,
|
||||
pointable = pointable_compat,
|
||||
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_construct = function(pos)
|
||||
minetest.get_node_timer(pos):start(1)
|
||||
end,
|
||||
on_timer = function(pos, elapsed)
|
||||
if minetest.get_node_light(pos) > 11 then
|
||||
minetest.set_node(pos, {name = "fireflies:hidden_firefly"})
|
||||
end
|
||||
minetest.get_node_timer(pos):start(30)
|
||||
end
|
||||
})
|
||||
|
||||
minetest.register_node("fireflies:hidden_firefly", {
|
||||
description = S("Hidden Firefly"),
|
||||
drawtype = "airlike",
|
||||
inventory_image = "fireflies_firefly.png^default_invisible_node_overlay.png",
|
||||
wield_image = "fireflies_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_construct = function(pos)
|
||||
minetest.get_node_timer(pos):start(1)
|
||||
end,
|
||||
on_timer = function(pos, elapsed)
|
||||
if minetest.get_node_light(pos) <= 11 then
|
||||
minetest.set_node(pos, {name = "fireflies:firefly"})
|
||||
end
|
||||
minetest.get_node_timer(pos):start(30)
|
||||
end
|
||||
})
|
||||
|
||||
|
||||
-- bug net
|
||||
minetest.register_tool("fireflies:bug_net", {
|
||||
description = S("Bug Net"),
|
||||
inventory_image = "fireflies_bugnet.png",
|
||||
pointabilities = {nodes = {["group:catchable"] = true}},
|
||||
tool_capabilities = {
|
||||
groupcaps = {
|
||||
catchable = { maxlevel = 1, uses = 256, times = { [1] = 0, [2] = 0, [3] = 0 } }
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
minetest.register_craft( {
|
||||
output = "fireflies:bug_net",
|
||||
recipe = {
|
||||
{"farming:string", "farming:string"},
|
||||
{"farming:string", "farming:string"},
|
||||
{"group:stick", ""}
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
-- firefly in a bottle
|
||||
minetest.register_node("fireflies:firefly_bottle", {
|
||||
description = S("Firefly in a Bottle"),
|
||||
inventory_image = "fireflies_bottle.png",
|
||||
wield_image = "fireflies_bottle.png",
|
||||
tiles = {{
|
||||
name = "fireflies_bottle_animated.png",
|
||||
animation = {
|
||||
type = "vertical_frames",
|
||||
aspect_w = 16,
|
||||
aspect_h = 16,
|
||||
length = 1.5
|
||||
},
|
||||
}},
|
||||
drawtype = "plantlike",
|
||||
paramtype = "light",
|
||||
sunlight_propagates = true,
|
||||
light_source = 9,
|
||||
walkable = false,
|
||||
groups = {vessel = 1, dig_immediate = 3, attached_node = 1},
|
||||
selection_box = {
|
||||
type = "fixed",
|
||||
fixed = {-0.25, -0.5, -0.25, 0.25, 0.3, 0.25}
|
||||
},
|
||||
sounds = default.node_sound_glass_defaults(),
|
||||
on_rightclick = function(pos, node, player, itemstack, pointed_thing)
|
||||
local lower_pos = {x = pos.x, y = pos.y + 1, z = pos.z}
|
||||
if minetest.is_protected(pos, player:get_player_name()) or
|
||||
minetest.get_node(lower_pos).name ~= "air" then
|
||||
return
|
||||
end
|
||||
|
||||
local upper_pos = {x = pos.x, y = pos.y + 2, z = pos.z}
|
||||
local firefly_pos
|
||||
|
||||
if not minetest.is_protected(upper_pos, player:get_player_name()) and
|
||||
minetest.get_node(upper_pos).name == "air" then
|
||||
firefly_pos = upper_pos
|
||||
elseif not minetest.is_protected(lower_pos, player:get_player_name()) then
|
||||
firefly_pos = lower_pos
|
||||
end
|
||||
|
||||
if firefly_pos then
|
||||
minetest.set_node(pos, {name = "vessels:glass_bottle"})
|
||||
minetest.set_node(firefly_pos, {name = "fireflies:firefly"})
|
||||
minetest.get_node_timer(firefly_pos):start(1)
|
||||
end
|
||||
end
|
||||
})
|
||||
|
||||
minetest.register_craft( {
|
||||
output = "fireflies:firefly_bottle",
|
||||
recipe = {
|
||||
{"fireflies:firefly"},
|
||||
{"vessels:glass_bottle"}
|
||||
}
|
||||
})
|
||||
|
||||
-- restart firefly timers
|
||||
minetest.register_lbm({
|
||||
name = "fireflies:firefly_timer",
|
||||
nodenames = {"fireflies:firefly", "fireflies:hidden_firefly"},
|
||||
run_at_every_load = true,
|
||||
|
||||
action = function(pos)
|
||||
minetest.get_node_timer(pos):start(math.random(1,5))
|
||||
end,
|
||||
})
|
58
mods/minetest_game/fireflies/license.txt
Normal file
58
mods/minetest_game/fireflies/license.txt
Normal file
|
@ -0,0 +1,58 @@
|
|||
License of source code
|
||||
----------------------
|
||||
|
||||
The MIT License (MIT)
|
||||
Copyright (c) 2018 Shara RedCat
|
||||
|
||||
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) 2018 Shara RedCat
|
||||
|
||||
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/
|
5
mods/minetest_game/fireflies/locale/fireflies.de.tr
Normal file
5
mods/minetest_game/fireflies/locale/fireflies.de.tr
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=Glühwürmchen
|
||||
Hidden Firefly=Verborgenes Glühwürmchen
|
||||
Bug Net=Insektennetz
|
||||
Firefly in a Bottle=Glühwürmchen in einer Flasche
|
5
mods/minetest_game/fireflies/locale/fireflies.eo.tr
Normal file
5
mods/minetest_game/fireflies/locale/fireflies.eo.tr
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=Lampiro
|
||||
Hidden Firefly=Kaŝita lampiro
|
||||
Bug Net=Insekta reto
|
||||
Firefly in a Bottle=Lampiro en botelo
|
5
mods/minetest_game/fireflies/locale/fireflies.es.tr
Normal file
5
mods/minetest_game/fireflies/locale/fireflies.es.tr
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=Luciérnaga
|
||||
Hidden Firefly=Luciérnaga oculta
|
||||
Bug Net=Red de insectos
|
||||
Firefly in a Bottle=Luciérnaga en botella
|
5
mods/minetest_game/fireflies/locale/fireflies.fr.tr
Normal file
5
mods/minetest_game/fireflies/locale/fireflies.fr.tr
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=Luciole
|
||||
Hidden Firefly=Luciole cachée
|
||||
Bug Net=Filet à papillon
|
||||
Firefly in a Bottle=Luciole en bouteille
|
5
mods/minetest_game/fireflies/locale/fireflies.id.tr
Normal file
5
mods/minetest_game/fireflies/locale/fireflies.id.tr
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=Kunang-Kunang
|
||||
Hidden Firefly=Kunang-Kunang Tersembunyi
|
||||
Bug Net=Jaring Serangga
|
||||
Firefly in a Bottle=Kunang-Kunang dalam Botol
|
5
mods/minetest_game/fireflies/locale/fireflies.it.tr
Normal file
5
mods/minetest_game/fireflies/locale/fireflies.it.tr
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=Lucciola
|
||||
Hidden Firefly=Lucciola nascosta
|
||||
Bug Net=Retino
|
||||
Firefly in a Bottle=Lucciola imbottigliata
|
5
mods/minetest_game/fireflies/locale/fireflies.ja.tr
Normal file
5
mods/minetest_game/fireflies/locale/fireflies.ja.tr
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=ホタル
|
||||
Hidden Firefly=隠されたホタル
|
||||
Bug Net=虫取り網
|
||||
Firefly in a Bottle=ホタルの入った瓶
|
5
mods/minetest_game/fireflies/locale/fireflies.jbo.tr
Normal file
5
mods/minetest_game/fireflies/locale/fireflies.jbo.tr
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=lo gusycinki
|
||||
Hidden Firefly=lo se mipri gusycinki
|
||||
Bug Net=lo cinki julne
|
||||
Firefly in a Bottle=lo gusycinki poi nenri lo botpi
|
5
mods/minetest_game/fireflies/locale/fireflies.lv.tr
Normal file
5
mods/minetest_game/fireflies/locale/fireflies.lv.tr
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=Jāņtārpiņš
|
||||
Hidden Firefly=Paslēpts jāņtārpiņš
|
||||
Bug Net=Ķeramtīkls
|
||||
Firefly in a Bottle=Jāņtārpiņš pudelē
|
5
mods/minetest_game/fireflies/locale/fireflies.ms.tr
Normal file
5
mods/minetest_game/fireflies/locale/fireflies.ms.tr
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=Kelip-Kelip
|
||||
Hidden Firefly=Kelip-Kelip Tersembunyi
|
||||
Bug Net=Jaring Pepijat
|
||||
Firefly in a Bottle=Kelip-Kelip dalam Botol
|
5
mods/minetest_game/fireflies/locale/fireflies.pl.tr
Normal file
5
mods/minetest_game/fireflies/locale/fireflies.pl.tr
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=Świetlik
|
||||
Hidden Firefly=Ukryty świetlik
|
||||
Bug Net=Siatka na owady
|
||||
Firefly in a Bottle=Świetlik w butelce
|
5
mods/minetest_game/fireflies/locale/fireflies.pt_BR.tr
Normal file
5
mods/minetest_game/fireflies/locale/fireflies.pt_BR.tr
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=Vaga-lume
|
||||
Hidden Firefly=Vaga-lume escondido
|
||||
Bug Net=Rede de Insetos
|
||||
Firefly in a Bottle=Vaga-lume em uma garrafa
|
5
mods/minetest_game/fireflies/locale/fireflies.ru.tr
Normal file
5
mods/minetest_game/fireflies/locale/fireflies.ru.tr
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=Светлячок
|
||||
Hidden Firefly=Притаившийся светлячок
|
||||
Bug Net=Сачок
|
||||
Firefly in a Bottle=Светлячок в бутылке
|
5
mods/minetest_game/fireflies/locale/fireflies.sk.tr
Normal file
5
mods/minetest_game/fireflies/locale/fireflies.sk.tr
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=Svetluška
|
||||
Hidden Firefly=Skrytá svetluška
|
||||
Bug Net=Sieťka na hmyz
|
||||
Firefly in a Bottle=Svetluška vo fľaši
|
5
mods/minetest_game/fireflies/locale/fireflies.sv.tr
Normal file
5
mods/minetest_game/fireflies/locale/fireflies.sv.tr
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=Eldfluga
|
||||
Hidden Firefly=Gömd eldfluga
|
||||
Bug Net=Insektshåv
|
||||
Firefly in a Bottle=Eldfluga i en flaska
|
5
mods/minetest_game/fireflies/locale/fireflies.uk.tr
Normal file
5
mods/minetest_game/fireflies/locale/fireflies.uk.tr
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=Світляк
|
||||
Hidden Firefly=Світляк, що причаївся
|
||||
Bug Net=Сачок
|
||||
Firefly in a Bottle=Світляк у пляшці
|
5
mods/minetest_game/fireflies/locale/fireflies.zh_CN.tr
Normal file
5
mods/minetest_game/fireflies/locale/fireflies.zh_CN.tr
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=萤火虫
|
||||
Hidden Firefly=隐藏的萤火虫
|
||||
Bug Net=虫网
|
||||
Firefly in a Bottle=放在瓶子里的萤火虫
|
5
mods/minetest_game/fireflies/locale/fireflies.zh_TW.tr
Normal file
5
mods/minetest_game/fireflies/locale/fireflies.zh_TW.tr
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=螢火蟲
|
||||
Hidden Firefly=隱藏的螢火蟲
|
||||
Bug Net=蟲網
|
||||
Firefly in a Bottle=放在瓶子裡的螢火蟲
|
5
mods/minetest_game/fireflies/locale/template.txt
Normal file
5
mods/minetest_game/fireflies/locale/template.txt
Normal file
|
@ -0,0 +1,5 @@
|
|||
# textdomain: fireflies
|
||||
Firefly=
|
||||
Hidden Firefly=
|
||||
Bug Net=
|
||||
Firefly in a Bottle=
|
3
mods/minetest_game/fireflies/mod.conf
Normal file
3
mods/minetest_game/fireflies/mod.conf
Normal file
|
@ -0,0 +1,3 @@
|
|||
name = fireflies
|
||||
description = Minetest Game mod: fireflies
|
||||
depends = default, vessels
|
BIN
mods/minetest_game/fireflies/textures/fireflies_bottle.png
Normal file
BIN
mods/minetest_game/fireflies/textures/fireflies_bottle.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 172 B |
Binary file not shown.
After Width: | Height: | Size: 203 B |
BIN
mods/minetest_game/fireflies/textures/fireflies_bugnet.png
Normal file
BIN
mods/minetest_game/fireflies/textures/fireflies_bugnet.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 192 B |
BIN
mods/minetest_game/fireflies/textures/fireflies_firefly.png
Normal file
BIN
mods/minetest_game/fireflies/textures/fireflies_firefly.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 113 B |
Binary file not shown.
After Width: | Height: | Size: 121 B |
Loading…
Add table
Add a link
Reference in a new issue