Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • Illuna-Minetest/minetest_game
  • ClaudiusMinimus/minetest_game
  • xthediamondlegox/minetest_game
  • Elvas/minetest_game
4 results
Show changes
Commits on Source (1855)
name: build
on: [push, pull_request]
jobs:
luacheck:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install Luarocks
run: |
sudo apt-get update -qyy
sudo apt-get install luarocks -qyy
- name: Install Luacheck
run: luarocks install --local luacheck
- name: Run Luacheck
run: $HOME/.luarocks/bin/luacheck mods
variables:
GIT_SUBMODULE_STRATEGY: recursive
stages:
- check
code-quality:
image: registry.gitlab.com/craigbarnes/dockerfiles/lua-testing
interruptible: true
stage: check
retry:
max: 2
when:
- runner_system_failure
- stuck_or_timeout_failure
script:
- luarocks install luacheck
- luacheck mods
[submodule "mods/boats"]
path = mods/boats
url = https://github.com/tenplus1/boats.git
[submodule "mods/illuna"]
path = mods/illuna
url = https://git.tchncs.de/Illuna-Minetest/illuna.git
[submodule "mods/death_message"]
path = mods/death_messages
url = https://git.tchncs.de/Illuna-Minetest/death_message.git
url = ../../Illuna-Minetest/illuna.git
[submodule "mods/wine"]
path = mods/wine
url = https://github.com/tenplus1/wine
url = https://notabug.org/TenPlus1/wine
[submodule "mods/death_messages"]
path = mods/death_messages
url = https://git.tchncs.de/Illuna-Minetest/death_messages.git
[submodule "mods/mobs_redo"]
path = mods/mobs_redo
url = https://github.com/tenplus1/mobs_redo
[submodule "mods/mobs_animal"]
path = mods/mobs_animal
url = https://git.tchncs.de/Illuna-Minetest/mobs_animal.git
[submodule "mods/mobs_monster"]
path = mods/mobs_monster
url = https://github.com/tenplus1/mobs_monster
[submodule "mods/farming"]
path = mods/farming
url = https://git.tchncs.de/Illuna-Minetest/farming.git
url = ../../Illuna-Minetest/death_messages.git
[submodule "mods/worldedit"]
path = mods/worldedit
url = https://github.com/Uberi/Minetest-WorldEdit
[submodule "mods/3d_armor"]
path = mods/3d_armor
url = https://github.com/stujones11/minetest-3d_armor
[submodule "mods/plantlife_modpack"]
path = mods/plantlife_modpack
url = https://git.tchncs.de/Illuna-Minetest/plantlife_modpack.git
[submodule "mods/darkage"]
path = mods/darkage
url = https://git.tchncs.de/Illuna-Minetest/darkage.git
[submodule "mods/hudbars"]
path = mods/hudbars
url = https://git.tchncs.de/Illuna-Minetest/hudbars.git
[submodule "mods/xdecor"]
path = mods/xdecor
url = https://git.tchncs.de/Illuna-Minetest/xdecor.git
[submodule "mods/caverealms"]
path = mods/caverealms
url = https://git.tchncs.de/Illuna-Minetest/caverealms.git
url = ../../Illuna-Minetest/xdecor.git
[submodule "mods/wardrobe"]
path = mods/wardrobe
url = https://git.tchncs.de/Illuna-Minetest/wardrobe.git
url = ../../Illuna-Minetest/wardrobe.git
[submodule "mods/ctravelnet"]
path = mods/ctravelnet
url = https://git.tchncs.de/Illuna-Minetest/ctravelnet.git
[submodule "mods/bags"]
path = mods/bags
url = https://git.tchncs.de/Illuna-Minetest/bags.git
url = ../../Illuna-Minetest/ctravelnet.git
[submodule "mods/cottages"]
path = mods/cottages
url = https://git.tchncs.de/Illuna-Minetest/cottages.git/
[submodule "mods/horses"]
path = mods/horses
url = https://git.tchncs.de/Illuna-Minetest/horses.git
url = ../../Illuna-Minetest/cottages.git/
[submodule "mods/bows"]
path = mods/bows
url = ../../Illuna-Minetest/bows
branch = master
[submodule "mods/pkarcs"]
path = mods/pkarcs
url = ../../Illuna-Minetest/pkarcs
[submodule "mods/columnia"]
path = mods/columnia
url = ../../Illuna-Minetest/columnia
[submodule "mods/homedecor_modpack"]
path = mods/homedecor_modpack
url = ../../Illuna-Minetest/homedecor_modpack
[submodule "mods/magical_potion"]
path = mods/magical_potion
url = ../../Illuna-Minetest/magical_potion
[submodule "mods/mtfoods"]
path = mods/mtfoods
url = https://github.com/Philipbenr/mtfoods
[submodule "mods/mtcandy"]
path = mods/mtcandy
url = ../../Illuna-Minetest/mtcandy
[submodule "mods/teleport_potion"]
path = mods/teleport_potion
url = ../../Illuna-Minetest/teleport_potion
[submodule "mods/halloween_mobs"]
path = mods/halloween_mobs
url = ../../Illuna-Minetest/halloween_mobs
[submodule "mods/ethereal"]
path = mods/ethereal
url = ../../Illuna-Minetest/ethereal
[submodule "mods/technic"]
path = mods/technic
url = ../../Illuna-Minetest/technic
[submodule "mods/markers"]
path = mods/markers
url = https://github.com/Sokomine/markers
[submodule "mods/golems"]
path = mods/golems
url = ../../Illuna-Minetest/golems
[submodule "mods/princess"]
path = mods/princess
url = https://github.com/pithydon/princess
[submodule "mods/city_block"]
path = mods/city_block
url = https://github.com/minetest-mods/city_block
[submodule "mods/glow"]
path = mods/glow
url = https://github.com/bdjnk/glow
[submodule "mods/character_creator"]
path = mods/character_creator
url = https://github.com/minetest-mods/character_creator
[submodule "mods/illuna_ethereal"]
path = mods/illuna_ethereal
url = ../../Illuna-Minetest/illuna_ethereal
[submodule "mods/bacon"]
path = mods/bacon
url = https://github.com/mootpoint/bacon
[submodule "mods/geomoria"]
path = mods/geomoria
url = https://github.com/duane-r/geomoria
[submodule "mods/integral"]
path = mods/integral
url = ../../Illuna-Minetest/integral
[submodule "mods/illuna_extras"]
path = mods/illuna_extras
url = ../../Illuna-Minetest/illuna_extras
[submodule "mods/underworlds"]
path = mods/underworlds
url = ../../Illuna-Minetest/underworlds
[submodule "mods/caverealms"]
path = mods/caverealms
url = ../../Illuna-Minetest/caverealms
[submodule "mods/fun_caves"]
path = mods/fun_caves
url = ../../Illuna-Minetest/fun_caves
[submodule "mods/hopper"]
path = mods/hopper
url = https://github.com/minetest-mods/hopper
[submodule "mods/digilines"]
path = mods/digilines
url = https://github.com/minetest-mods/digilines
[submodule "mods/turtle"]
path = mods/turtle
url = https://github.com/minetest-mods/turtle
[submodule "mods/xconnected"]
path = mods/xconnected
url = https://github.com/Sokomine/xconnected
[submodule "mods/under_sky"]
path = mods/under_sky
url = https://github.com/Ezhh/under_sky
[submodule "mods/travelnet"]
path = mods/travelnet
url = https://github.com/Sokomine/travelnet
[submodule "mods/torches"]
path = mods/torches
url = https://github.com/minetest-mods/torches
[submodule "mods/steel"]
path = mods/steel
url = ../../Illuna-Minetest/steel
[submodule "mods/replacer"]
path = mods/replacer
url = https://github.com/Sokomine/replacer
[submodule "mods/quartz"]
path = mods/quartz
url = https://github.com/minetest-mods/quartz
[submodule "mods/names_per_ip"]
path = mods/names_per_ip
url = https://github.com/SmallJoker/names_per_ip
[submodule "mods/mobs_more_monsters"]
path = mods/mobs_more_monsters
url = ../../Illuna-Minetest/mobs_more_monsters
[submodule "mods/moreores"]
path = mods/moreores
url = ../../Illuna-Minetest/moreores
[submodule "mods/wiki"]
path = mods/wiki
url = ../../Illuna-Minetest/wiki
[submodule "mods/mg_villages"]
path = mods/mg_villages
url = https://github.com/Sokomine/mg_villages
[submodule "mods/handle_schematics"]
path = mods/handle_schematics
url = https://github.com/Sokomine/handle_schematics
[submodule "mods/unified_inventory"]
path = mods/unified_inventory
url = ../../Illuna-Minetest/unified_inventory
[submodule "modpacks/mydoors"]
path = modpacks/mydoors
url = https://github.com/minetest-mods/mydoors
[submodule "mods/sneak_glitch"]
path = mods/sneak_glitch
url = https://github.com/SmallJoker/sneak_glitch
[submodule "mods/mycastle"]
path = mods/mycastle
url = ../../Illuna-Minetest/mycastle
[submodule "mods/mesecons"]
path = mods/mesecons
url = ../../Illuna-Minetest/mesecons
[submodule "mods/other_worlds"]
path = mods/other_worlds
url = ../../Illuna-Minetest/other_worlds
[submodule "mods/loud_walking"]
path = mods/loud_walking
url = ../../Illuna-Minetest/loud_walking
[submodule "mods/playerskins"]
path = mods/playerskins
url = ../../Illuna-Minetest/playerskins
[submodule "mods/dmobs"]
path = mods/dmobs
url = ../../Illuna-Minetest/dmobs
[submodule "mods/mobs_animal"]
path = mods/mobs_animal
url = ../../Illuna-Minetest/mobs_animal
[submodule "mods/mobs_monster"]
path = mods/mobs_monster
url = ../../Illuna-Minetest/mobs_monster
[submodule "mods/mobs_redo"]
path = mods/mobs_redo
url = ../../Illuna-Minetest/mobs_redo
[submodule "mods/basic_robot"]
path = mods/basic_robot
url = ../../Illuna-Minetest/basic_robot
[submodule "mods/irc"]
path = mods/irc
url = ../../Illuna-Minetest/irc
[submodule "mods/playereffects"]
path = mods/playereffects
url = ../../Illuna-Minetest/playereffects
[submodule "mods/chat3"]
path = mods/chat3
url = ../../Illuna-Minetest/chat3
[submodule "mods/protector"]
path = mods/protector
url = ../../Illuna-Minetest/protector
[submodule "mods/illuna_costumes"]
path = mods/illuna_costumes
url = ../../Illuna-Minetest/illuna_costumes
[submodule "mods/areas"]
path = mods/areas
url = ../../Illuna-Minetest/areas
[submodule "mods/3d_armor"]
path = mods/3d_armor
url = ../../Illuna-Minetest/3d_armor
[submodule "mods/technic_armor"]
path = mods/technic_armor
url = https://github.com/stujones11/technic_armor
[submodule "mods/hazmat_suit"]
path = mods/hazmat_suit
url = https://github.com/stujones11/hazmat_suit
[submodule "mods/player_monoids"]
path = mods/player_monoids
url = https://github.com/minetest-mods/player_monoids
[submodule "mods/mob_horse"]
path = mods/mob_horse
url = ../../Illuna-Minetest/mob_horse
[submodule "mods/matrix"]
path = mods/matrix
url = https://github.com/entuland/lua-matrix
[submodule "mods/rhotator"]
path = mods/rhotator
url = ../../Illuna-Minetest/rhotator
[submodule "mods/sea"]
path = mods/sea
url = ../../Illuna-Minetest/minetest-mod-sea
[submodule "mods/xban2"]
path = mods/xban2
url = https://github.com/minetest-mods/xban2
branch = master
[submodule "mods/chakram"]
path = mods/chakram
url = ../../Illuna-Minetest/chakram
[submodule "mods/hangglider"]
path = mods/hangglider
url = ../../Illuna-Minetest/minetest-hangglider
[submodule "mods/hangglider_regular"]
path = mods/hangglider_regular
url = ../../Illuna-Minetest/minetest-hangglider-regular
[submodule "mods/illuna_events"]
path = mods/illuna_events
url = ../../Illuna-Minetest/illuna_events.git
[submodule "mods/eventkeys"]
path = mods/eventkeys
url = https://github.com/auouymous/eventkeys
[submodule "mods/cloaking"]
path = mods/cloaking
url = https://github.com/luk3yx/minetest-cloaking
[submodule "mods/moreblocks"]
path = mods/moreblocks
url = https://github.com/minetest-mods/moreblocks
[submodule "mods/arrow_signs"]
path = mods/arrow_signs
url = https://bitbucket.org/adrido/arrow_signs/
[submodule "mods/bitchange"]
path = mods/bitchange
url = ../../Illuna-Minetest/bitchange
[submodule "mods/bridges"]
path = mods/bridges
url = https://github.com/Sokomine/bridges
[submodule "mods/christmas_craft"]
path = mods/christmas_craft
url = ../../Illuna-Minetest/christmas_craft
[submodule "mods/maptools"]
path = mods/maptools
url = https://github.com/calinou/maptools
[submodule "mods/medieval_craft"]
path = mods/medieval_craft
url = https://bitbucket.org/kingarthursteam/medieval_craft
[submodule "mods/mobf_trader"]
path = mods/mobf_trader
url = https://github.com/Sokomine/mobf_trader
[submodule "mods/spawners"]
path = mods/spawners
url = ../../Illuna-Minetest/spawners
[submodule "mods/skybox"]
path = mods/skybox
url = ../../Illuna-Minetest/skybox
[submodule "mods/moreglass"]
path = mods/moreglass
url = ../../Illuna-Minetest/moreglass.git
[submodule "mods/hbsprint"]
path = mods/hbsprint
url = https://github.com/minetest-mods/hbsprint
[submodule "mods/hudbars"]
path = mods/hudbars
url = https://repo.or.cz/minetest_hudbars.git
[submodule "mods/hbarmor"]
path = mods/hbarmor
url = git://repo.or.cz/minetest_hbarmor.git
[submodule "mods/hbhunger"]
path = mods/hbhunger
url = https://repo.or.cz/minetest_hbhunger.git
[submodule "mods/headanim"]
path = mods/headanim
url = https://github.com/LoneWolfHT/headanim/
[submodule "mods/medieval_inner_glasses"]
path = mods/medieval_inner_glasses
url = https://github.com/kodrag/medieval-inner-glasses
[submodule "mods/we_undo"]
path = mods/we_undo
url = https://github.com/HybridDog/we_undo
[submodule "mods/basic_materials"]
path = mods/basic_materials
url = https://github.com/mt-mods/basic_materials
[submodule "mods/basic_signs"]
path = mods/basic_signs
url = https://github.com/mt-mods/basic_signs
[submodule "mods/biome_lib"]
path = mods/biome_lib
url = https://github.com/mt-mods/biome_lib
[submodule "mods/pipeworks"]
path = mods/pipeworks
url = https://github.com/mt-mods/pipeworks
[submodule "mods/signs_lib"]
path = mods/signs_lib
url = https://github.com/mt-mods/signs_lib
[submodule "mods/unifieddyes"]
path = mods/unifieddyes
url = https://github.com/mt-mods/unifieddyes
[submodule "mods/colored_eggs"]
path = mods/colored_eggs
url = https://github.com/auouymous/colored_eggs
[submodule "mods/monitoring"]
path = mods/monitoring
url = https://github.com/minetest-monitoring/monitoring
ignore = {
-- list taken from https://stackoverflow.com/questions/49158143/how-to-ignore-luacheck-warnings/49160695#56618022 as
-- all the third party mods would be hard to manage otherwise
--"011", -- A syntax error.
--"021", -- An invalid inline option.
"022", -- An unpaired inline push directive.
"023", -- An unpaired inline pop directive.
"111", -- Setting an undefined global variable.
"112", -- Mutating an undefined global variable.
"113", -- Accessing an undefined global variable.
"121", -- Setting a read-only global variable.
"122", -- Setting a read-only field of a global variable.
"131", -- Unused implicitly defined global variable.
"142", -- Setting an undefined field of a global variable.
"143", -- Accessing an undefined field of a global variable.
"211", -- Unused local variable.
"212", -- Unused argument.
"213", -- Unused loop variable.
"221", -- Local variable is accessed but never set.
"231", -- Local variable is set but never accessed.
"232", -- An argument is set but never accessed.
"233", -- Loop variable is set but never accessed.
"241", -- Local variable is mutated but never accessed.
"311", -- Value assigned to a local variable is unused.
"312", -- Value of an argument is unused.
"313", -- Value of a loop variable is unused.
"314", -- Value of a field in a table literal is unused.
"321", -- Accessing uninitialized local variable.
"331", -- Value assigned to a local variable is mutated but never accessed.
"341", -- Mutating uninitialized local variable.
"411", -- Redefining a local variable.
"412", -- Redefining an argument.
"413", -- Redefining a loop variable.
"421", -- Shadowing a local variable.
"422", -- Shadowing an argument.
"423", -- Shadowing a loop variable.
"431", -- Shadowing an upvalue.
"432", -- Shadowing an upvalue argument.
"433", -- Shadowing an upvalue loop variable.
"511", -- Unreachable code.
"512", -- Loop can be executed at most once.
"521", -- Unused label.
"531", -- Left-hand side of an assignment is too short.
"532", -- Left-hand side of an assignment is too long.
"541", -- An empty do end block.
"542", -- An empty if branch.
"551", -- An empty statement.
"561", -- Cyclomatic complexity of a function is too high.
"571", -- A numeric for loop goes from #(expr) down to 1 or less without negative step.
"611", -- A line consists of nothing but whitespace.
"612", -- A line contains trailing whitespace.
"613", -- Trailing whitespace in a string.
"614", -- Trailing whitespace in a comment.
"621", -- Inconsistent indentation (SPACE followed by TAB).
"631", -- Line is too long.
}
License of media (textures and sounds)
--------------------------------------
Copyright (C) 2010-2012 celeron55, Perttu Ahola <celeron55@gmail.com>
See README.txt in each mod directory for information about other authors.
Attribution-ShareAlike 3.0 Unported (CC BY-SA 3.0)
http://creativecommons.org/licenses/by-sa/3.0/
License of menu/header.png
Copyright (C) 2015 paramat CC BY-SA 3.0
License of source code
----------------------
Copyright (C) 2010-2012 celeron55, Perttu Ahola <celeron55@gmail.com>
See README.txt in each mod directory for information about other authors.
GNU LESSER GENERAL PUBLIC LICENSE
Version 2.1, February 1999
Copyright (C) 1991, 1999 Free Software Foundation, Inc.
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
[This is the first released version of the Lesser GPL. It also counts
as the successor of the GNU Library Public License, version 2, hence
the version number 2.1.]
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
Licenses are intended to guarantee your freedom to share and change
free software--to make sure the software is free for all its users.
This license, the Lesser General Public License, applies to some
specially designated software packages--typically libraries--of the
Free Software Foundation and other authors who decide to use it. You
can use it too, but we suggest you first think carefully about whether
this license or the ordinary General Public License is the better
strategy to use in any particular case, based on the explanations below.
When we speak of free software, we are referring to freedom of use,
not price. Our General Public Licenses are designed to make sure that
you have the freedom to distribute copies of free software (and charge
for this service if you wish); that you receive source code or can get
it if you want it; that you can change the software and use pieces of
it in new free programs; and that you are informed that you can do
these things.
To protect your rights, we need to make restrictions that forbid
distributors to deny you these rights or to ask you to surrender these
rights. These restrictions translate to certain responsibilities for
you if you distribute copies of the library or if you modify it.
For example, if you distribute copies of the library, whether gratis
or for a fee, you must give the recipients all the rights that we gave
you. You must make sure that they, too, receive or can get the source
code. If you link other code with the library, you must provide
complete object files to the recipients, so that they can relink them
with the library after making changes to the library and recompiling
it. And you must show them these terms so they know their rights.
We protect your rights with a two-step method: (1) we copyright the
library, and (2) we offer you this license, which gives you legal
permission to copy, distribute and/or modify the library.
To protect each distributor, we want to make it very clear that
there is no warranty for the free library. Also, if the library is
modified by someone else and passed on, the recipients should know
that what they have is not the original version, so that the original
author's reputation will not be affected by problems that might be
introduced by others.
Finally, software patents pose a constant threat to the existence of
any free program. We wish to make sure that a company cannot
effectively restrict the users of a free program by obtaining a
restrictive license from a patent holder. Therefore, we insist that
any patent license obtained for a version of the library must be
consistent with the full freedom of use specified in this license.
Most GNU software, including some libraries, is covered by the
ordinary GNU General Public License. This license, the GNU Lesser
General Public License, applies to certain designated libraries, and
is quite different from the ordinary General Public License. We use
this license for certain libraries in order to permit linking those
libraries into non-free programs.
When a program is linked with a library, whether statically or using
a shared library, the combination of the two is legally speaking a
combined work, a derivative of the original library. The ordinary
General Public License therefore permits such linking only if the
entire combination fits its criteria of freedom. The Lesser General
Public License permits more lax criteria for linking other code with
the library.
We call this license the "Lesser" General Public License because it
does Less to protect the user's freedom than the ordinary General
Public License. It also provides other free software developers Less
of an advantage over competing non-free programs. These disadvantages
are the reason we use the ordinary General Public License for many
libraries. However, the Lesser license provides advantages in certain
special circumstances.
For example, on rare occasions, there may be a special need to
encourage the widest possible use of a certain library, so that it becomes
a de-facto standard. To achieve this, non-free programs must be
allowed to use the library. A more frequent case is that a free
library does the same job as widely used non-free libraries. In this
case, there is little to gain by limiting the free library to free
software only, so we use the Lesser General Public License.
In other cases, permission to use a particular library in non-free
programs enables a greater number of people to use a large body of
free software. For example, permission to use the GNU C Library in
non-free programs enables many more people to use the whole GNU
operating system, as well as its variant, the GNU/Linux operating
system.
Although the Lesser General Public License is Less protective of the
users' freedom, it does ensure that the user of a program that is
linked with the Library has the freedom and the wherewithal to run
that program using a modified version of the Library.
The precise terms and conditions for copying, distribution and
modification follow. Pay close attention to the difference between a
"work based on the library" and a "work that uses the library". The
former contains code derived from the library, whereas the latter must
be combined with the library in order to run.
GNU LESSER GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License Agreement applies to any software library or other
program which contains a notice placed by the copyright holder or
other authorized party saying it may be distributed under the terms of
this Lesser General Public License (also called "this License").
Each licensee is addressed as "you".
A "library" means a collection of software functions and/or data
prepared so as to be conveniently linked with application programs
(which use some of those functions and data) to form executables.
The "Library", below, refers to any such software library or work
which has been distributed under these terms. A "work based on the
Library" means either the Library or any derivative work under
copyright law: that is to say, a work containing the Library or a
portion of it, either verbatim or with modifications and/or translated
straightforwardly into another language. (Hereinafter, translation is
included without limitation in the term "modification".)
"Source code" for a work means the preferred form of the work for
making modifications to it. For a library, complete source code means
all the source code for all modules it contains, plus any associated
interface definition files, plus the scripts used to control compilation
and installation of the library.
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running a program using the Library is not restricted, and output from
such a program is covered only if its contents constitute a work based
on the Library (independent of the use of the Library in a tool for
writing it). Whether that is true depends on what the Library does
and what the program that uses the Library does.
1. You may copy and distribute verbatim copies of the Library's
complete source code as you receive it, in any medium, provided that
you conspicuously and appropriately publish on each copy an
appropriate copyright notice and disclaimer of warranty; keep intact
all the notices that refer to this License and to the absence of any
warranty; and distribute a copy of this License along with the
Library.
You may charge a fee for the physical act of transferring a copy,
and you may at your option offer warranty protection in exchange for a
fee.
2. You may modify your copy or copies of the Library or any portion
of it, thus forming a work based on the Library, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
a) The modified work must itself be a software library.
b) You must cause the files modified to carry prominent notices
stating that you changed the files and the date of any change.
c) You must cause the whole of the work to be licensed at no
charge to all third parties under the terms of this License.
d) If a facility in the modified Library refers to a function or a
table of data to be supplied by an application program that uses
the facility, other than as an argument passed when the facility
is invoked, then you must make a good faith effort to ensure that,
in the event an application does not supply such function or
table, the facility still operates, and performs whatever part of
its purpose remains meaningful.
(For example, a function in a library to compute square roots has
a purpose that is entirely well-defined independent of the
application. Therefore, Subsection 2d requires that any
application-supplied function or table used by this function must
be optional: if the application does not supply it, the square
root function must still compute square roots.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Library,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Library, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote
it.
Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Library.
In addition, mere aggregation of another work not based on the Library
with the Library (or with a work based on the Library) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
3. You may opt to apply the terms of the ordinary GNU General Public
License instead of this License to a given copy of the Library. To do
this, you must alter all the notices that refer to this License, so
that they refer to the ordinary GNU General Public License, version 2,
instead of to this License. (If a newer version than version 2 of the
ordinary GNU General Public License has appeared, then you can specify
that version instead if you wish.) Do not make any other change in
these notices.
Once this change is made in a given copy, it is irreversible for
that copy, so the ordinary GNU General Public License applies to all
subsequent copies and derivative works made from that copy.
This option is useful when you wish to copy part of the code of
the Library into a program that is not a library.
4. You may copy and distribute the Library (or a portion or
derivative of it, under Section 2) in object code or executable form
under the terms of Sections 1 and 2 above provided that you accompany
it with the complete corresponding machine-readable source code, which
must be distributed under the terms of Sections 1 and 2 above on a
medium customarily used for software interchange.
If distribution of object code is made by offering access to copy
from a designated place, then offering equivalent access to copy the
source code from the same place satisfies the requirement to
distribute the source code, even though third parties are not
compelled to copy the source along with the object code.
5. A program that contains no derivative of any portion of the
Library, but is designed to work with the Library by being compiled or
linked with it, is called a "work that uses the Library". Such a
work, in isolation, is not a derivative work of the Library, and
therefore falls outside the scope of this License.
However, linking a "work that uses the Library" with the Library
creates an executable that is a derivative of the Library (because it
contains portions of the Library), rather than a "work that uses the
library". The executable is therefore covered by this License.
Section 6 states terms for distribution of such executables.
When a "work that uses the Library" uses material from a header file
that is part of the Library, the object code for the work may be a
derivative work of the Library even though the source code is not.
Whether this is true is especially significant if the work can be
linked without the Library, or if the work is itself a library. The
threshold for this to be true is not precisely defined by law.
If such an object file uses only numerical parameters, data
structure layouts and accessors, and small macros and small inline
functions (ten lines or less in length), then the use of the object
file is unrestricted, regardless of whether it is legally a derivative
work. (Executables containing this object code plus portions of the
Library will still fall under Section 6.)
Otherwise, if the work is a derivative of the Library, you may
distribute the object code for the work under the terms of Section 6.
Any executables containing that work also fall under Section 6,
whether or not they are linked directly with the Library itself.
6. As an exception to the Sections above, you may also combine or
link a "work that uses the Library" with the Library to produce a
work containing portions of the Library, and distribute that work
under terms of your choice, provided that the terms permit
modification of the work for the customer's own use and reverse
engineering for debugging such modifications.
You must give prominent notice with each copy of the work that the
Library is used in it and that the Library and its use are covered by
this License. You must supply a copy of this License. If the work
during execution displays copyright notices, you must include the
copyright notice for the Library among them, as well as a reference
directing the user to the copy of this License. Also, you must do one
of these things:
a) Accompany the work with the complete corresponding
machine-readable source code for the Library including whatever
changes were used in the work (which must be distributed under
Sections 1 and 2 above); and, if the work is an executable linked
with the Library, with the complete machine-readable "work that
uses the Library", as object code and/or source code, so that the
user can modify the Library and then relink to produce a modified
executable containing the modified Library. (It is understood
that the user who changes the contents of definitions files in the
Library will not necessarily be able to recompile the application
to use the modified definitions.)
b) Use a suitable shared library mechanism for linking with the
Library. A suitable mechanism is one that (1) uses at run time a
copy of the library already present on the user's computer system,
rather than copying library functions into the executable, and (2)
will operate properly with a modified version of the library, if
the user installs one, as long as the modified version is
interface-compatible with the version that the work was made with.
c) Accompany the work with a written offer, valid for at
least three years, to give the same user the materials
specified in Subsection 6a, above, for a charge no more
than the cost of performing this distribution.
d) If distribution of the work is made by offering access to copy
from a designated place, offer equivalent access to copy the above
specified materials from the same place.
e) Verify that the user has already received a copy of these
materials or that you have already sent this user a copy.
For an executable, the required form of the "work that uses the
Library" must include any data and utility programs needed for
reproducing the executable from it. However, as a special exception,
the materials to be distributed need not include anything that is
normally distributed (in either source or binary form) with the major
components (compiler, kernel, and so on) of the operating system on
which the executable runs, unless that component itself accompanies
the executable.
It may happen that this requirement contradicts the license
restrictions of other proprietary libraries that do not normally
accompany the operating system. Such a contradiction means you cannot
use both them and the Library together in an executable that you
distribute.
7. You may place library facilities that are a work based on the
Library side-by-side in a single library together with other library
facilities not covered by this License, and distribute such a combined
library, provided that the separate distribution of the work based on
the Library and of the other library facilities is otherwise
permitted, and provided that you do these two things:
a) Accompany the combined library with a copy of the same work
based on the Library, uncombined with any other library
facilities. This must be distributed under the terms of the
Sections above.
b) Give prominent notice with the combined library of the fact
that part of it is a work based on the Library, and explaining
where to find the accompanying uncombined form of the same work.
8. You may not copy, modify, sublicense, link with, or distribute
the Library except as expressly provided under this License. Any
attempt otherwise to copy, modify, sublicense, link with, or
distribute the Library is void, and will automatically terminate your
rights under this License. However, parties who have received copies,
or rights, from you under this License will not have their licenses
terminated so long as such parties remain in full compliance.
9. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Library or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Library (or any work based on the
Library), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Library or works based on it.
10. Each time you redistribute the Library (or any work based on the
Library), the recipient automatically receives a license from the
original licensor to copy, distribute, link with or modify the Library
subject to these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties with
this License.
11. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Library at all. For example, if a patent
license would not permit royalty-free redistribution of the Library by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Library.
If any portion of this section is held invalid or unenforceable under any
particular circumstance, the balance of the section is intended to apply,
and the section as a whole is intended to apply in other circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
12. If the distribution and/or use of the Library is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Library under this License may add
an explicit geographical distribution limitation excluding those countries,
so that distribution is permitted only in or among countries not thus
excluded. In such case, this License incorporates the limitation as if
written in the body of this License.
13. The Free Software Foundation may publish revised and/or new
versions of the Lesser General Public License from time to time.
Such new versions will be similar in spirit to the present version,
but may differ in detail to address new problems or concerns.
Each version is given a distinguishing version number. If the Library
specifies a version number of this License which applies to it and
"any later version", you have the option of following the terms and
conditions either of that version or of any later version published by
the Free Software Foundation. If the Library does not specify a
license version number, you may choose any version ever published by
the Free Software Foundation.
14. If you wish to incorporate parts of the Library into other free
programs whose distribution conditions are incompatible with these,
write to the author to ask for permission. For software which is
copyrighted by the Free Software Foundation, write to the Free
Software Foundation; we sometimes make exceptions for this. Our
decision will be guided by the two goals of preserving the free status
of all derivatives of our free software and of promoting the sharing
and reuse of software generally.
NO WARRANTY
15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY
KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE
LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
DAMAGES.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Libraries
If you develop a new library, and you want it to be of the greatest
possible use to the public, we recommend making it free software that
everyone can redistribute and change. You can do so by permitting
redistribution under these terms (or, alternatively, under the terms of the
ordinary General Public License).
To apply these terms, attach the following notices to the library. It is
safest to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least the
"copyright" line and a pointer to where the full notice is found.
<one line to give the library's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Also add information on how to contact you by electronic and paper mail.
You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the library, if
necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the
library `Frob' (a library for tweaking knobs) written by James Random Hacker.
<signature of Ty Coon>, 1 April 1990
Ty Coon, President of Vice
That's all there is to it!
# Minetest Game
The default game bundled in the Minetest engine.
For further information, check [this forum topic](https://forum.minetest.net/viewtopic.php?f=15&t=9724).
Also see the [Minetest Wiki](https://wiki.minetest.net/Subgames/Minetest_Game) for more information.
## Installation
- Unzip the archive, rename the folder to `minetest_game` and
place it in .. `minetest/games/`
- GNU/Linux: If you use a system-wide installation place it in `~/.minetest/games/`.
The Minetest engine can be found at [GitHub](https://github.com/minetest/minetest).
For further information or help, see: [Installing Mods](https://wiki.minetest.net/Installing_Mods).
## Compatibility
The Minetest Game GitHub `master` `HEAD` is generally compatible with the GitHub
`master` `HEAD` of the Minetest engine.
Additionally, when the Minetest engine is tagged to be a certain version (e.g.
`0.4.10`), Minetest Game is tagged with the version, too.
When stable releases are made, Minetest Game and the Minetest engine is packaged
and made available at [www.minetest.net](https://www.minetest.net/downloads/).
## Licensing
See `LICENSE.txt`
Minetest Game [minetest_game]
=============================
The main subgame for the Minetest engine
========================================
To use this subgame with the Minetest engine, insert this repository as
/games/minetest_game
The Minetest engine can be found in:
https://github.com/minetest/minetest/
Compatibility
--------------
The Minetest Game github master HEAD is generally compatible with the github
master HEAD of the Minetest engine.
Additionally, when the Minetest engine is tagged to be a certain version (eg.
0.4.10), Minetest Game is tagged with the version too.
When stable releases are made, Minetest Game is packaged and made available in
http://minetest.net/download
and in case the repository has grown too much, it may be reset. In that sense,
this is not a "real" git repository. (Package maintainers please note!)
License of source code
----------------------
Copyright (C) 2010-2012 celeron55, Perttu Ahola <celeron55@gmail.com>
See README.txt in each mod directory for information about other authors.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation; either version 2.1 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public License along
with this program; if not, write to the Free Software Foundation, Inc.,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
License of media (textures and sounds)
--------------------------------------
Copyright (C) 2010-2012 celeron55, Perttu Ahola <celeron55@gmail.com>
See README.txt in each mod directory for information about other authors.
Attribution-ShareAlike 3.0 Unported (CC BY-SA 3.0)
http://creativecommons.org/licenses/by-sa/3.0/
License of menu/header.png
Copyright (C) 2015 paramat CC BY-SA 3.0
name = Minetest Game
title = TechEth Game
author = Minetest, Illuna
description = Game of the Illuna TechEth flagship-server, based on the official minetest_game
......@@ -2,32 +2,41 @@ Minetest Game API
=================
GitHub Repo: https://github.com/minetest/minetest_game
Introduction
------------
The Minetest Game subgame offers multiple new possibilities in addition to the Minetest engine's built-in API,
The Minetest Game game offers multiple new possibilities in addition to the Minetest engine's built-in API,
allowing you to add new plants to farming mod, buckets for new liquids, new stairs and custom panes.
For information on the Minetest API, visit https://github.com/minetest/minetest/blob/master/doc/lua_api.txt
Please note:
* [XYZ] refers to a section the Minetest API
* [#ABC] refers to a section in this document
* [pos] refers to a position table `{x = -5, y = 0, z = 200}`
Bucket API
----------
The bucket API allows registering new types of buckets for non-default liquids.
bucket.register_liquid(
"default:lava_source", -- name of the source node
"default:lava_flowing", -- name of the flowing node
"bucket:bucket_lava", -- name of the new bucket item (or nil if liquid is not takeable)
"bucket_lava.png", -- texture of the new bucket item (ignored if itemname == nil)
"Lava Bucket", -- text description of the bucket item
{lava_bucket = 1} -- groups of the bucket item, OPTIONAL
{lava_bucket = 1}, -- groups of the bucket item, OPTIONAL
false -- force-renew, OPTIONAL. Force the liquid source to renew if it has
-- a source neighbour, even if defined as 'liquid_renewable = false'.
-- Needed to avoid creating holes in sloping rivers.
)
The filled bucket item is returned to the player that uses an empty bucket pointing to the given liquid source.
When punching with an empty bucket pointing to an entity or a non-liquid node, the on_punch of the entity or node will be triggered.
Beds API
--------
......@@ -36,6 +45,7 @@ Beds API
def -- See [#Bed definition]
)
* `beds.can_dig(bed_pos)` Returns a boolean whether the bed at `bed_pos` may be dug
* `beds.read_spawns() ` Returns a table containing players respawn positions
* `beds.kick_players()` Forces all players to leave bed
* `beds.skip_night()` Sets world time to morning and saves respawn position of all players currently sleeping
......@@ -61,11 +71,106 @@ Beds API
}
}
Bones API
---------
An ordered list of listnames (default: "main", "craft") of the player inventory,
that will be placed into bones or dropped on player death can be looked up or changed
in `bones.player_inventory_lists`.
e.g. `table.insert(bones.player_inventory_lists, "backpack")`
Creative API
------------
Use `creative.register_tab(name, title, items)` to add a tab with filtered items.
For example,
creative.register_tab("tools", "Tools", minetest.registered_tools)
is used to show all tools. Name is used in the sfinv page name, title is the
human readable title.
Creative provides `creative.is_enabled_for(name)`, which is identical in
functionality to the engine's `minetest.creative_is_enabled(name)`.
Its use is deprecated and it should also not be overriden.
The contents of `creative.formspec_add` is appended to every creative inventory
page. Mods can use it to add additional formspec elements onto the default
creative inventory formspec to be drawn after each update.
Group overrides can be used for any registered item, node or tool. Use one of
the groups stated below to pick which category it will appear in.
node = 1 -- Appears in the Nodes category
tool = 1 -- Appears in the Tools category
craftitem = 1 -- Appears in the Items category
Chests API
----------
The chests API allows the creation of chests, which have their own inventories for holding items.
`default.chest.get_chest_formspec(pos)`
* Returns a formspec for a specific chest.
* `pos` Location of the chest node, e.g `{x = 1, y = 1, z = 1}`
`default.chest.chest_lid_obstructed(pos)`
* Returns a boolean depending on whether or not a chest has its top obstructed by a solid node.
* `pos` Location of the chest node, e.g `{x = 1, y = 1, z = 1}`
`default.chest.chest_lid_close(pn)`
* Closes the chest that a player is currently looking in.
* `pn` The name of the player whose chest is going to be closed
`default.chest.open_chests`
* A table indexed by player name to keep track of who opened what chest.
* Key: The name of the player.
* Value: A table containing information about the chest the player is looking at.
e.g `{ pos = {1, 1, 1}, sound = null, swap = "default:chest" }`
`default.chest.register_chest(name, def)`
* Registers new chest
* `name` Name for chest e.g. "default:chest"
* `def` See [#Chest Definition]
### Chest Definition
description = "Chest",
tiles = {
"default_chest_top.png",
"default_chest_top.png",
"default_chest_side.png",
"default_chest_side.png",
"default_chest_front.png",
"default_chest_inside.png"
}, -- Textures which are applied to the chest model.
sounds = default.node_sound_wood_defaults(),
sound_open = "default_chest_open",
sound_close = "default_chest_close",
groups = {choppy = 2, oddly_breakable_by_hand = 2},
protected = false, -- If true, only placer can modify chest.
Doors API
---------
The doors mod allows modders to register custom doors and trapdoors.
`doors.registered_doors[name] = Door definition`
* Table of registered doors, indexed by door name
`doors.registered_trapdoors[name] = Trapdoor definition`
* Table of registered trap doors, indexed by trap door name
`doors.register_door(name, def)`
* Registers new door
......@@ -101,37 +206,104 @@ The doors mod allows modders to register custom doors and trapdoors.
has the permissions needed to open this door. If omitted then no
permission checks are performed.
`doors.door_toggle(pos, node, clicker)`
* Toggle door open or shut
* `pos` Position of the door
* `node` Node definition
* `clicker` Player definition for the player that clicked on the door
### Door definition
description = "Door description",
inventory_image = "mod_door_inv.png",
groups = {choppy = 2},
model = "mod_door", -- (optional)
-- Model name without a suffix ("big_door" not "big_door_a.obj", "big_door_b.obj")
tiles = {"mod_door.png"}, -- UV map.
-- The front and back of the door must be identical in appearence as they swap on
-- open/close.
recipe = craftrecipe,
sounds = default.node_sound_wood_defaults(), -- optional
sound_open = sound play for open door, -- optional
sound_close = sound play for close door, -- optional
gain_open = 0.3, -- optional, defaults to 0.3
gain_close = 0.3, -- optional, defaults to 0.3
protected = false, -- If true, only placer can open the door (locked for others)
on_rightclick = function(pos, node, clicker, itemstack, pointed_thing),
-- optional function containing the on_rightclick callback, defaults to a doors.door_toggle-wrapper
use_texture_alpha = "clip",
### Trapdoor definition
description = "Trapdoor description",
inventory_image = "mod_trapdoor_inv.png",
nodebox_closed = {} -- Nodebox for closed model
nodebox_opened = {} -- Nodebox for opened model
-- (optional) both nodeboxes must be used, not one only
groups = {choppy = 2},
tile_front = "doors_trapdoor.png", -- the texture for the front and back of the trapdoor
tile_side = "doors_trapdoor_side.png", -- the tiles of the four side parts of the trapdoor
tile_side = "doors_trapdoor_side.png",
-- The texture for the four sides of the trapdoor.
-- The texture should have the trapdoor side drawn twice, in the lowest and highest
-- 1/8ths of the texture, both upright. The area between is not used.
-- The lower 1/8th will be used for the closed trapdoor, the higher 1/8th will be used
-- for the open trapdoor.
sounds = default.node_sound_wood_defaults(), -- optional
sound_open = sound play for open door, -- optional
sound_close = sound play for close door, -- optional
gain_open = 0.3, -- optional, defaults to 0.3
gain_close = 0.3, -- optional, defaults to 0.3
protected = false, -- If true, only placer can open the door (locked for others)
on_rightclick = function(pos, node, clicker, itemstack, pointed_thing) ,
-- function containing the on_rightclick callback
use_texture_alpha = "clip",
### Fence gate definition
description = "Wooden Fence Gate",
texture = "default_wood.png",
texture = "default_wood.png", -- `backface_culling` will automatically be
-- set to `true` if not specified.
material = "default:wood",
groups = {choppy = 2, oddly_breakable_by_hand = 2, flammable = 2},
sounds = default.node_sound_wood_defaults(), -- optional
on_rightclick = function(pos, node, clicker, itemstack, pointed_thing)
-- function containing the on_rightclick callback
Dungeon Loot API
----------------
The mod that places chests with loot in dungeons provides an API to register additional loot.
`dungeon_loot.register(def)`
* Registers one or more loot items
* `def` Can be a single [#Loot definition] or a list of them
`dungeon_loot.registered_loot`
* Table of all registered loot, not to be modified manually
### Loot definition
name = "item:name",
chance = 0.5,
-- ^ chance value from 0.0 to 1.0 that the item will appear in the chest when chosen
-- Due to an extra step in the selection process, 0.5 does not(!) mean that
-- on average every second chest will have this item
count = {1, 4},
-- ^ table with minimum and maximum amounts of this item
-- optional, defaults to always single item
y = {-32768, -512},
-- ^ table with minimum and maximum heights this item can be found at
-- optional, defaults to no height restrictions
types = {"desert"},
-- ^ table with types of dungeons this item can be found in
-- supported types: "normal" (the cobble/mossycobble one), "sandstone"
-- "desert" and "ice"
-- optional, defaults to no type restrictions
Fence API
---------
......@@ -154,6 +326,7 @@ Allows creation of new fences with "fencelike" drawtype.
groups = {choppy = 2, oddly_breakable_by_hand = 2, flammable = 2},
sounds = default.node_sound_wood_defaults(),
Walls API
---------
......@@ -166,6 +339,7 @@ walls.register(name, desc, texture, mat, sounds)
^ mat = "default:stone". Used to auto-generate crafting recipe.
^ sounds = sounds: see [#Default sounds]
Farming API
-----------
......@@ -177,6 +351,9 @@ The farming API allows you to easily register plants and hoes.
`farming.register_plant(name, Plant definition)`
* Register a new growing plant, see [#Plant definition]
`farming.registered_plants[name] = definition`
* Table of registered plants, indexed by plant name
### Hoe Definition
......@@ -196,6 +373,8 @@ The farming API allows you to easily register plants and hoes.
{
description = "", -- Description of seed item
harvest_description = "", -- Description of harvest item
-- (optional, derived automatically if not provided)
inventory_image = "unknown_item.png", -- Image to be used as seed's wield- and inventory image
steps = 8, -- How many steps the plant has to grow, until it can be harvested
-- ^ Always provide a plant texture for each step, format: modname_plantname_i.png (i = stepnumber)
......@@ -203,9 +382,12 @@ The farming API allows you to easily register plants and hoes.
maxlight = default.LIGHT_MAX -- Maximum light to grow
}
Fire API
--------
Add group flammable when registering a node to make fire seek for it.
Add it to an item to make it burn up when dropped in lava or fire.
New node def property:
`on_burn(pos)`
......@@ -213,6 +395,14 @@ New node def property:
* Called when fire attempts to remove a burning node.
* `pos` Position of the burning node.
`on_ignite(pos, igniter)`
* Called when Flint and steel (or a mod defined ignitor) is used on a node.
Defining it may prevent the default action (spawning flames) from triggering.
* `pos` Position of the ignited node.
* `igniter` Player that used the tool, when available.
Give Initial Stuff API
----------------------
......@@ -245,9 +435,89 @@ Give Initial Stuff API
^ Adds items to the list of items to be given
TNT API
Player API
----------
The player API can register player models and update the player's appearance.
* `player_api.globalstep(dtime, ...)`
* The function called by the globalstep that controls player animations.
You can override this to replace the globalstep with your own implementation.
* Receives all args that minetest.register_globalstep() passes
* `player_api.register_model(name, def)`
* Register a new model to be used by players
* `name`: model filename such as "character.x", "foo.b3d", etc.
* `def`: see [#Model definition]
* Saved to player_api.registered_models
* `player_api.registered_models[name]`
* Get a model's definition
* `name`: model filename
* See [#Model definition]
* `player_api.set_model(player, model_name)`
* Change a player's model
* `player`: PlayerRef
* `model_name`: model registered with `player_api.register_model`
* `player_api.set_animation(player, anim_name, speed)`
* Applies an animation to a player if speed or anim_name differ from the currently playing animation
* `player`: PlayerRef
* `anim_name`: name of the animation
* `speed`: keyframes per second. If nil, the default from the model def is used
* `player_api.set_textures(player, textures)`
* Sets player textures
* `player`: PlayerRef
* `textures`: array of textures. If nil, the default from the model def is used
* `player_api.set_textures(player, index, texture)`
* Sets one of the player textures
* `player`: PlayerRef
* `index`: Index into array of all textures
* `texture`: the texture string
* `player_api.get_animation(player)`
* Returns a table containing fields `model`, `textures` and `animation`
* Any of the fields of the returned table may be nil
* `player`: PlayerRef
* `player_api.player_attached`
* A table that maps a player name to a boolean
* If the value for a given player is set to true, the default player animations
(walking, digging, ...) will no longer be updated, and knockback from damage is
prevented for that player
* Example of usage: A mod sets a player's value to true when attached to a vehicle
### Model Definition
{
animation_speed = 30, -- Default animation speed, in keyframes per second
textures = {"character.png"}, -- Default array of textures
animations = {
-- [anim_name] = {
-- x = <start_frame>,
-- y = <end_frame>,
-- collisionbox = <model collisionbox>, -- (optional)
-- eye_height = <model eye height>, -- (optional)
-- -- suspend client side animations while this one is active (optional)
-- override_local = <true/false>
-- },
stand = ..., lay = ..., walk = ..., mine = ..., walk_mine = ..., -- required animations
sit = ... -- used by boats and other MTG mods
},
-- Default object properties, see lua_api.txt
visual_size = {x = 1, y = 1},
collisionbox = {-0.3, 0.0, -0.3, 0.3, 1.7, 0.3},
stepheight = 0.6,
eye_height = 1.47
}
TNT API
-------
`tnt.register_tnt(definition)`
^ Register a new type of tnt.
......@@ -256,6 +526,7 @@ TNT API
* `description` A description for your TNT.
* `radius` The radius within which the TNT can destroy nodes. The default is 3.
* `damage_radius` The radius within which the TNT can damage players and mobs. By default it is twice the `radius`.
* `sound` The sound played when explosion occurs. By default it is `tnt_explode`.
* `disable_drops` Disable drops. By default it is set to false.
* `ignore_protection` Don't check `minetest.is_protected` before removing a node.
* `ignore_on_blast` Don't call `on_blast` even if a node has one.
......@@ -265,17 +536,20 @@ TNT API
* `bottom` Bottom tile. By default the name of the tnt with a suffix of `_bottom.png`.
* `burning` Top tile when lit. By default the name of the tnt with a suffix of `_top_burning_animated.png".
`tnt.boom(position, definition)`
`tnt.boom(position[, definition])`
^ Create an explosion.
* `position` The center of explosion.
* `definition` The TNT definion as passed to `tnt.register`
* `definition` The TNT definion as passed to `tnt.register` with the following addition:
* `explode_center` false by default which removes TNT node on blast, when true will explode center node.
`tnt.burn(position)`
^ Ignite TNT at position
`tnt.burn(position, [nodename])`
^ Ignite node at position, triggering its `on_ignite` callback (see fire mod).
If no such callback exists, fallback to turn tnt group nodes to their
"_burning" variant.
nodename isn't required unless already known.
To make dropping items from node inventories easier, you can use the
following helper function from 'default':
......@@ -330,41 +604,213 @@ To use it, add the `on_screwdriver` function to the node definition.
* `new_param2` the new value of param2 that would have been set if on_rotate wasn't there
* return value: false to disallow rotation, nil to keep default behaviour, true to allow
it but to indicate that changed have already been made (so the screwdriver will wear out)
* use `on_rotate = screwdriver.disallow` to always disallow rotation
* use `on_rotate = false` to always disallow rotation
* use `on_rotate = screwdriver.rotate_simple` to allow only face rotation
Sethome API
-----------
The sethome API adds three global functions to allow mods to read a players home position,
set a players home position and teleport a player to home position.
`sethome.get(name)`
* `name` Player who's home position you wish to get
* return value: false if no player home coords exist, position table if true
`sethome.set(name, pos)`
* `name` Player who's home position you wish to set
* `pos` Position table containing coords of home position
* return value: false if unable to set and save new home position, otherwise true
`sethome.go(name)`
* `name` Player you wish to teleport to their home position
* return value: false if player cannot be sent home, otherwise true
Sfinv API
---------
It is recommended that you read this link for a good introduction to the
sfinv API by its author: https://rubenwardy.com/minetest_modding_book/en/chapters/sfinv.html
### sfinv Methods
**Pages**
* sfinv.set_page(player, pagename) - changes the page
* sfinv.get_page(player) - get the current page name. Will never return nil
* sfinv.get_homepage_name(player) - get the page name of the first page to show to a player
* sfinv.register_page(name, def) - register a page, see section below
* sfinv.override_page(name, def) - overrides fields of an page registered with register_page.
* Note: Page must already be defined, (opt)depend on the mod defining it.
* sfinv.set_player_inventory_formspec(player) - (re)builds page formspec
and calls set_inventory_formspec().
* sfinv.get_formspec(player, context) - builds current page's formspec
**Contexts**
* sfinv.get_or_create_context(player) - gets the player's context
* sfinv.set_context(player, context)
**Theming**
* sfinv.make_formspec(player, context, content, show_inv, size) - adds a theme to a formspec
* show_inv, defaults to false. Whether to show the player's main inventory
* size, defaults to `size[8,8.6]` if not specified
* sfinv.get_nav_fs(player, context, nav, current_idx) - creates tabheader or ""
### sfinv Members
* pages - table of pages[pagename] = def
* pages_unordered - array table of pages in order of addition (used to build navigation tabs).
* contexts - contexts[playername] = player_context
* enabled - set to false to disable. Good for inventory rehaul mods like unified inventory
### Context
A table with these keys:
* page - current page name
* nav - a list of page names
* nav_titles - a list of page titles
* nav_idx - current nav index (in nav and nav_titles)
* any thing you want to store
* sfinv will clear the stored data on log out / log in
### sfinv.register_page
sfinv.register_page(name, def)
def is a table containing:
* `title` - human readable page name (required)
* `get(self, player, context)` - returns a formspec string. See formspec variables. (required)
* `is_in_nav(self, player, context)` - return true to show in the navigation (the tab header, by default)
* `on_player_receive_fields(self, player, context, fields)` - on formspec submit.
* `on_enter(self, player, context)` - called when the player changes pages, usually using the tabs.
* `on_leave(self, player, context)` - when leaving this page to go to another, called before other's on_enter
### get formspec
Use sfinv.make_formspec to apply a layout:
return sfinv.make_formspec(player, context, [[
list[current_player;craft;1.75,0.5;3,3;]
list[current_player;craftpreview;5.75,1.5;1,1;]
image[4.75,1.5;1,1;gui_furnace_arrow_bg.png^[transformR270]
listring[current_player;main]
listring[current_player;craft]
image[0,4.25;1,1;gui_hb_bg.png]
image[1,4.25;1,1;gui_hb_bg.png]
image[2,4.25;1,1;gui_hb_bg.png]
image[3,4.25;1,1;gui_hb_bg.png]
image[4,4.25;1,1;gui_hb_bg.png]
image[5,4.25;1,1;gui_hb_bg.png]
image[6,4.25;1,1;gui_hb_bg.png]
image[7,4.25;1,1;gui_hb_bg.png]
]], true)
See above (methods section) for more options.
### Customising themes
Simply override this function to change the navigation:
function sfinv.get_nav_fs(player, context, nav, current_idx)
return "navformspec"
end
And override this function to change the layout:
function sfinv.make_formspec(player, context, content, show_inv, size)
local tmp = {
size or "size[8,8.6]",
theme_main,
sfinv.get_nav_fs(player, context, context.nav_titles, context.nav_idx),
content
}
if show_inv then
tmp[4] = theme_inv
end
return table.concat(tmp, "")
end
Stairs API
----------
The stairs API lets you register stairs and slabs and ensures that they are registered the same way as those
delivered with Minetest Game, to keep them compatible with other mods.
`stairs.register_stair(subname, recipeitem, groups, images, description, sounds)`
The following node attributes are sourced from the recipeitem:
* use_texture_alpha
* sunlight_propagates
* light_source
* If the recipeitem is a fuel, the stair/slab is also registered as a fuel of proportionate burntime.
`stairs.register_stair(subname, recipeitem, groups, images, description, sounds, worldaligntex)`
* Registers a stair.
* Registers a stair
* `subname`: Basically the material name (e.g. cobble) used for the stair name. Nodename pattern: "stairs:stair_subname"
* `recipeitem`: Item used in the craft recipe, e.g. "default:cobble", may be `nil`
* `groups`: see [Known damage and digging time defining groups]
* `images`: see [Tile definition]
* `description`: used for the description field in the stair's definition
* `sounds`: see [#Default sounds]
* `groups`: See [Known damage and digging time defining groups]
* `images`: See [Tile definition]
* `description`: Used for the description field in the stair's definition
* `sounds`: See [#Default sounds]
* `worldaligntex`: A bool to set all textures world-aligned. Default false. See [Tile definition]
`stairs.register_slab(subname, recipeitem, groups, images, description, sounds)`
`stairs.register_slab(subname, recipeitem, groups, images, description, sounds, worldaligntex)`
* Registers a slabs
* `subname`: Basically the material name (e.g. cobble) used for the stair name. Nodename pattern: "stairs:stair_subname"
* Registers a slab
* `subname`: Basically the material name (e.g. cobble) used for the slab name. Nodename pattern: "stairs:slab_subname"
* `recipeitem`: Item used in the craft recipe, e.g. "default:cobble"
* `groups`: see [Known damage and digging time defining groups]
* `images`: see [Tile definition]
* `description`: used for the description field in the stair's definition
* `sounds`: see [#Default sounds]
* `groups`: See [Known damage and digging time defining groups]
* `images`: See [Tile definition]
* `description`: Used for the description field in the slab's definition
* `sounds`: See [#Default sounds]
* `worldaligntex`: A bool to set all textures world-aligned. Default false. See [Tile definition]
`stairs.register_stair_inner(subname, recipeitem, groups, images, description, sounds, worldaligntex, full_description)`
* Registers an inner corner stair
* `subname`: Basically the material name (e.g. cobble) used for the stair name. Nodename pattern: "stairs:stair_inner_subname"
* `recipeitem`: Item used in the craft recipe, e.g. "default:cobble", may be `nil`
* `groups`: See [Known damage and digging time defining groups]
* `images`: See [Tile definition]
* `description`: Used for the description field in the stair's definition with "Inner" prepended
* `sounds`: See [#Default sounds]
* `worldaligntex`: A bool to set all textures world-aligned. Default false. See [Tile definition]
* `full_description`: Overrides the description, bypassing string concatenation. This is useful for translation. (optional)
`stairs.register_stair_and_slab(subname, recipeitem, groups, images, desc_stair, desc_slab, sounds)`
`stairs.register_stair_outer(subname, recipeitem, groups, images, description, sounds, worldaligntex, full_description)`
* A wrapper for stairs.register_stair and stairs.register_slab
* Registers an outer corner stair
* `subname`: Basically the material name (e.g. cobble) used for the stair name. Nodename pattern: "stairs:stair_outer_subname"
* `recipeitem`: Item used in the craft recipe, e.g. "default:cobble", may be `nil`
* `groups`: See [Known damage and digging time defining groups]
* `images`: See [Tile definition]
* `description`: Used for the description field in the stair's definition with "Outer" prepended
* `sounds`: See [#Default sounds]
* `worldaligntex`: A bool to set all textures world-aligned. Default false. See [Tile definition]
* `full_description`: Overrides the description, bypassing string concatenation. This is useful for translation. (optional)
```
stairs.register_stair_and_slab(subname, recipeitem, groups, images, desc_stair, desc_slab,
sounds, worldaligntex, desc_stair_inner, desc_stair_outer)
```
* A wrapper for stairs.register_stair, stairs.register_slab, stairs.register_stair_inner, stairs.register_stair_outer
* Uses almost the same arguments as stairs.register_stair
* `desc_stair`: Description for stair node
* `desc_stair`: Description for stair nodes. For corner stairs 'Inner' or 'Outer' will be prefixed unless
`desc_stair_inner` or `desc_stair_outer` are specified, which are used instead.
* `desc_slab`: Description for slab node
* `desc_stair_inner`: Description for inner stair node
* `desc_stair_outer`: Description for outer stair node
Xpanes API
----------
......@@ -379,12 +825,18 @@ Creates panes that automatically connect to each other
### Pane definition
{
textures = {"texture_Bottom_top", "texture_left_right", "texture_front_back"}, -- More tiles aren't supported
textures = {
"texture for front and back",
(unused),
"texture for the 4 edges"
}, -- More tiles aren't supported
groups = {group = rating}, -- Uses the known node groups, see [Known damage and digging time defining groups]
sounds = SoundSpec, -- See [#Default sounds]
recipe = {{"","","","","","","","",""}}, -- Recipe field only
use_texture_alpha = true, -- Optional boolean (default: `false`) for colored glass panes
}
Raillike definitions
--------------------
......@@ -416,151 +868,121 @@ Sounds inside the default table can be used within the sounds field of node defi
* `default.node_sound_wood_defaults()`
* `default.node_sound_leaves_defaults()`
* `default.node_sound_glass_defaults()`
* `default.node_sound_metal_defaults()`
Default constants
-----------------
`default.LIGHT_MAX` The maximum light level (see [Node definition] light_source)
Player API
----------
The player API can register player models and update the player's appearence
GUI and formspecs
-----------------
`default.player_register_model(name, def)`
`default.get_hotbar_bg(x, y)`
* Register a new model to be used by players.
* name: model filename such as "character.x", "foo.b3d", etc.
* def: See [#Model definition]
* Get the hotbar background as string, containing the formspec elements
* x: Horizontal position in the formspec
* y: Vertical position in the formspec
`default.registered_player_models[name]`
`default.gui_bg`
* Get a model's definition
* see [#Model definition]
* Deprecated, remove from mods.
`default.player_set_model(player, model_name)`
`default.gui_bg_img`
* Change a player's model
* `player`: PlayerRef
* `model_name`: model registered with player_register_model()
* Deprecated, remove from mods.
`default.player_set_animation(player, anim_name [, speed])`
`default.gui_slots`
* Applies an animation to a player
* anim_name: name of the animation.
* speed: frames per second. If nil, default from the model is used
* Deprecated, remove from mods.
`default.player_set_textures(player, textures)`
`default.gui_survival_form`
* Sets player textures
* `player`: PlayerRef
* `textures`: array of textures, If `textures` is nil, the default textures from the model def are used
* Entire formspec for the survival inventory
default.player_get_animation(player)
`default.get_furnace_active_formspec(fuel_percent, item_percent)`
* Returns a table containing fields `model`, `textures` and `animation`.
* Any of the fields of the returned table may be nil.
* player: PlayerRef
* Get the active furnace formspec using the defined GUI elements
* fuel_percent: Percent of how much the fuel is used
* item_percent: Percent of how much the item is cooked
### Model Definition
`default.get_furnace_inactive_formspec()`
* Get the inactive furnace formspec using the defined GUI elements
{
animation_speed = 30, -- Default animation speed, in FPS.
textures = {"character.png", }, -- Default array of textures.
visual_size = {x = 1, y = 1}, -- Used to scale the model.
animations = {
-- <anim_name> = {x = <start_frame>, y = <end_frame>},
foo = {x = 0, y = 19},
bar = {x = 20, y = 39},
-- ...
},
}
Leafdecay
---------
To enable leaf decay for a node, add it to the `leafdecay` group.
To enable leaf decay for leaves when a tree is cut down by a player,
register the tree with the default.register_leafdecay(leafdecaydef)
function.
The rating of the group determines how far from a node in the group `tree`
the node can be without decaying.
If `param2` of any registered node is ~= 0, the node will always be
preserved. Thus, if the player places a node of that kind, you will
want to set `param2 = 1` or so.
If `param2` of the node is ~= 0, the node will always be preserved. Thus, if
the player places a node of that kind, you will want to set `param2 = 1` or so.
The function `default.after_place_leaves` can be set as
`after_place_node of a node` to set param2 to 1 if the player places
the node (should not be used for nodes that use param2 otherwise
(e.g. facedir)).
The function `default.after_place_leaves` can be set as `after_place_node of a node`
to set param2 to 1 if the player places the node (should not be used for nodes
that use param2 otherwise (e.g. facedir)).
If the node is in the `leafdecay_drop` group then it will always be
dropped as an item.
`default.register_leafdecay(leafdecaydef)`
`leafdecaydef` is a table, with following members:
{
trunks = {"default:tree"}, -- nodes considered trunks
leaves = {"default:leaves", "default:apple"},
-- nodes considered for removal
radius = 3, -- radius to consider for searching
}
Note: all the listed nodes in `trunks` have their `on_after_destruct`
callback overridden. All the nodes listed in `leaves` have their
`on_timer` callback overridden.
If the node is in the `leafdecay_drop` group then it will always be dropped as an
item.
Dyes
----
To make recipes that will work with any dye ever made by anybody, define
them based on groups. You can select any group of groups, based on your need for
amount of colors.
### Color groups
Base color groups:
* `basecolor_white`
* `basecolor_grey`
* `basecolor_black`
* `basecolor_red`
* `basecolor_yellow`
* `basecolor_green`
* `basecolor_cyan`
* `basecolor_blue`
* `basecolor_magenta`
Extended color groups ( * means also base color )
* `excolor_white` *
* `excolor_lightgrey`
* `excolor_grey` *
* `excolor_darkgrey`
* `excolor_black` *
* `excolor_red` *
* `excolor_orange`
* `excolor_yellow` *
* `excolor_lime`
* `excolor_green` *
* `excolor_aqua`
* `excolor_cyan` *
* `excolor_sky_blue`
* `excolor_blue` *
* `excolor_violet`
* `excolor_magenta` *
* `excolor_red_violet`
The whole unifieddyes palette as groups:
* `unicolor_<excolor>`
For the following, no white/grey/black is allowed:
* `unicolor_medium_<excolor>`
* `unicolor_dark_<excolor>`
* `unicolor_light_<excolor>`
* `unicolor_<excolor>_s50`
* `unicolor_medium_<excolor>_s50`
* `unicolor_dark_<excolor>_s50`
Example of one shapeless recipe using a color group:
Minetest Game dyes are registered with:
groups = {dye = 1, color_<color> = 1},
To make recipes that will work with dyes from many mods, define them using the
dye group and the color groups.
Dye color groups:
* `color_white`
* `color_grey`
* `color_dark_grey`
* `color_black`
* `color_red`
* `color_pink`
* `color_orange`
* `color_brown`
* `color_yellow`
* `color_green`
* `color_dark_green`
* `color_blue`
* `color_cyan`
* `color_violet`
* `color_magenta`
Example of one shapeless recipe using the dye group and a color group:
minetest.register_craft({
type = "shapeless",
output = '<mod>:item_yellow',
recipe = {'<mod>:item_no_color', 'group:basecolor_yellow'},
output = "<mod>:item_yellow",
recipe = {"<mod>:item_no_color", "group:dye,color_yellow"},
})
### Color lists
* `dye.basecolors` are an array containing the names of available base colors
* `dye.excolors` are an array containing the names of the available extended colors
Trees
-----
......@@ -583,11 +1005,143 @@ Trees
* `default.grow_new_pine_tree(pos)`
* Grows a new design pine tree at pos
* `default.grow_new_snowy_pine_tree(pos)`
* Grows a new design snowy pine tree at pos
* `default.grow_new_acacia_tree(pos)`
* Grows a new design acacia tree at pos
* `default.grow_new_aspen_tree(pos)`
* Grows a new design aspen tree at pos
* `default.grow_new_snowy_pine_tree(pos)`
* Grows a new design snowy pine tree at pos
* `default.grow_bush(pos)`
* Grows a bush at pos
* `default.grow_acacia_bush(pos)`
* Grows an acaia bush at pos
* `default.grow_pine_bush(pos)`
* Grows a pine bush at pos
* `default.grow_blueberry_bush(pos)`
* Grows a blueberry bush at pos
Carts
-----
carts.register_rail(
"mycarts:myrail", -- Rail name
nodedef, -- standard nodedef
railparams -- rail parameter struct (optional)
)
railparams = {
on_step(obj, dtime), -- Event handler called when
-- cart is on rail
acceleration, -- integer acceleration factor (negative
-- values to brake)
}
The event handler is called after all default calculations
are made, so the custom on_step handler can override things
like speed, acceleration, player attachment. The handler will
likely be called many times per second, so the function needs
to make sure that the event is handled properly.
Key API
-------
The key API allows mods to add key functionality to nodes that have
ownership or specific permissions. Using the API will make it so
that a node owner can use skeleton keys on their nodes to create keys
for that node in that location, and give that key to other players,
allowing them some sort of access that they otherwise would not have
due to node protection.
To make your new nodes work with the key API, you need to register
two callback functions in each nodedef:
`on_key_use(pos, player)`
* Is called when a player right-clicks (uses) a normal key on your
* node.
* `pos` - position of the node
* `player` - PlayerRef
* return value: none, ignored
The `on_key_use` callback should validate that the player is wielding
a key item with the right key meta secret. If needed the code should
deny access to the node functionality.
If formspecs are used, the formspec callbacks should duplicate these
checks in the metadata callback functions.
`on_skeleton_key_use(pos, player, newsecret)`
* Is called when a player right-clicks (uses) a skeleton key on your
* node.
* `pos` - position of the node
* `player` - PlayerRef
* `newsecret` - a secret value(string)
* return values:
* `secret` - `nil` or the secret value that unlocks the door
* `name` - a string description of the node ("a locked chest")
* `owner` - name of the node owner
The `on_skeleton_key_use` function should validate that the player has
the right permissions to make a new key for the item. The newsecret
value is useful if the node has no secret value. The function should
store this secret value somewhere so that in the future it may compare
key secrets and match them to allow access. If a node already has a
secret value, the function should return that secret value instead
of the newsecret value. The secret value stored for the node should
not be overwritten, as this would invalidate existing keys.
Aside from the secret value, the function should retun a descriptive
name for the node and the owner name. The return values are all
encoded in the key that will be given to the player in replacement
for the wielded skeleton key.
if `nil` is returned, it is assumed that the wielder did not have
permissions to create a key for this node, and no key is created.
`default.register_craft_metadata_copy(ingredient, result)`
----------------------------------------------------------
This function registers a shapeless recipe that takes `ingredient`
and `result` as input and outputs `result`.
The metadata of the input `result` is copied to the output `result`.
Log API
-------
Logs action of the player with a node at a certain position.
By default only actions of real players are logged.
Actions of non-players (usually machines) are logged only when
setting `log_non_player_actions` is enabled.
A player is considered non-player if `player:is_player()` returns
`false` or `player.is_fake_player` is truthy. The use of
`is_fake_player` is an unofficial standard between mods.
These non-players are marked by the content of `is_fake_player`
(if it is a string) or a "*" in brackets after the player name in
the log.
`default.log_player_action(player, ...)`
* `player` The player who performed the action
* `message_parts` Any mumber of message parts describing the action
in 3rd person singular present tense. It can also
contain a `pos` which is logged as "(X,Y,Z)"
`default.set_inventory_action_loggers(def, name)`
* sets the callbacks `on_metadata_inventory_move`,
`on_metadata_inventory_put` and `on_metadata_inventory_take`
that log corresponding actions
* `def` See [Node definition]
* `name` Description of the node in the log message
menu/header.png

1.88 KiB | W: 0px | H: 0px

menu/header.png

3.01 KiB | W: 0px | H: 0px

menu/header.png
menu/header.png
menu/header.png
menu/header.png
  • 2-up
  • Swipe
  • Onion skin
menu/icon.png

2.94 KiB | W: 0px | H: 0px

menu/icon.png

11.8 KiB | W: 0px | H: 0px

menu/icon.png
menu/icon.png
menu/icon.png
menu/icon.png
  • 2-up
  • Swipe
  • Onion skin
# This file contains settings of Minetest Game that can be changed in minetest.conf
# This file contains settings of Minetest Game that can be changed in
# minetest.conf.
# By default, all the settings are commented and not functional.
# Uncomment settings by removing the preceding #.
# Whether creative mode (fast digging of all blocks, unlimited resources) should be enabled
# Whether creative mode (fast digging of all blocks, unlimited resources) should
# be enabled.
#creative_mode = false
# The time in seconds after which the bones of a dead player can be looted by everyone
# 0 to disable
# Sets the behaviour of the inventory items when a player dies.
# bones: Store items in a bone node but drop items if inside protected area.
# drop: Drop items on the ground.
# keep: Player keeps items.
#bones_mode = bones
# The time in seconds after which the bones of a dead player can be looted by
# everyone.
# 0 to disable.
#share_bones_time = 1200
# How much earlier the bones of a dead player can be looted by
......@@ -14,28 +23,58 @@
# 0 to disable. By default it is "share_bones_time" divide by four.
#share_bones_time_early = 300
# Whether standard fire should be disabled ('basic flame' nodes will disappear)
# 'permanent flame' nodes will remain with either setting
#disable_fire = false
# Inform player of condition and location of new bones.
#bones_position_message = false
# Whether fire should be enabled. If disabled, 'basic_flame' nodes will
# disappear.
# 'permanent_flame' nodes will remain with either setting.
#enable_fire = true
# Enable flame sound.
#flame_sound = true
# Whether the stuff in initial_stuff should be given to new players
# Whether lavacooling should be enabled.
#enable_lavacooling = true
# Whether the stuff in initial_stuff should be given to new players.
#give_initial_stuff = false
#initial_stuff = default:pick_steel,default:axe_steel,default:shovel_steel,default:torch 99,default:cobble 99
#initial_stuff = default:pick_steel,default:axe_steel,default:shovel_steel,
default:torch 99,default:cobble 99
# Whether the TNT mod should be enabled
# Whether the TNT mod should be enabled.
#enable_tnt = <true in singleplayer, false in multiplayer>
# The radius of a TNT explosion
# The radius of a TNT explosion.
#tnt_radius = 3
# Enable the stairs mod ABM that replaces the old 'upside down'
# stair and slab nodes in old maps with the new param2 versions.
#enable_stairs_replace_abm = false
# Whether you allow respawning in beds
# Default value is true
# Whether to allow respawning in beds.
# Default value is true.
#enable_bed_respawn = true
# Whether players can skip night by sleeping
# Default value is true
# Whether players can skip night by sleeping.
# Default value is true.
#enable_bed_night_skip = true
# If enabled, fences and walls cannot be jumped over.
#enable_fence_tall = false
# Whether the engine's spawn search, which does not check for a suitable
# starting biome, is used.
# Default value is false.
#engine_spawn = false
# Whether river water source nodes create flowing sounds.
# Helps rivers create more sound, especially on level sections.
#river_source_sounds = false
# Enable cloud and shadow intensity variation by the 'weather' mod.
# Non-functional in V6 or Singlenode mapgens.
#enable_weather = true
# If enabled, non-player actions are logged
#log_non_player_actions = false
Subproject commit 1e7ace698bf06f363955d4e77a1fe7f68ecb1128
Subproject commit ac414d3df3bf34cc060f0eede40dc7a1e392f300
Subproject commit 1fd6a10bf8cac86bd5eb0593aa6f2381d3b904f2
Subproject commit 5d0314158a4e1a436a28292df004fdc8466c0150
arrow_signs @ f180f724
Subproject commit f180f7246dec209c50004812a6d776d83aab6aad
Subproject commit d6654f5e74b3051d42cbdd791934340a7076d608
Subproject commit b073bcb760328654e9d73e61bf950a56d8adbbb5
Subproject commit 9d55f9916d20779ecbf93c7e95dae8adebd2079b
Subproject commit 304f55fe830149e9eb495d20ea12cbfcc05d44cb