commit 6bc42eaf895c902aac77bdd83132bbab1ba87d83 Author: Juraj Vajda Date: Sun Mar 14 14:08:58 2021 -0400 initial commit diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..e43b0f9 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.DS_Store diff --git a/LICENSE.txt b/LICENSE.txt new file mode 100644 index 0000000..48f0b8d --- /dev/null +++ b/LICENSE.txt @@ -0,0 +1,519 @@ +License of media (textures and sounds) +-------------------------------------- +Copyright (C) 2010-2012 celeron55, Perttu Ahola +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 +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. + + + Copyright (C) + + 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. + + , 1 April 1990 + Ty Coon, President of Vice + +That's all there is to it! diff --git a/README.md b/README.md new file mode 100644 index 0000000..a88d83c --- /dev/null +++ b/README.md @@ -0,0 +1,35 @@ +# 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: +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` diff --git a/game.conf b/game.conf new file mode 100644 index 0000000..5a38429 --- /dev/null +++ b/game.conf @@ -0,0 +1,3 @@ +name = Survival X +author = SaKeL +description = A basic exploration, mining, crafting and building sandbox game with no NPCs, monsters or animals. Minetest Game is usually used with mods added and many mods are available for this game. Reliably maintained by Minetest Engine core developers. diff --git a/game_api.txt b/game_api.txt new file mode 100644 index 0000000..bddf7e2 --- /dev/null +++ b/game_api.txt @@ -0,0 +1,1084 @@ +Minetest Game API +================= +GitHub Repo: https://github.com/minetest/minetest_game + + +Introduction +------------ + +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 + 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 +-------- + + beds.register_bed( + "beds:bed", -- Bed name + 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 + +### Bed definition + + { + description = "Simple Bed", + inventory_image = "beds_bed.png", + wield_image = "beds_bed.png", + tiles = { + bottom = {'Tile definition'}, -- the tiles of the bottom part of the bed. + top = {Tile definition} -- the tiles of the bottom part of the bed. + }, + nodebox = { + bottom = 'regular nodebox', -- bottom part of bed (see [Node boxes]) + top = 'regular nodebox', -- top part of bed (see [Node boxes]) + }, + selectionbox = 'regular nodebox', -- for both nodeboxes (see [Node boxes]) + recipe = { -- Craft recipe + {"group:wool", "group:wool", "group:wool"}, + {"group:wood", "group:wood", "group:wood"} + } + } + + +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 + * `name` Name for door + * `def` See [#Door definition] + +`doors.register_trapdoor(name, def)` + + * Registers new trapdoor + * `name` Name for trapdoor + * `def` See [#Trapdoor definition] + +`doors.register_fencegate(name, def)` + + * Registers new fence gate + * `name` Name for fence gate + * `def` See [#Fence gate definition] + +`doors.get(pos)` + + * `pos` A position as a table, e.g `{x = 1, y = 1, z = 1}` + * Returns an ObjectRef to a door, or nil if the position does not contain a door + + ### Methods + + :open(player) -- Open the door object, returns if door was opened + :close(player) -- Close the door object, returns if door was closed + :toggle(player) -- Toggle the door state, returns if state was toggled + :state() -- returns the door state, true = open, false = closed + + the "player" parameter can be omitted in all methods. If passed then + the usual permission checks will be performed to make sure the player + 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}, + 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 + 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 + +### Trapdoor definition + + description = "Trapdoor description", + inventory_image = "mod_trapdoor_inv.png", + 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 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 + 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 + on_rightclick = function(pos, node, clicker, itemstack, pointed_thing) + -- function containing the on_rightclick callback + +### Fence gate definition + + description = "Wooden Fence Gate", + 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 +--------- + +Allows creation of new fences with "fencelike" drawtype. + +`default.register_fence(name, item definition)` + + Registers a new fence. Custom fields texture and material are required, as + are name and description. The rest is optional. You can pass most normal + nodedef fields here except drawtype. The fence group will always be added + for this node. + +### fence definition + + name = "default:fence_wood", + description = "Wooden Fence", + texture = "default_wood.png", + material = "default:wood", + groups = {choppy = 2, oddly_breakable_by_hand = 2, flammable = 2}, + sounds = default.node_sound_wood_defaults(), + + +Walls API +--------- + +The walls API allows easy addition of stone auto-connecting wall nodes. + +walls.register(name, desc, texture, mat, sounds) +^ name = "walls:stone_wall". Node name. +^ desc = "A Stone wall" +^ texture = "default_stone.png" +^ mat = "default:stone". Used to auto-generate crafting recipe. +^ sounds = sounds: see [#Default sounds] + + +Farming API +----------- + +The farming API allows you to easily register plants and hoes. + +`farming.register_hoe(name, hoe definition)` + * Register a new hoe, see [#hoe definition] + +`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 + + + { + description = "", -- Description for tooltip + inventory_image = "unknown_item.png", -- Image to be used as wield- and inventory image + max_uses = 30, -- Uses until destroyed + material = "", -- Material for recipes + recipe = { -- Craft recipe, if material isn't used + {"air", "air", "air"}, + {"", "group:stick"}, + {"", "group:stick"}, + } + } + +### Plant definition + + { + 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) + minlight = 13, -- Minimum light to grow + 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)` + + * 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 +---------------------- + +`give_initial_stuff.give(player)` + +^ Give initial stuff to "player" + +`give_initial_stuff.add(stack)` + +^ Add item to the initial stuff +^ Stack can be an ItemStack or a item name eg: "default:dirt 99" +^ Can be called after the game has loaded + +`give_initial_stuff.clear()` + +^ Removes all items from the initial stuff +^ Can be called after the game has loaded + +`give_initial_stuff.get_list()` + +^ returns list of item stacks + +`give_initial_stuff.set_list(list)` + +^ List of initial items with numeric indices. + +`give_initial_stuff.add_from_csv(str)` + +^ str is a comma separated list of initial stuff +^ Adds items to the list of items to be given + + +Player API +---------- + +The player API can register player models and update the player's appearance. + +* `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 + * `player`: PlayerRef + * `anim_name`: name of the animation + * `speed`: frames 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.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 FPS + textures = {"character.png", }, -- Default array of textures + visual_size = {x = 1, y = 1}, -- Used to scale the model + animations = { + -- = {x = , y = }, + foo = {x = 0, y = 19}, + bar = {x = 20, y = 39}, + -- ... + }, + collisionbox = {-0.3, 0.0, -0.3, 0.3, 1.7, 0.3}, -- In nodes from feet position + stepheight = 0.6, -- In nodes + eye_height = 1.47, -- In nodes above feet position + } + + +TNT API +------- + +`tnt.register_tnt(definition)` + +^ Register a new type of tnt. + + * `name` The name of the node. If no prefix is given `tnt` is used. + * `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. + * `tiles` Textures for node + * `side` Side tiles. By default the name of the tnt with a suffix of `_side.png`. + * `top` Top tile. By default the name of the tnt with a suffix of `_top.png`. + * `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])` + +^ Create an explosion. + +* `position` The center of explosion. +* `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, [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': + +default.get_inventory_drops(pos, inventory, drops) + +^ Return drops from node inventory "inventory" in drops. + +* `pos` - the node position +* `inventory` - the name of the inventory (string) +* `drops` - an initialized list + +The function returns no values. The drops are returned in the `drops` +parameter, and drops is not reinitialized so you can call it several +times in a row to add more inventory items to it. + + +`on_blast` callbacks: + +Both nodedefs and entitydefs can provide an `on_blast()` callback + +`nodedef.on_blast(pos, intensity)` +^ Allow drop and node removal overriding +* `pos` - node position +* `intensity` - TNT explosion measure. larger or equal to 1.0 +^ Should return a list of drops (e.g. {"default:stone"}) +^ Should perform node removal itself. If callback exists in the nodedef +^ then the TNT code will not destroy this node. + +`entitydef.on_blast(luaobj, damage)` +^ Allow TNT effects on entities to be overridden +* `luaobj` - LuaEntityRef of the entity +* `damage` - suggested HP damage value +^ Should return a list of (bool do_damage, bool do_knockback, table drops) +* `do_damage` - if true then TNT mod wil damage the entity +* `do_knockback` - if true then TNT mod will knock the entity away +* `drops` - a list of drops, e.g. {"wool:red"} + + +Screwdriver API +--------------- + +The screwdriver API allows you to control a node's behaviour when a screwdriver is used on it. +To use it, add the `on_screwdriver` function to the node definition. + +`on_rotate(pos, node, user, mode, new_param2)` + + * `pos` Position of the node that the screwdriver is being used on + * `node` that node + * `user` The player who used the screwdriver + * `mode` screwdriver.ROTATE_FACE or screwdriver.ROTATE_AXIS + * `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 = 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, worldaligntex)` + + * 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] + * `worldaligntex`: A bool to set all textures world-aligned. Default false. See [Tile definition] + +`stairs.register_slab(subname, recipeitem, groups, images, description, sounds, worldaligntex)` + + * 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 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_outer(subname, recipeitem, groups, images, description, sounds, worldaligntex, full_description)` + + * 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 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 +---------- + +Creates panes that automatically connect to each other + +`xpanes.register_pane(subname, def)` + + * `subname`: used for nodename. Result: "xpanes:subname" and "xpanes:subname_{2..15}" + * `def`: See [#Pane definition] + +### Pane definition + + { + 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 +-------------------- + +The following nodes use the group `connect_to_raillike` and will only connect to +raillike nodes within this group and the same group value. +Use `minetest.raillike_group()` to get the group value. + +| Node type | Raillike group name +|-----------------------|--------------------- +| default:rail | "rail" +| tnt:gunpowder | "gunpowder" +| tnt:gunpowder_burning | "gunpowder" + +Example: +If you want to add a new rail type and want it to connect with default:rail, +add `connect_to_raillike=minetest.raillike_group("rail")` into the `groups` table +of your node. + + +Default sounds +-------------- + +Sounds inside the default table can be used within the sounds field of node definitions. + + * `default.node_sound_defaults()` + * `default.node_sound_stone_defaults()` + * `default.node_sound_dirt_defaults()` + * `default.node_sound_sand_defaults()` + * `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) + + +GUI and formspecs +----------------- + +`default.get_hotbar_bg(x, y)` + + * Get the hotbar background as string, containing the formspec elements + * x: Horizontal position in the formspec + * y: Vertical position in the formspec + +`default.gui_bg` + + * Deprecated, remove from mods. + +`default.gui_bg_img` + + * Deprecated, remove from mods. + +`default.gui_slots` + + * Deprecated, remove from mods. + +`default.gui_survival_form` + + * Entire formspec for the survival inventory + +`default.get_furnace_active_formspec(fuel_percent, item_percent)` + + * 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 + +`default.get_furnace_inactive_formspec()` + + * Get the inactive furnace formspec using the defined GUI elements + + +Leafdecay +--------- + +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. + +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. + +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. + + +Dyes +---- + +Minetest Game dyes are registered with: + + groups = {dye = 1, 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 = ":item_yellow", + recipe = {":item_no_color", "group:dye,color_yellow"}, + }) + + +Trees +----- + + * `default.grow_tree(pos, is_apple_tree)` + * Grows a mgv6 tree or apple tree at pos + + * `default.grow_jungle_tree(pos)` + * Grows a mgv6 jungletree at pos + + * `default.grow_pine_tree(pos)` + * Grows a mgv6 pinetree at pos + + * `default.grow_new_apple_tree(pos)` + * Grows a new design apple tree at pos + + * `default.grow_new_jungle_tree(pos)` + * Grows a new design jungle tree at pos + + * `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_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`. diff --git a/menu/header.png b/menu/header.png new file mode 100644 index 0000000..2ecda83 Binary files /dev/null and b/menu/header.png differ diff --git a/menu/icon.png b/menu/icon.png new file mode 100644 index 0000000..bf90c82 Binary files /dev/null and b/menu/icon.png differ diff --git a/minetest.conf b/minetest.conf new file mode 100644 index 0000000..e69de29 diff --git a/minetest.conf.example b/minetest.conf.example new file mode 100644 index 0000000..86eba66 --- /dev/null +++ b/minetest.conf.example @@ -0,0 +1,77 @@ +# 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. +#creative_mode = false + +# 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 +# everyone if the player dies in a protected area they don't own. +# 0 to disable. By default it is "share_bones_time" divide by four. +#share_bones_time_early = 300 + +# 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 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 + +# Whether the TNT mod should be enabled. +#enable_tnt = + +# 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 to allow respawning in beds. +# Default value is true. +#enable_bed_respawn = 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 variation by the 'weather' mod. +# Non-functional in V6 or Singlenode mapgens. +#enable_weather = true diff --git a/schematic_tables.txt b/schematic_tables.txt new file mode 100644 index 0000000..eff2d35 --- /dev/null +++ b/schematic_tables.txt @@ -0,0 +1,2228 @@ +Minetest Game schematic tables +============================== + +This document acts as the official record of all schematic tables used in +Minetest Game, and should be updated by any commit that adds a table type +schematic. + +The following tables are for pasting into mods that contain a function to +convert the Lua tables into .mts files. Such mods often have two functions to +process two formats of the 'data' table: + +The standard table format is described in the 'Schematic specifier' section of +the lua_api.txt file in the Minetest Engine. +The 'data' table appears as a sequence of vertical slices through the structure +the schematic describes. +Each XY-plane slice has the X-rows formatted in order of increasing Y, so the +slices of the structure visually appear upside-down in the table. +In this document this format is used where 'mts_save()' appears. + +The transformed table format was created to be easier to work with. +Each XY-plane slice has the X-rows formatted in order of decreasing Y, so the +slices of the structure visually appear upright in the table. +In this document this format is used where 'mts_save_up()' appears. + + +-- This node will not replace existing world nodes + +local _ = {name = "air", prob = 0} + + +-- Mapgen Apple tree + +local M = {name = "default:leaves", prob = 255} +local N = {name = "default:leaves", prob = 223} +local F = {name = "default:apple", prob = 63} +local Y = {name = "default:tree", prob = 255, force_place = true} +local T = {name = "default:tree", prob = 255} + +mts_save("apple_tree", { + size = {x = 7, y = 8, z = 7}, + data = { + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, N, M, N, _, _, + _, _, _, N, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, M, M, F, M, M, _, + _, N, M, M, M, N, _, + _, _, N, M, N, _, _, + _, _, _, _, _, _, _, + + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + N, M, Y, _, _, M, N, + _, M, M, _, Y, M, _, + _, N, M, M, M, N, _, + _, _, _, N, _, _, _, + + _, _, _, Y, _, _, _, + _, _, _, Y, _, _, _, + _, _, _, Y, _, _, _, + _, _, _, Y, _, _, _, + M, F, _, Y, _, F, M, + N, M, _, _, _, M, N, + _, M, M, M, M, M, _, + _, _, N, M, N, _, _, + + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + N, M, _, _, Y, M, N, + _, M, Y, _, M, M, _, + _, N, M, M, M, N, _, + _, _, _, N, _, _, _, + + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, M, M, F, M, M, _, + _, N, M, M, M, N, _, + _, _, N, M, N, _, _, + _, _, _, _, _, _, _, + + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, N, M, N, _, _, + _, _, _, N, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + }, + yslice_prob = { + {ypos = 2, prob = 127}, + }, +}) + + +-- Apple tree from sapling + +mts_save("apple_tree_from_sapling", { + size = {x = 7, y = 8, z = 7}, + data = { + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, N, M, N, _, _, + _, _, _, N, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, M, M, F, M, M, _, + _, N, M, M, M, N, _, + _, _, N, M, N, _, _, + _, _, _, _, _, _, _, + + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + N, M, T, _, _, M, N, + _, M, M, _, T, M, _, + _, N, M, M, M, N, _, + _, _, _, N, _, _, _, + + _, _, _, T, _, _, _, + _, _, _, Y, _, _, _, + _, _, _, T, _, _, _, + _, _, _, T, _, _, _, + M, F, _, T, _, F, M, + N, M, _, _, _, M, N, + _, M, M, M, M, M, _, + _, _, N, M, N, _, _, + + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + N, M, _, _, T, M, N, + _, M, T, _, M, M, _, + _, N, M, M, M, N, _, + _, _, _, N, _, _, _, + + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, M, M, F, M, M, _, + _, N, M, M, M, N, _, + _, _, N, M, N, _, _, + _, _, _, _, _, _, _, + + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, N, M, N, _, _, + _, _, _, N, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + }, + yslice_prob = { + {ypos = 2, prob = 127}, + }, +}) + + +-- Mapgen Jungle tree + +local L = {name = "default:jungleleaves", prob = 255} +local N = {name = "default:jungleleaves", prob = 223} +local M = {name = "default:jungleleaves", prob = 191} +local B = {name = "default:jungletree", prob = 255, force_place = true} +local Y = {name = "default:jungletree", prob = 191, force_place = true} +local U = {name = "default:jungletree", prob = 127, force_place = true} +local I = {name = "default:jungletree", prob = 255} + +mts_save("jungle_tree", { + size = {x = 5, y = 17, z = 5}, + data = { + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + N, L, N, _, _, + _, _, N, L, N, + _, _, _, _, _, + _, _, _, _, _, + M, N, N, N, M, + M, N, N, N, M, + _, _, _, _, _, + + _, _, B, _, _, + _, _, B, _, _, + _, _, U, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + L, B, L, _, _, + _, _, L, B, L, + _, _, _, _, _, + _, _, _, _, _, + N, B, L, B, N, + N, L, L, L, N, + _, N, N, N, _, + + _, B, B, B, _, + _, B, B, B, _, + _, U, B, U, _, + _, _, B, _, _, + _, _, B, _, _, + _, _, B, _, _, + _, _, B, _, _, + _, _, B, _, _, + _, _, B, L, N, + N, L, B, _, _, + N, L, B, _, _, + _, _, B, L, N, + _, _, B, L, N, + _, _, B, _, _, + N, L, L, L, N, + N, L, L, L, N, + _, N, L, N, _, + + _, _, B, _, _, + _, _, B, _, _, + _, _, U, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, L, B, L, + L, B, L, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, L, B, L, + _, _, _, _, _, + N, B, L, B, N, + N, L, L, L, N, + _, N, N, N, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, N, L, N, + N, L, N, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, N, L, N, + _, _, _, _, _, + M, N, N, N, M, + M, N, N, N, M, + _, _, _, _, _, + }, + yslice_prob = { + {ypos=6, prob=191}, + {ypos=7, prob=191}, + {ypos=8, prob=191}, + {ypos=9, prob=191}, + {ypos=10, prob=191}, + }, +}) + + +-- Jungle tree from sapling + +local B = {name = "default:jungletree", prob = 255} +local C = {name = "default:jungletree", prob = 255, force_place = true} +local Y = {name = "default:jungletree", prob = 191} +local U = {name = "default:jungletree", prob = 127} + +mts_save("jungle_tree_from_sapling", { + size = {x = 5, y = 17, z = 5}, + data = { + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + N, L, N, _, _, + _, _, N, L, N, + _, _, _, _, _, + _, _, _, _, _, + M, N, N, N, M, + M, N, N, N, M, + _, _, _, _, _, + + _, _, B, _, _, + _, _, B, _, _, + _, _, U, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + L, B, L, _, _, + _, _, L, B, L, + _, _, _, _, _, + _, _, _, _, _, + N, B, L, B, N, + N, L, L, L, N, + _, N, N, N, _, + + _, B, B, B, _, + _, B, C, B, _, + _, U, B, U, _, + _, _, B, _, _, + _, _, B, _, _, + _, _, B, _, _, + _, _, B, _, _, + _, _, B, _, _, + _, _, B, L, N, + N, L, B, _, _, + N, L, B, _, _, + _, _, B, L, N, + _, _, B, L, N, + _, _, B, _, _, + N, L, L, L, N, + N, L, L, L, N, + _, N, L, N, _, + + _, _, B, _, _, + _, _, B, _, _, + _, _, U, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, L, B, L, + L, B, L, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, L, B, L, + _, _, _, _, _, + N, B, L, B, N, + N, L, L, L, N, + _, N, N, N, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, N, L, N, + N, L, N, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, N, L, N, + _, _, _, _, _, + M, N, N, N, M, + M, N, N, N, M, + _, _, _, _, _, + }, + yslice_prob = { + {ypos=6, prob=191}, + {ypos=7, prob=191}, + {ypos=8, prob=191}, + {ypos=9, prob=191}, + {ypos=10, prob=191}, + }, +}) + + +-- Mapgen Pine tree + +local L = {name = "default:pine_needles", prob = 255} +local M = {name = "default:pine_needles", prob = 223} +local N = {name = "default:pine_needles", prob = 191} +local T = {name = "default:pine_tree", prob = 255, force_place = true} +local B = {name = "default:pine_tree", prob = 255} + +mts_save("pine_tree", { + size = {x = 5, y = 16, z = 5}, + data = { + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + M, L, _, L, M, + _, L, L, L, _, + _, _, _, _, _, + M, L, _, L, M, + _, L, L, L, _, + _, _, _, _, _, + M, L, _, L, M, + _, L, L, L, _, + _, _, _, _, _, + + _, _, T, _, _, + _, _, T, _, _, + _, _, T, _, _, + _, _, T, _, _, + _, _, T, _, _, + _, _, T, _, _, + _, _, T, _, _, + L, _, T, _, L, + _, L, T, L, _, + _, _, T, _, _, + L, _, T, _, L, + _, L, T, L, _, + _, _, T, _, _, + L, _, T, _, L, + _, L, L, L, _, + _, _, L, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + M, L, _, L, M, + _, L, L, L, _, + _, _, _, _, _, + M, L, _, L, M, + _, L, L, L, _, + _, _, _, _, _, + M, L, _, L, M, + _, L, L, L, _, + _, _, _, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + }, + yslice_prob = { + {ypos = 2, prob = 127}, + {ypos = 3, prob = 127}, + {ypos = 4, prob = 127}, + {ypos = 5, prob = 127}, + {ypos = 9, prob = 127}, + {ypos = 12, prob = 127}, + }, +}) + + +-- Pine tree from sapling + +local T = {name = "default:pine_tree", prob = 255} +local U = {name = "default:pine_tree", prob = 255, force_place = true} + +mts_save("pine_tree_from_sapling", { + size = {x = 5, y = 16, z = 5}, + data = { + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + M, L, _, L, M, + _, L, L, L, _, + _, _, _, _, _, + M, L, _, L, M, + _, L, L, L, _, + _, _, _, _, _, + M, L, _, L, M, + _, L, L, L, _, + _, _, _, _, _, + + _, _, T, _, _, + _, _, U, _, _, + _, _, T, _, _, + _, _, T, _, _, + _, _, T, _, _, + _, _, T, _, _, + _, _, T, _, _, + L, _, T, _, L, + _, L, T, L, _, + _, _, T, _, _, + L, _, T, _, L, + _, L, T, L, _, + _, _, T, _, _, + L, _, T, _, L, + _, L, L, L, _, + _, _, L, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + M, L, _, L, M, + _, L, L, L, _, + _, _, _, _, _, + M, L, _, L, M, + _, L, L, L, _, + _, _, _, _, _, + M, L, _, L, M, + _, L, L, L, _, + _, _, _, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + }, + yslice_prob = { + {ypos = 2, prob = 127}, + {ypos = 3, prob = 127}, + {ypos = 4, prob = 127}, + {ypos = 5, prob = 127}, + {ypos = 9, prob = 127}, + {ypos = 12, prob = 127}, + }, +}) + + +-- Snowy pine tree from sapling + +local T = {name = "default:pine_tree", prob = 255} +local U = {name = "default:pine_tree", prob = 255, force_place = true} +local L = {name = "default:pine_needles", prob = 255} +local S = {name = "default:snow", prob = 255} + +mts_save("snowy_pine_tree_from_sapling", { + size = {x = 5, y = 16, z = 5}, + data = { + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + L, L, L, L, L, + S, S, S, S, S, + _, _, _, _, _, + _, _, _, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + M, L, _, L, M, + _, L, L, L, _, + _, _, _, _, _, + L, L, _, L, M, + S, L, L, L, _, + _, _, _, _, _, + _, L, _, L, L, + _, L, L, L, S, + _, S, S, S, _, + _, _, _, _, _, + + _, _, T, _, _, + _, _, U, _, _, + _, _, T, _, _, + _, _, T, _, _, + _, _, T, _, _, + _, _, T, _, _, + L, _, T, _, L, + _, L, T, L, _, + _, _, T, _, _, + L, _, T, _, L, + _, L, T, L, _, + _, _, T, _, _, + L, _, T, _, L, + S, L, L, L, S, + _, S, L, S, _, + _, _, S, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + M, L, _, L, M, + _, L, L, L, _, + _, _, _, _, _, + M, L, _, L, M, + _, L, L, L, _, + _, _, _, _, _, + L, L, _, L, L, + S, L, L, L, S, + _, S, S, S, _, + _, _, _, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, L, + _, _, _, _, S, + _, _, _, _, _, + L, L, L, L, _, + S, S, S, S, _, + _, _, _, _, _, + _, _, _, _, _, + }, + yslice_prob = { + {ypos = 2, prob = 127}, + {ypos = 3, prob = 127}, + {ypos = 4, prob = 127}, + {ypos = 8, prob = 127}, + {ypos = 11, prob = 127}, + }, +}) + + +-- Mapgen Acacia tree + +local L = {name = "default:acacia_leaves", prob = 255} +local M = {name = "default:acacia_leaves", prob = 223} +local T = {name = "default:acacia_tree", prob = 255, force_place = true} + +mts_save("acacia_tree", { + size = {x = 9, y = 9, z = 9}, + data = { + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + M, M, M, M, _, _, _, _, _, + _, _, _, _, M, M, M, M, M, + + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + M, L, L, M, _, _, _, _, _, + _, _, _, _, M, L, L, L, M, + + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, T, _, _, _, _, _, _, + M, L, L, M, _, _, T, _, _, + _, _, _, _, M, L, L, L, M, + + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, T, _, _, _, _, _, + _, _, _, _, _, T, _, _, _, + M, M, M, M, _, _, _, _, _, + _, _, _, _, M, L, L, L, M, + + _, _, _, _, T, _, _, _, _, + _, _, _, _, T, _, _, _, _, + _, _, _, _, T, _, _, _, _, + _, _, _, _, T, _, _, _, _, + _, _, _, _, T, _, _, _, _, + _, _, _, _, T, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + M, M, M, M, M, M, M, M, M, + + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, T, _, _, _, + _, _, _, T, _, _, _, _, _, + _, _, _, _, _, M, M, M, M, + M, L, L, L, M, _, _, _, _, + + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, T, _, _, + _, _, T, _, _, M, L, L, M, + M, L, L, L, M, _, _, _, _, + + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, M, L, L, M, + M, L, L, L, M, _, _, _, _, + + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, M, M, M, M, + M, M, M, M, M, _, _, _, _, + }, + yslice_prob = { + {ypos = 2, prob = 127}, + {ypos = 3, prob = 127}, + {ypos = 4, prob = 127}, + }, +}) + + +-- Acacia tree from sapling + +local T = {name = "default:acacia_tree", prob = 255} +local U = {name = "default:acacia_tree", prob = 255, force_place = true} + +mts_save("acacia_tree_from_sapling", { + size = {x = 9, y = 9, z = 9}, + data = { + + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + M, M, M, M, _, _, _, _, _, + _, _, _, _, M, M, M, M, M, + + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + M, L, L, M, _, _, _, _, _, + _, _, _, _, M, L, L, L, M, + + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, T, _, _, _, _, _, _, + M, L, L, M, _, _, T, _, _, + _, _, _, _, M, L, L, L, M, + + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, T, _, _, _, _, _, + _, _, _, _, _, T, _, _, _, + M, M, M, M, _, _, _, _, _, + _, _, _, _, M, L, L, L, M, + + _, _, _, _, T, _, _, _, _, + _, _, _, _, U, _, _, _, _, + _, _, _, _, T, _, _, _, _, + _, _, _, _, T, _, _, _, _, + _, _, _, _, T, _, _, _, _, + _, _, _, _, T, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + M, M, M, M, M, M, M, M, M, + + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, T, _, _, _, + _, _, _, T, _, _, _, _, _, + _, _, _, _, _, M, M, M, M, + M, L, L, L, M, _, _, _, _, + + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, T, _, _, + _, _, T, _, _, M, L, L, M, + M, L, L, L, M, _, _, _, _, + + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, M, L, L, M, + M, L, L, L, M, _, _, _, _, + + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, _, _, _, _, + _, _, _, _, _, M, M, M, M, + M, M, M, M, M, _, _, _, _, + }, + yslice_prob = { + {ypos = 2, prob = 127}, + {ypos = 3, prob = 127}, + {ypos = 4, prob = 127}, + }, +}) + + +-- Mapgen Aspen tree + +local T = {name = "default:aspen_tree", prob = 255, force_place = true} +local B = {name = "default:aspen_tree", prob = 255} +local L = {name = "default:aspen_leaves", prob = 255} +local M = {name = "default:aspen_leaves", prob = 223} +local N = {name = "default:aspen_leaves", prob = 127} + +mts_save("aspen_tree", { + size = {x = 5, y = 14, z = 5}, + data = { + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, M, L, M, _, + M, L, L, L, M, + _, M, L, M, _, + M, L, L, L, M, + _, M, L, M, _, + M, L, L, L, M, + _, M, L, M, _, + _, _, _, _, _, + + _, _, T, _, _, + _, _, T, _, _, + _, _, T, _, _, + _, _, T, _, _, + _, _, T, _, _, + _, _, T, _, _, + _, L, T, L, _, + L, L, T, L, L, + _, L, T, L, _, + L, L, T, L, L, + _, L, T, L, _, + L, L, T, L, L, + _, L, L, L, _, + _, _, L, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, M, L, M, _, + M, L, L, L, M, + _, M, L, M, _, + M, L, L, L, M, + _, M, L, M, _, + M, L, L, L, M, + _, M, L, M, _, + _, _, _, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + }, + yslice_prob = { + {ypos = 2, prob = 127}, + {ypos = 3, prob = 127}, + {ypos = 4, prob = 127}, + {ypos = 8, prob = 127}, + {ypos = 10, prob = 127}, + }, +}) + + +-- Aspen tree from sapling + +mts_save("aspen_tree_from_sapling", { + size = {x = 5, y = 14, z = 5}, + data = { + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, M, L, M, _, + M, L, L, L, M, + _, M, L, M, _, + M, L, L, L, M, + _, M, L, M, _, + M, L, L, L, M, + _, M, L, M, _, + _, _, _, _, _, + + _, _, B, _, _, + _, _, T, _, _, + _, _, B, _, _, + _, _, B, _, _, + _, _, B, _, _, + _, _, B, _, _, + _, L, B, L, _, + L, L, B, L, L, + _, L, B, L, _, + L, L, B, L, L, + _, L, B, L, _, + L, L, B, L, L, + _, L, L, L, _, + _, _, L, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, M, L, M, _, + M, L, L, L, M, + _, M, L, M, _, + M, L, L, L, M, + _, M, L, M, _, + M, L, L, L, M, + _, M, L, M, _, + _, _, _, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + N, M, L, M, N, + _, _, _, _, _, + _, _, _, _, _, + }, + yslice_prob = { + {ypos = 2, prob = 127}, + {ypos = 3, prob = 127}, + {ypos = 4, prob = 127}, + {ypos = 8, prob = 127}, + {ypos = 10, prob = 127}, + }, +}) + + +-- Mapgen emergent jungle tree + +local L = {name = "default:jungleleaves", prob = 255} +local N = {name = "default:jungleleaves", prob = 223} +local M = {name = "default:jungleleaves", prob = 127} +local B = {name = "default:jungletree", prob = 255, force_place = true} +local U = {name = "default:jungletree", prob = 127, force_place = true} + +mts_save("emergent_jungle_tree", { + size = {x = 7, y = 37, z = 7}, + data = { + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + B, _, _, _, _, _, B, + B, _, _, _, _, _, B, + B, _, _, _, _, _, B, + U, _, _, _, _, _, U, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + N, N, N, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, N, N, N, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, N, N, N, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + N, N, N, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, N, N, N, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, M, M, M, M, M, _, + _, N, N, N, N, N, _, + _, N, N, N, N, N, _, + _, N, N, N, N, N, _, + _, _, _, _, _, _, _, + + _, _, _, _, _, _, _, + _, _, B, _, B, _, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, U, B, _, B, U, _, + _, _, U, _, U, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + N, B, N, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, N, B, N, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, N, B, N, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + N, B, N, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, N, B, N, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + M, _, _, _, _, _, M, + N, L, _, _, _, L, N, + N, B, L, L, L, B, N, + N, L, L, L, L, L, N, + _, N, N, N, N, N, _, + + _, _, B, _, B, _, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, B, B, B, _, + _, B, B, B, B, B, _, + _, B, B, B, B, B, _, + _, B, B, B, B, B, _, + _, U, B, B, B, U, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + N, N, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, _, B, B, N, N, + N, N, N, B, _, _, _, + _, _, _, B, _, _, _, + _, _, N, B, N, _, _, + _, _, _, B, _, _, _, + _, _, _, B, N, N, N, + N, N, B, B, _, _, _, + _, _, _, B, _, _, _, + _, _, _, B, B, N, N, + N, N, N, B, _, _, _, + _, _, _, B, _, _, _, + M, _, B, B, B, _, M, + N, _, B, _, B, _, N, + N, L, L, _, L, L, N, + N, L, L, L, L, L, N, + _, N, L, L, L, N, _, + + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + N, B, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, B, N, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + N, B, B, B, B, _, _, + _, _, B, B, B, _, _, + M, _, B, _, B, _, M, + N, _, _, _, _, _, N, + N, L, _, _, _, L, N, + N, L, L, L, L, L, N, + _, N, L, L, L, N, _, + + _, _, B, _, B, _, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, B, B, B, _, + _, B, B, B, B, B, _, + _, B, B, B, B, B, _, + _, B, B, B, B, B, _, + _, U, B, B, B, U, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, _, B, _, _, _, + N, N, N, B, _, _, _, + _, _, _, B, B, N, N, + _, _, _, B, _, _, _, + N, N, B, B, _, _, _, + _, _, _, B, N, N, N, + _, _, _, B, _, _, _, + _, _, N, B, N, _, _, + _, _, _, B, _, _, _, + N, N, N, B, _, _, _, + _, _, _, B, _, _, _, + M, _, B, B, B, _, M, + N, _, B, _, B, _, N, + N, L, L, _, L, L, N, + N, L, L, L, L, L, N, + _, N, L, L, L, N, _, + + _, _, _, _, _, _, _, + _, _, B, _, B, _, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, U, B, _, B, U, _, + _, _, U, _, U, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, N, B, N, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, N, B, N, + _, _, _, _, _, _, _, + N, B, N, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, N, B, N, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + M, _, _, _, _, _, M, + N, L, _, _, _, L, N, + N, B, L, L, L, B, N, + N, L, L, L, L, L, N, + _, N, N, N, N, N, _, + + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + B, _, _, _, _, _, B, + B, _, _, _, _, _, B, + B, _, _, _, _, _, B, + U, _, _, _, _, _, U, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, N, N, N, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, N, N, N, + _, _, _, _, _, _, _, + N, N, N, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, N, N, N, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, M, M, M, M, M, _, + _, N, N, N, N, N, _, + _, N, N, N, N, N, _, + _, N, N, N, N, N, _, + _, _, _, _, _, _, _, + }, + yslice_prob = { + {ypos = 13, prob = 127}, + {ypos = 14, prob = 127}, + {ypos = 15, prob = 127}, + {ypos = 16, prob = 127}, + {ypos = 17, prob = 127}, + {ypos = 18, prob = 127}, + {ypos = 19, prob = 127}, + {ypos = 20, prob = 127}, + {ypos = 21, prob = 127}, + {ypos = 22, prob = 127}, + {ypos = 23, prob = 127}, + {ypos = 24, prob = 127}, + }, +}) + + +-- Emergent jungle tree from sapling + +local L = {name = "default:jungleleaves", prob = 255} +local N = {name = "default:jungleleaves", prob = 223} +local M = {name = "default:jungleleaves", prob = 127} +local S = {name = "default:jungletree", prob = 255, force_place = true} +local B = {name = "default:jungletree", prob = 255} +local U = {name = "default:jungletree", prob = 127} + +mts_save("emergent_jungle_tree_from_sapling", { + size = {x = 7, y = 37, z = 7}, + data = { + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + B, _, _, _, _, _, B, + B, _, _, _, _, _, B, + B, _, _, _, _, _, B, + U, _, _, _, _, _, U, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + N, N, N, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, N, N, N, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, N, N, N, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + N, N, N, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, N, N, N, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, M, M, M, M, M, _, + _, N, N, N, N, N, _, + _, N, N, N, N, N, _, + _, N, N, N, N, N, _, + _, _, _, _, _, _, _, + + _, _, _, _, _, _, _, + _, _, B, _, B, _, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, U, B, _, B, U, _, + _, _, U, _, U, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + N, B, N, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, N, B, N, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, N, B, N, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + N, B, N, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, N, B, N, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + M, _, _, _, _, _, M, + N, L, _, _, _, L, N, + N, B, L, L, L, B, N, + N, L, L, L, L, L, N, + _, N, N, N, N, N, _, + + _, _, B, _, B, _, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, B, B, B, _, + _, B, B, B, B, B, _, + _, B, B, B, B, B, _, + _, B, B, B, B, B, _, + _, U, B, B, B, U, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + N, N, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, _, B, B, N, N, + N, N, N, B, _, _, _, + _, _, _, B, _, _, _, + _, _, N, B, N, _, _, + _, _, _, B, _, _, _, + _, _, _, B, N, N, N, + N, N, B, B, _, _, _, + _, _, _, B, _, _, _, + _, _, _, B, B, N, N, + N, N, N, B, _, _, _, + _, _, _, B, _, _, _, + M, _, B, B, B, _, M, + N, _, B, _, B, _, N, + N, L, L, _, L, L, N, + N, L, L, L, L, L, N, + _, N, L, L, L, N, _, + + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, B, B, B, _, _, + _, _, B, S, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + N, B, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, B, N, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + N, B, B, B, B, _, _, + _, _, B, B, B, _, _, + M, _, B, _, B, _, M, + N, _, _, _, _, _, N, + N, L, _, _, _, L, N, + N, L, L, L, L, L, N, + _, N, L, L, L, N, _, + + _, _, B, _, B, _, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, B, B, B, _, + _, B, B, B, B, B, _, + _, B, B, B, B, B, _, + _, B, B, B, B, B, _, + _, U, B, B, B, U, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, B, B, B, _, _, + _, _, _, B, _, _, _, + N, N, N, B, _, _, _, + _, _, _, B, B, N, N, + _, _, _, B, _, _, _, + N, N, B, B, _, _, _, + _, _, _, B, N, N, N, + _, _, _, B, _, _, _, + _, _, N, B, N, _, _, + _, _, _, B, _, _, _, + N, N, N, B, _, _, _, + _, _, _, B, _, _, _, + M, _, B, B, B, _, M, + N, _, B, _, B, _, N, + N, L, L, _, L, L, N, + N, L, L, L, L, L, N, + _, N, L, L, L, N, _, + + _, _, _, _, _, _, _, + _, _, B, _, B, _, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, B, B, _, B, B, _, + _, U, B, _, B, U, _, + _, _, U, _, U, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, N, B, N, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, N, B, N, + _, _, _, _, _, _, _, + N, B, N, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, N, B, N, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + M, _, _, _, _, _, M, + N, L, _, _, _, L, N, + N, B, L, L, L, B, N, + N, L, L, L, L, L, N, + _, N, N, N, N, N, _, + + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + B, _, _, _, _, _, B, + B, _, _, _, _, _, B, + B, _, _, _, _, _, B, + U, _, _, _, _, _, U, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, N, N, N, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, N, N, N, + _, _, _, _, _, _, _, + N, N, N, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, N, N, N, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, _, _, _, _, _, _, + _, M, M, M, M, M, _, + _, N, N, N, N, N, _, + _, N, N, N, N, N, _, + _, N, N, N, N, N, _, + _, _, _, _, _, _, _, + }, + yslice_prob = { + {ypos = 13, prob = 127}, + {ypos = 14, prob = 127}, + {ypos = 15, prob = 127}, + {ypos = 16, prob = 127}, + {ypos = 17, prob = 127}, + {ypos = 18, prob = 127}, + {ypos = 19, prob = 127}, + {ypos = 20, prob = 127}, + {ypos = 21, prob = 127}, + {ypos = 22, prob = 127}, + {ypos = 23, prob = 127}, + {ypos = 24, prob = 127}, + }, +}) + + +-- Mapgen small pine tree + +local L = {name = "default:pine_needles", prob = 255} +local M = {name = "default:pine_needles", prob = 223} +local N = {name = "default:pine_needles", prob = 191} +local T = {name = "default:pine_tree", prob = 255, force_place = true} +local B = {name = "default:pine_tree", prob = 255} +local S = {name = "default:snow", prob = 255} + +mts_save("small_pine_tree", { + size = {x = 5, y = 12, z = 5}, + data = { + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, L, L, L, _, + _, _, L, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + L, L, _, L, L, + _, L, L, L, _, + _, L, L, L, _, + _, L, L, L, _, + _, _, L, _, _, + _, _, L, _, _, + _, _, _, _, _, + _, _, _, _, _, + + _, _, T, _, _, + _, _, T, _, _, + _, _, T, _, _, + _, _, T, _, _, + L, _, T, _, L, + L, L, T, L, L, + _, L, T, L, _, + _, L, T, L, _, + _, L, T, L, _, + _, L, L, L, _, + _, _, L, _, _, + _, _, L, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + L, L, _, L, L, + _, L, L, L, _, + _, L, L, L, _, + _, L, L, L, _, + _, _, L, _, _, + _, _, L, _, _, + _, _, _, _, _, + _, _, _, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, L, L, L, _, + _, _, L, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + }, + yslice_prob = { + {ypos = 2, prob = 127}, + {ypos = 3, prob = 127}, + {ypos = 4, prob = 127}, + }, +}) + + +-- Small pine tree from sapling + +mts_save("small_pine_tree_from_sapling", { + size = {x = 5, y = 12, z = 5}, + data = { + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, L, L, L, _, + _, _, L, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + L, L, _, L, L, + _, L, L, L, _, + _, L, L, L, _, + _, L, L, L, _, + _, _, L, _, _, + _, _, L, _, _, + _, _, _, _, _, + _, _, _, _, _, + + _, _, B, _, _, + _, _, T, _, _, + _, _, B, _, _, + _, _, B, _, _, + L, _, B, _, L, + L, L, B, L, L, + _, L, B, L, _, + _, L, B, L, _, + _, L, B, L, _, + _, L, L, L, _, + _, _, L, _, _, + _, _, L, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + L, L, _, L, L, + _, L, L, L, _, + _, L, L, L, _, + _, L, L, L, _, + _, _, L, _, _, + _, _, L, _, _, + _, _, _, _, _, + _, _, _, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, L, L, L, _, + _, _, L, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + }, + yslice_prob = { + {ypos = 2, prob = 127}, + {ypos = 3, prob = 127}, + {ypos = 4, prob = 127}, + }, +}) + + +-- Snowy small pine tree from sapling + +mts_save("snowy_small_pine_tree_from_sapling", { + size = {x = 5, y = 13, z = 5}, + data = { + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, L, L, L, _, + _, S, L, S, _, + _, _, S, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + L, L, _, L, L, + S, L, L, L, S, + _, L, L, L, _, + _, L, L, L, _, + _, S, L, S, _, + _, _, L, _, _, + _, _, S, _, _, + _, _, _, _, _, + _, _, _, _, _, + + _, _, B, _, _, + _, _, T, _, _, + _, _, B, _, _, + _, _, B, _, _, + L, _, B, _, L, + L, L, B, L, L, + S, L, B, L, S, + _, L, B, L, _, + _, L, B, L, _, + _, L, L, L, _, + _, S, L, S, _, + _, _, L, _, _, + _, _, S, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + L, L, _, L, L, + S, L, L, L, S, + _, L, L, L, _, + _, L, L, L, _, + _, S, L, S, _, + _, _, L, _, _, + _, _, S, _, _, + _, _, _, _, _, + _, _, _, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, L, L, L, _, + _, S, L, S, _, + _, _, S, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + }, + yslice_prob = { + {ypos = 2, prob = 127}, + {ypos = 3, prob = 127}, + }, +}) + + +-- Apple tree log + +mts_save("apple_log", { + size = {x = 4, y = 2, z = 1}, + data = { + {name = "default:tree", param2 = 12, prob = 127}, + {name = "default:tree", param2 = 12}, + {name = "default:tree", param2 = 12}, + {name = "default:tree", param2 = 12}, + {name = "air", prob = 0}, + {name = "flowers:mushroom_brown", prob = 63}, + {name = "air", prob = 0}, + {name = "air", prob = 0}, + }, +}) + + +-- Jungletree log + +mts_save("jungle_log", { + size = {x = 5, y = 2, z = 1}, + data = { + {name = "default:jungletree", param2 = 12, prob = 127}, + {name = "default:jungletree", param2 = 12}, + {name = "default:jungletree", param2 = 12}, + {name = "default:jungletree", param2 = 12}, + {name = "default:jungletree", param2 = 12, prob = 127}, + {name = "air", prob = 0}, + {name = "air", prob = 0}, + {name = "flowers:mushroom_brown", prob = 127}, + {name = "air", prob = 0}, + {name = "air", prob = 0}, + }, +}) + + +-- Pine tree log + +mts_save("pine_log", { + size = {x = 5, y = 2, z = 1}, + data = { + {name = "default:pine_tree", param2 = 12, prob = 127}, + {name = "default:pine_tree", param2 = 12}, + {name = "default:pine_tree", param2 = 12}, + {name = "default:pine_tree", param2 = 12}, + {name = "default:pine_tree", param2 = 12, prob = 127}, + {name = "air", prob = 0}, + {name = "air", prob = 0}, + {name = "flowers:mushroom_red", prob = 63}, + {name = "air", prob = 0}, + {name = "air", prob = 0}, + }, +}) + + +-- Acacia tree log + +mts_save("acacia_log", { + size = {x = 5, y = 1, z = 1}, + data = { + {name = "default:acacia_tree", param2 = 12, prob = 127}, + {name = "default:acacia_tree", param2 = 12}, + {name = "default:acacia_tree", param2 = 12}, + {name = "default:acacia_tree", param2 = 12}, + {name = "default:acacia_tree", param2 = 12, prob = 127}, + }, +}) + + +-- Aspen tree log + +mts_save("aspen_log", { + size = {x = 5, y = 2, z = 1}, + data = { + {name = "default:aspen_tree", param2 = 12, prob = 127}, + {name = "default:aspen_tree", param2 = 12}, + {name = "default:aspen_tree", param2 = 12}, + {name = "default:aspen_tree", param2 = 12}, + {name = "default:aspen_tree", param2 = 12, prob = 127}, + {name = "air", prob = 0}, + {name = "flowers:mushroom_red", prob = 63}, + {name = "flowers:mushroom_brown", prob = 63}, + {name = "air", prob = 0}, + {name = "air", prob = 0}, + }, +}) + + +-- Large cactus + +local C = {name = "default:cactus", prob = 255, param2 = 20} +local R = {name = "default:cactus", prob = 255, param2 = 20, force_place = true} +local E = {name = "default:cactus", prob = 127, param2 = 20} + +mts_save("large_cactus", { + size = {x = 5, y = 7, z = 5}, + data = { + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + + _, _, C, _, _, + _, _, R, _, _, + _, _, C, _, _, + C, C, C, C, C, + C, _, C, _, C, + E, _, C, _, E, + _, _, C, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + _, _, _, _, _, + }, + yslice_prob = { + {ypos = 2, prob = 127}, + }, +}) + + +-- Papyrus + +mts_save("papyrus_on_dirt", { + size = {x = 1, y = 7, z = 1}, + data = { + {name = "default:dirt", prob = 255, force_place = true}, + {name = "default:dirt", prob = 255, force_place = true}, + {name = "default:papyrus", prob = 255}, + {name = "default:papyrus", prob = 255}, + {name = "default:papyrus", prob = 255}, + {name = "default:papyrus", prob = 255}, + {name = "default:papyrus", prob = 255}, + }, + yslice_prob = { + {ypos = 2, prob = 127}, + {ypos = 3, prob = 127}, + }, +}) + +mts_save("papyrus_on_dry_dirt", { + size = {x = 1, y = 7, z = 1}, + data = { + {name = "default:dry_dirt", prob = 255, force_place = true}, + {name = "default:dry_dirt", prob = 255, force_place = true}, + {name = "default:papyrus", prob = 255}, + {name = "default:papyrus", prob = 255}, + {name = "default:papyrus", prob = 255}, + {name = "default:papyrus", prob = 255}, + {name = "default:papyrus", prob = 255}, + }, + yslice_prob = { + {ypos = 2, prob = 127}, + {ypos = 3, prob = 127}, + }, +}) + + +-- Bush + +local L = {name = "default:bush_leaves", prob = 255} +local M = {name = "default:bush_leaves", prob = 191} +local N = {name = "default:bush_leaves", prob = 127} +local S = {name = "default:bush_stem", prob = 255, force_place = true} + +mts_save("bush", { + size = {x = 3, y = 3, z = 3}, + data = { + _, _, _, + M, L, M, + N, M, N, + + _, _, _, + L, S, L, + M, L, M, + + _, _, _, + M, L, M, + N, M, N, + }, +}) + + +-- Blueberry bush + +local L = {name = "default:blueberry_bush_leaves_with_berries", prob = 255, force_place = true} +local M = {name = "default:blueberry_bush_leaves_with_berries", prob = 223} +local N = {name = "default:blueberry_bush_leaves_with_berries", prob = 95} + +mts_save("blueberry_bush", { + size = {x = 3, y = 1, z = 3}, + data = { + N, M, N, + + M, L, M, + + N, M, N, + }, +}) + + +-- Acacia bush + +local L = {name = "default:acacia_bush_leaves", prob = 255} +local M = {name = "default:acacia_bush_leaves", prob = 191} +local N = {name = "default:acacia_bush_leaves", prob = 127} +local S = {name = "default:acacia_bush_stem", prob = 255, force_place = true} + +mts_save("acacia_bush", { + size = {x = 3, y = 3, z = 3}, + data = { + _, _, _, + N, M, N, + M, L, M, + + _, _, _, + M, S, M, + L, L, L, + + _, _, _, + N, M, N, + M, L, M, + }, +}) + + +-- Pine bush + +local L = {name = "default:pine_bush_needles", prob = 255} +local M = {name = "default:pine_bush_needles", prob = 191} +local N = {name = "default:pine_bush_needles", prob = 127} +local S = {name = "default:pine_bush_stem", prob = 255, force_place = true} + +mts_save("pine_bush", { + size = {x = 3, y = 3, z = 3}, + data = { + _, _, _, + M, L, M, + N, M, N, + + _, _, _, + L, S, L, + M, L, M, + + _, _, _, + M, L, M, + N, M, N, + }, +}) diff --git a/screenshot.png b/screenshot.png new file mode 100644 index 0000000..5498b60 Binary files /dev/null and b/screenshot.png differ diff --git a/settingtypes.txt b/settingtypes.txt new file mode 100644 index 0000000..eff1e90 --- /dev/null +++ b/settingtypes.txt @@ -0,0 +1,77 @@ +# This file contains settings of minetest_game that can be changed in +# minetest.conf + +# In creative mode players are able to dig all kind of blocks nearly +# instantly, and have access to unlimited resources. +# Some of the functionality is only available if this setting is present +# at startup. +creative_mode (Creative mode) bool false + +# Flammable nodes will be ignited by nearby igniters. Spreading fire may +# cause severe destruction. +# Spreading fire nodes will disappear when fire is disabled, but +# 'permanent_flame' nodes are unaffected. +enable_fire (Fire) bool true + +# Enable flame sound. +flame_sound (Flame sound) bool true + +# Enable lavacooling. +enable_lavacooling (Lavacooling) bool true + +# If enabled, steel tools, torches and cobblestone will be given to new +# players. +give_initial_stuff (Give initial items) bool false + +# If enabled, players respawn at the bed they last lay on instead of normal +# spawn. +# This setting is only read at startup. +enable_bed_respawn (Respawn at bed) bool true + +# If enabled, the night can be skipped if more than half of the players are +# in beds. +enable_bed_night_skip (Skip night when sleeping) bool true + +# If enabled, fences and walls cannot be jumped over. +enable_fence_tall (Tall fences and walls) bool false + +# When TNT explodes, it destroys nearby nodes and damages nearby players. +# This setting is disabled by default on servers. +enable_tnt (TNT) bool true + +# The radius in which nodes will be destroyed by a TNT explosion. +tnt_radius (TNT radius) int 3 0 + +# 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 mode) enum bones bones,drop,keep + +# The time in seconds after which the bones of a dead player can be looted +# by everyone. +# Setting this to 0 will disable sharing of bones completely. +share_bones_time (Bones share time) int 1200 0 + +# How much earlier the bones of a dead player can be looted by +# everyone if the player dies in a protected area they don't own. +# 0 to disable. By default it is "share_bones_time" divide by four. +share_bones_time_early (Earlier bones share time) int 300 0 + +# Inform player of condition and location of new bones. +bones_position_message (Inform player about bones) bool false + +# Replaces old stairs with new ones. Only required for older worlds. +enable_stairs_replace_abm (Replace old stairs) bool false + +# If enabled, use the engine's spawn search which does not check for a +# suitable starting biome. +engine_spawn (Use engine spawn search) bool false + +# Whether river water source nodes create flowing sounds. +# Helps rivers create more sound, especially on level sections. +river_source_sounds (River source node sounds) bool false + +# Enable cloud variation by the 'weather' mod. +# Non-functional in V6 or Singlenode mapgens. +enable_weather (Enable weather) bool true