pax_global_header00006660000000000000000000000064141057430210014507gustar00rootroot0000000000000052 comment=5f5bd8b5fb3a57e28ec6605a22d7e8410d91ba88 minetest-skyblock-0.3.0/000077500000000000000000000000001410574302100151565ustar00rootroot00000000000000minetest-skyblock-0.3.0/.github/000077500000000000000000000000001410574302100165165ustar00rootroot00000000000000minetest-skyblock-0.3.0/.github/workflows/000077500000000000000000000000001410574302100205535ustar00rootroot00000000000000minetest-skyblock-0.3.0/.github/workflows/build.yml000066400000000000000000000003641410574302100224000ustar00rootroot00000000000000on: [push, pull_request] name: build jobs: lint: runs-on: ubuntu-latest steps: - uses: actions/checkout@master - name: lint uses: Roang-zero1/factorio-mod-luacheck@master with: luacheckrc_url: "" minetest-skyblock-0.3.0/.luacheckrc000066400000000000000000000006631410574302100172700ustar00rootroot00000000000000unused_args = false allow_defined_top = true max_line_length = 999 globals = { "skyblock", "minetest", } read_globals = { string = {fields = {"split", "trim"}}, table = {fields = {"copy", "getn"}}, "VoxelArea", "unified_inventory", "core", "ItemStack", "default", "bucket", } files["skyblock/register_misc.lua"].ignore = { "vm", "area", "data" } files["skyblock/skyblock.lua"].ignore = { "filename", "t" } minetest-skyblock-0.3.0/CONTRIBUTING.md000066400000000000000000000015101410574302100174040ustar00rootroot00000000000000# Contributing Contributions are **welcome** and will be fully **credited**. We accept contributions via Pull Requests on [Github](https://github.com/bedezign/yii2-audit). ## Pull Requests - **Document any change in behaviour** - Make sure any relevant documentation is kept up-to-date. - **Consider our release cycle** - We try to follow [SemVer v2.0.0](http://semver.org/). Randomly breaking public APIs is not an option. - **Create feature branches** - Don't ask us to pull from your master branch. - **One pull request per feature** - If you want to do more than one thing, send multiple pull requests. - **Send coherent history** - Make sure each individual commit in your pull request is meaningful. If you had to make multiple intermediate commits while developing, please squash them before submitting. **Happy coding**! minetest-skyblock-0.3.0/LICENSE.md000066400000000000000000001045521410574302100165710ustar00rootroot00000000000000GNU GENERAL PUBLIC LICENSE ========================== Version 3, 29 June 2007 Copyright © 2007 Free Software Foundation, Inc. <> Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. ## Preamble The GNU General Public License is a free, copyleft license for software and other kinds of works. The licenses for most software and other practical works are designed to take away your freedom to share and change the works. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change all versions of a program--to make sure it remains free software for all its users. We, the Free Software Foundation, use the GNU General Public License for most of our software; it applies also to any other work released this way by its authors. You can apply it to your programs, too. When we speak of free software, we are referring to freedom, 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 them if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs, and that you know you can do these things. To protect your rights, we need to prevent others from denying you these rights or asking you to surrender the rights. Therefore, you have certain responsibilities if you distribute copies of the software, or if you modify it: responsibilities to respect the freedom of others. For example, if you distribute copies of such a program, whether gratis or for a fee, you must pass on to the recipients the same freedoms that you received. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights. Developers that use the GNU GPL protect your rights with two steps: (1) assert copyright on the software, and (2) offer you this License giving you legal permission to copy, distribute and/or modify it. For the developers' and authors' protection, the GPL clearly explains that there is no warranty for this free software. For both users' and authors' sake, the GPL requires that modified versions be marked as changed, so that their problems will not be attributed erroneously to authors of previous versions. Some devices are designed to deny users access to install or run modified versions of the software inside them, although the manufacturer can do so. This is fundamentally incompatible with the aim of protecting users' freedom to change the software. The systematic pattern of such abuse occurs in the area of products for individuals to use, which is precisely where it is most unacceptable. Therefore, we have designed this version of the GPL to prohibit the practice for those products. If such problems arise substantially in other domains, we stand ready to extend this provision to those domains in future versions of the GPL, as needed to protect the freedom of users. Finally, every program is threatened constantly by software patents. States should not allow patents to restrict development and use of software on general-purpose computers, but in those that do, we wish to avoid the special danger that patents applied to a free program could make it effectively proprietary. To prevent this, the GPL assures that patents cannot be used to render the program non-free. The precise terms and conditions for copying, distribution and modification follow. ## TERMS AND CONDITIONS ### 0. Definitions. “This License” refers to version 3 of the GNU General Public License. “Copyright” also means copyright-like laws that apply to other kinds of works, such as semiconductor masks. “The Program” refers to any copyrightable work licensed under this License. Each licensee is addressed as “you”. “Licensees” and “recipients” may be individuals or organizations. To “modify” a work means to copy from or adapt all or part of the work in a fashion requiring copyright permission, other than the making of an exact copy. The resulting work is called a “modified version” of the earlier work or a work “based on” the earlier work. A “covered work” means either the unmodified Program or a work based on the Program. To “propagate” a work means to do anything with it that, without permission, would make you directly or secondarily liable for infringement under applicable copyright law, except executing it on a computer or modifying a private copy. Propagation includes copying, distribution (with or without modification), making available to the public, and in some countries other activities as well. To “convey” a work means any kind of propagation that enables other parties to make or receive copies. Mere interaction with a user through a computer network, with no transfer of a copy, is not conveying. An interactive user interface displays “Appropriate Legal Notices” to the extent that it includes a convenient and prominently visible feature that (1) displays an appropriate copyright notice, and (2) tells the user that there is no warranty for the work (except to the extent that warranties are provided), that licensees may convey the work under this License, and how to view a copy of this License. If the interface presents a list of user commands or options, such as a menu, a prominent item in the list meets this criterion. ### 1. Source Code. The “source code” for a work means the preferred form of the work for making modifications to it. “Object code” means any non-source form of a work. A “Standard Interface” means an interface that either is an official standard defined by a recognized standards body, or, in the case of interfaces specified for a particular programming language, one that is widely used among developers working in that language. The “System Libraries” of an executable work include anything, other than the work as a whole, that (a) is included in the normal form of packaging a Major Component, but which is not part of that Major Component, and (b) serves only to enable use of the work with that Major Component, or to implement a Standard Interface for which an implementation is available to the public in source code form. A “Major Component”, in this context, means a major essential component (kernel, window system, and so on) of the specific operating system (if any) on which the executable work runs, or a compiler used to produce the work, or an object code interpreter used to run it. The “Corresponding Source” for a work in object code form means all the source code needed to generate, install, and (for an executable work) run the object code and to modify the work, including scripts to control those activities. However, it does not include the work's System Libraries, or general-purpose tools or generally available free programs which are used unmodified in performing those activities but which are not part of the work. For example, Corresponding Source includes interface definition files associated with source files for the work, and the source code for shared libraries and dynamically linked subprograms that the work is specifically designed to require, such as by intimate data communication or control flow between those subprograms and other parts of the work. The Corresponding Source need not include anything that users can regenerate automatically from other parts of the Corresponding Source. The Corresponding Source for a work in source code form is that same work. ### 2. Basic Permissions. All rights granted under this License are granted for the term of copyright on the Program, and are irrevocable provided the stated conditions are met. This License explicitly affirms your unlimited permission to run the unmodified Program. The output from running a covered work is covered by this License only if the output, given its content, constitutes a covered work. This License acknowledges your rights of fair use or other equivalent, as provided by copyright law. You may make, run and propagate covered works that you do not convey, without conditions so long as your license otherwise remains in force. You may convey covered works to others for the sole purpose of having them make modifications exclusively for you, or provide you with facilities for running those works, provided that you comply with the terms of this License in conveying all material for which you do not control copyright. Those thus making or running the covered works for you must do so exclusively on your behalf, under your direction and control, on terms that prohibit them from making any copies of your copyrighted material outside their relationship with you. Conveying under any other circumstances is permitted solely under the conditions stated below. Sublicensing is not allowed; section 10 makes it unnecessary. ### 3. Protecting Users' Legal Rights From Anti-Circumvention Law. No covered work shall be deemed part of an effective technological measure under any applicable law fulfilling obligations under article 11 of the WIPO copyright treaty adopted on 20 December 1996, or similar laws prohibiting or restricting circumvention of such measures. When you convey a covered work, you waive any legal power to forbid circumvention of technological measures to the extent such circumvention is effected by exercising rights under this License with respect to the covered work, and you disclaim any intention to limit operation or modification of the work as a means of enforcing, against the work's users, your or third parties' legal rights to forbid circumvention of technological measures. ### 4. Conveying Verbatim Copies. You may convey verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice; keep intact all notices stating that this License and any non-permissive terms added in accord with section 7 apply to the code; keep intact all notices of the absence of any warranty; and give all recipients a copy of this License along with the Program. You may charge any price or no price for each copy that you convey, and you may offer support or warranty protection for a fee. ### 5. Conveying Modified Source Versions. You may convey a work based on the Program, or the modifications to produce it from the Program, in the form of source code under the terms of section 4, provided that you also meet all of these conditions: * **a)** The work must carry prominent notices stating that you modified it, and giving a relevant date. * **b)** The work must carry prominent notices stating that it is released under this License and any conditions added under section 7. This requirement modifies the requirement in section 4 to “keep intact all notices”. * **c)** You must license the entire work, as a whole, under this License to anyone who comes into possession of a copy. This License will therefore apply, along with any applicable section 7 additional terms, to the whole of the work, and all its parts, regardless of how they are packaged. This License gives no permission to license the work in any other way, but it does not invalidate such permission if you have separately received it. * **d)** If the work has interactive user interfaces, each must display Appropriate Legal Notices; however, if the Program has interactive interfaces that do not display Appropriate Legal Notices, your work need not make them do so. A compilation of a covered work with other separate and independent works, which are not by their nature extensions of the covered work, and which are not combined with it such as to form a larger program, in or on a volume of a storage or distribution medium, is called an “aggregate” if the compilation and its resulting copyright are not used to limit the access or legal rights of the compilation's users beyond what the individual works permit. Inclusion of a covered work in an aggregate does not cause this License to apply to the other parts of the aggregate. ### 6. Conveying Non-Source Forms. You may convey a covered work in object code form under the terms of sections 4 and 5, provided that you also convey the machine-readable Corresponding Source under the terms of this License, in one of these ways: * **a)** Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by the Corresponding Source fixed on a durable physical medium customarily used for software interchange. * **b)** Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by a written offer, valid for at least three years and valid for as long as you offer spare parts or customer support for that product model, to give anyone who possesses the object code either (1) a copy of the Corresponding Source for all the software in the product that is covered by this License, on a durable physical medium customarily used for software interchange, for a price no more than your reasonable cost of physically performing this conveying of source, or (2) access to copy the Corresponding Source from a network server at no charge. * **c)** Convey individual copies of the object code with a copy of the written offer to provide the Corresponding Source. This alternative is allowed only occasionally and noncommercially, and only if you received the object code with such an offer, in accord with subsection 6b. * **d)** Convey the object code by offering access from a designated place (gratis or for a charge), and offer equivalent access to the Corresponding Source in the same way through the same place at no further charge. You need not require recipients to copy the Corresponding Source along with the object code. If the place to copy the object code is a network server, the Corresponding Source may be on a different server (operated by you or a third party) that supports equivalent copying facilities, provided you maintain clear directions next to the object code saying where to find the Corresponding Source. Regardless of what server hosts the Corresponding Source, you remain obligated to ensure that it is available for as long as needed to satisfy these requirements. * **e)** Convey the object code using peer-to-peer transmission, provided you inform other peers where the object code and Corresponding Source of the work are being offered to the general public at no charge under subsection 6d. A separable portion of the object code, whose source code is excluded from the Corresponding Source as a System Library, need not be included in conveying the object code work. A “User Product” is either (1) a “consumer product”, which means any tangible personal property which is normally used for personal, family, or household purposes, or (2) anything designed or sold for incorporation into a dwelling. In determining whether a product is a consumer product, doubtful cases shall be resolved in favor of coverage. For a particular product received by a particular user, “normally used” refers to a typical or common use of that class of product, regardless of the status of the particular user or of the way in which the particular user actually uses, or expects or is expected to use, the product. A product is a consumer product regardless of whether the product has substantial commercial, industrial or non-consumer uses, unless such uses represent the only significant mode of use of the product. “Installation Information” for a User Product means any methods, procedures, authorization keys, or other information required to install and execute modified versions of a covered work in that User Product from a modified version of its Corresponding Source. The information must suffice to ensure that the continued functioning of the modified object code is in no case prevented or interfered with solely because modification has been made. If you convey an object code work under this section in, or with, or specifically for use in, a User Product, and the conveying occurs as part of a transaction in which the right of possession and use of the User Product is transferred to the recipient in perpetuity or for a fixed term (regardless of how the transaction is characterized), the Corresponding Source conveyed under this section must be accompanied by the Installation Information. But this requirement does not apply if neither you nor any third party retains the ability to install modified object code on the User Product (for example, the work has been installed in ROM). The requirement to provide Installation Information does not include a requirement to continue to provide support service, warranty, or updates for a work that has been modified or installed by the recipient, or for the User Product in which it has been modified or installed. Access to a network may be denied when the modification itself materially and adversely affects the operation of the network or violates the rules and protocols for communication across the network. Corresponding Source conveyed, and Installation Information provided, in accord with this section must be in a format that is publicly documented (and with an implementation available to the public in source code form), and must require no special password or key for unpacking, reading or copying. ### 7. Additional Terms. “Additional permissions” are terms that supplement the terms of this License by making exceptions from one or more of its conditions. Additional permissions that are applicable to the entire Program shall be treated as though they were included in this License, to the extent that they are valid under applicable law. If additional permissions apply only to part of the Program, that part may be used separately under those permissions, but the entire Program remains governed by this License without regard to the additional permissions. When you convey a copy of a covered work, you may at your option remove any additional permissions from that copy, or from any part of it. (Additional permissions may be written to require their own removal in certain cases when you modify the work.) You may place additional permissions on material, added by you to a covered work, for which you have or can give appropriate copyright permission. Notwithstanding any other provision of this License, for material you add to a covered work, you may (if authorized by the copyright holders of that material) supplement the terms of this License with terms: * **a)** Disclaiming warranty or limiting liability differently from the terms of sections 15 and 16 of this License; or * **b)** Requiring preservation of specified reasonable legal notices or author attributions in that material or in the Appropriate Legal Notices displayed by works containing it; or * **c)** Prohibiting misrepresentation of the origin of that material, or requiring that modified versions of such material be marked in reasonable ways as different from the original version; or * **d)** Limiting the use for publicity purposes of names of licensors or authors of the material; or * **e)** Declining to grant rights under trademark law for use of some trade names, trademarks, or service marks; or * **f)** Requiring indemnification of licensors and authors of that material by anyone who conveys the material (or modified versions of it) with contractual assumptions of liability to the recipient, for any liability that these contractual assumptions directly impose on those licensors and authors. All other non-permissive additional terms are considered “further restrictions” within the meaning of section 10. If the Program as you received it, or any part of it, contains a notice stating that it is governed by this License along with a term that is a further restriction, you may remove that term. If a license document contains a further restriction but permits relicensing or conveying under this License, you may add to a covered work material governed by the terms of that license document, provided that the further restriction does not survive such relicensing or conveying. If you add terms to a covered work in accord with this section, you must place, in the relevant source files, a statement of the additional terms that apply to those files, or a notice indicating where to find the applicable terms. Additional terms, permissive or non-permissive, may be stated in the form of a separately written license, or stated as exceptions; the above requirements apply either way. ### 8. Termination. You may not propagate or modify a covered work except as expressly provided under this License. Any attempt otherwise to propagate or modify it is void, and will automatically terminate your rights under this License (including any patent licenses granted under the third paragraph of section 11). However, if you cease all violation of this License, then your license from a particular copyright holder is reinstated (a) provisionally, unless and until the copyright holder explicitly and finally terminates your license, and (b) permanently, if the copyright holder fails to notify you of the violation by some reasonable means prior to 60 days after the cessation. Moreover, your license from a particular copyright holder is reinstated permanently if the copyright holder notifies you of the violation by some reasonable means, this is the first time you have received notice of violation of this License (for any work) from that copyright holder, and you cure the violation prior to 30 days after your receipt of the notice. Termination of your rights under this section does not terminate the licenses of parties who have received copies or rights from you under this License. If your rights have been terminated and not permanently reinstated, you do not qualify to receive new licenses for the same material under section 10. ### 9. Acceptance Not Required for Having Copies. You are not required to accept this License in order to receive or run a copy of the Program. Ancillary propagation of a covered work occurring solely as a consequence of using peer-to-peer transmission to receive a copy likewise does not require acceptance. However, nothing other than this License grants you permission to propagate or modify any covered work. These actions infringe copyright if you do not accept this License. Therefore, by modifying or propagating a covered work, you indicate your acceptance of this License to do so. ### 10. Automatic Licensing of Downstream Recipients. Each time you convey a covered work, the recipient automatically receives a license from the original licensors, to run, modify and propagate that work, subject to this License. You are not responsible for enforcing compliance by third parties with this License. An “entity transaction” is a transaction transferring control of an organization, or substantially all assets of one, or subdividing an organization, or merging organizations. If propagation of a covered work results from an entity transaction, each party to that transaction who receives a copy of the work also receives whatever licenses to the work the party's predecessor in interest had or could give under the previous paragraph, plus a right to possession of the Corresponding Source of the work from the predecessor in interest, if the predecessor has it or can get it with reasonable efforts. You may not impose any further restrictions on the exercise of the rights granted or affirmed under this License. For example, you may not impose a license fee, royalty, or other charge for exercise of rights granted under this License, and you may not initiate litigation (including a cross-claim or counterclaim in a lawsuit) alleging that any patent claim is infringed by making, using, selling, offering for sale, or importing the Program or any portion of it. ### 11. Patents. A “contributor” is a copyright holder who authorizes use under this License of the Program or a work on which the Program is based. The work thus licensed is called the contributor's “contributor version”. A contributor's “essential patent claims” are all patent claims owned or controlled by the contributor, whether already acquired or hereafter acquired, that would be infringed by some manner, permitted by this License, of making, using, or selling its contributor version, but do not include claims that would be infringed only as a consequence of further modification of the contributor version. For purposes of this definition, “control” includes the right to grant patent sublicenses in a manner consistent with the requirements of this License. Each contributor grants you a non-exclusive, worldwide, royalty-free patent license under the contributor's essential patent claims, to make, use, sell, offer for sale, import and otherwise run, modify and propagate the contents of its contributor version. In the following three paragraphs, a “patent license” is any express agreement or commitment, however denominated, not to enforce a patent (such as an express permission to practice a patent or covenant not to sue for patent infringement). To “grant” such a patent license to a party means to make such an agreement or commitment not to enforce a patent against the party. If you convey a covered work, knowingly relying on a patent license, and the Corresponding Source of the work is not available for anyone to copy, free of charge and under the terms of this License, through a publicly available network server or other readily accessible means, then you must either (1) cause the Corresponding Source to be so available, or (2) arrange to deprive yourself of the benefit of the patent license for this particular work, or (3) arrange, in a manner consistent with the requirements of this License, to extend the patent license to downstream recipients. “Knowingly relying” means you have actual knowledge that, but for the patent license, your conveying the covered work in a country, or your recipient's use of the covered work in a country, would infringe one or more identifiable patents in that country that you have reason to believe are valid. If, pursuant to or in connection with a single transaction or arrangement, you convey, or propagate by procuring conveyance of, a covered work, and grant a patent license to some of the parties receiving the covered work authorizing them to use, propagate, modify or convey a specific copy of the covered work, then the patent license you grant is automatically extended to all recipients of the covered work and works based on it. A patent license is “discriminatory” if it does not include within the scope of its coverage, prohibits the exercise of, or is conditioned on the non-exercise of one or more of the rights that are specifically granted under this License. You may not convey a covered work if you are a party to an arrangement with a third party that is in the business of distributing software, under which you make payment to the third party based on the extent of your activity of conveying the work, and under which the third party grants, to any of the parties who would receive the covered work from you, a discriminatory patent license (a) in connection with copies of the covered work conveyed by you (or copies made from those copies), or (b) primarily for and in connection with specific products or compilations that contain the covered work, unless you entered into that arrangement, or that patent license was granted, prior to 28 March 2007. Nothing in this License shall be construed as excluding or limiting any implied license or other defenses to infringement that may otherwise be available to you under applicable patent law. ### 12. No Surrender of Others' Freedom. If 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 convey a covered work so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not convey it at all. For example, if you agree to terms that obligate you to collect a royalty for further conveying from those to whom you convey the Program, the only way you could satisfy both those terms and this License would be to refrain entirely from conveying the Program. ### 13. Use with the GNU Affero General Public License. Notwithstanding any other provision of this License, you have permission to link or combine any covered work with a work licensed under version 3 of the GNU Affero General Public License into a single combined work, and to convey the resulting work. The terms of this License will continue to apply to the part which is the covered work, but the special requirements of the GNU Affero General Public License, section 13, concerning interaction through a network will apply to the combination as such. ### 14. Revised Versions of this License. The Free Software Foundation may publish revised and/or new versions of the GNU 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 Program specifies that a certain numbered version of the GNU General Public License “or any later version” applies to it, you have the option of following the terms and conditions either of that numbered version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of the GNU General Public License, you may choose any version ever published by the Free Software Foundation. If the Program specifies that a proxy can decide which future versions of the GNU General Public License can be used, that proxy's public statement of acceptance of a version permanently authorizes you to choose that version for the Program. Later license versions may give you additional or different permissions. However, no additional obligations are imposed on any author or copyright holder as a result of your choosing to follow a later version. ### 15. Disclaimer of Warranty. THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM “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 PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. ### 16. Limitation of Liability. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS THE PROGRAM 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 PROGRAM (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 PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. ### 17. Interpretation of Sections 15 and 16. If the disclaimer of warranty and limitation of liability provided above cannot be given local legal effect according to their terms, reviewing courts shall apply local law that most closely approximates an absolute waiver of all civil liability in connection with the Program, unless a warranty or assumption of liability accompanies a copy of the Program in return for a fee. END OF TERMS AND CONDITIONS ## How to Apply These Terms to Your New Programs If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms. To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively state 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 program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Also add information on how to contact you by electronic and paper mail. If the program does terminal interaction, make it output a short notice like this when it starts in an interactive mode: Copyright (C) This program comes with ABSOLUTELY NO WARRANTY; for details type 'show w'. This is free software, and you are welcome to redistribute it under certain conditions; type 'show c' for details. The hypothetical commands 'show w' and 'show c' should show the appropriate parts of the General Public License. Of course, your program's commands might be different; for a GUI interface, you would use an “about box”. You should also get your employer (if you work as a programmer) or school, if any, to sign a “copyright disclaimer” for the program, if necessary. For more information on this, and how to apply and follow the GNU GPL, see <>. The GNU General Public License does not permit incorporating your program into proprietary programs. If your program is a subroutine library, you may consider it more useful to permit linking proprietary applications with the library. If this is what you want to do, use the GNU Lesser General Public License instead of this License. But first, please read <>.minetest-skyblock-0.3.0/README.md000066400000000000000000000034111410574302100164340ustar00rootroot00000000000000# Skyblock for Minetest [![Build status](https://github.com/cornernote/minetest-skyblock/workflows/build/badge.svg)](https://github.com/cornernote/minetest-skyblock/actions) [![home](https://img.shields.io/badge/skyblock-home-blue.svg?style=flat-square)](https://cornernote.github.io/minetest-skyblock/) [![chat](https://img.shields.io/badge/gitter-join%20chat-blue.svg?style=flat-square)](https://gitter.im/cornernote/minetest-skyblock) [![download](https://img.shields.io/github/tag/cornernote/minetest-skyblock.svg?style=flat-square&label=release)](https://github.com/cornernote/minetest-skyblock/releases) [![forum](https://img.shields.io/badge/minetest-mod-green.svg?style=flat-square)](https://forum.minetest.net/viewtopic.php?id=2799) [![bower](https://img.shields.io/badge/bower-mod-green.svg?style=flat-square)](https://minetest-bower.herokuapp.com/mods/skyblock) [![license](https://img.shields.io/badge/license-GPL3-brightgreen.svg?style=flat-square)](https://github.com/cornernote/minetest-skyblock/blob/master/LICENSE.md) ![SkyBlock](https://cloud.githubusercontent.com/assets/51875/9219481/4c7248b6-411a-11e5-81f1-5e4726a1fa99.png) ## Description Build a world starting from a small island in the sky. This Minetest mod is intended to be used as a minimal game that allows the player to craft and use all the default items in Minetest in a fun and challenging way. ## Project Resources * [Home](https://cornernote.github.io/minetest-skyblock/) * [Chat](https://gitter.im/cornernote/minetest-skyblock) * [Download](https://github.com/cornernote/minetest-skyblock/releases) * [Forum](https://forum.minetest.net/viewtopic.php?id=2799) * [Bower](https://minetest-bower.herokuapp.com/mods/skyblock) * [License](https://github.com/cornernote/minetest-skyblock/blob/master/LICENSE.md) minetest-skyblock-0.3.0/bower.json000066400000000000000000000014161410574302100171710ustar00rootroot00000000000000{ "name": "skyblock", "homepage": "https://cornernote.github.io/minetest-skyblock/", "description": "Build a world starting from a small island in the sky.", "keywords": [ "skyblock", "quest", "fun", "feat", "island" ], "screenshots": [ "https://cloud.githubusercontent.com/assets/51875/9104936/32308738-3c51-11e5-987e-ae805a724a01.png", "https://cloud.githubusercontent.com/assets/51875/9005792/697893a6-37c0-11e5-9a23-f20f93c2325b.png", "https://cloud.githubusercontent.com/assets/51875/9005796/6d8d6b24-37c0-11e5-9c14-b7bb8d66e6e3.png", "https://cloud.githubusercontent.com/assets/51875/9005798/71a68088-37c0-11e5-8f1a-02d1cdd983dc.png" ], "authors": [ "cornernote" ], "license": "GPL", "ignore": [ "**/.*" ] } minetest-skyblock-0.3.0/modpack.conf000066400000000000000000000001351410574302100174420ustar00rootroot00000000000000name = minetest-skyblock description = Build a world starting from a small island in the sky.minetest-skyblock-0.3.0/skyblock/000077500000000000000000000000001410574302100167775ustar00rootroot00000000000000minetest-skyblock-0.3.0/skyblock/init.lua000066400000000000000000000016731410574302100204540ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- minetest.log('action', ' __ __ __ __ ') minetest.log('action', ' _____/ /____ __/ /_ / /___ _____/ /__') minetest.log('action', ' / ___/ //_/ / / / __ \\/ / __ \\/ ___/ //_/') minetest.log('action', ' (__ ) ,< / /_/ / /_/ / / /_/ / /__/ ,< ') minetest.log('action', '/____/_/|_|\\__, /_.___/_/\\____/\\___/_/|_| ') minetest.log('action', ' /____/ ') local modpath = minetest.get_modpath('skyblock') -- load apis dofile(modpath..'/skyblock.lua') -- register entities dofile(modpath..'/register_node.lua') dofile(modpath..'/register_misc.lua') -- log that we started skyblock.log('[MOD]'..minetest.get_current_modname()..' -- loaded from '..minetest.get_modpath(minetest.get_current_modname()))minetest-skyblock-0.3.0/skyblock/mod.conf000066400000000000000000000001471410574302100204270ustar00rootroot00000000000000name = skyblock depends = default description = Build a world starting from a small island in the sky. minetest-skyblock-0.3.0/skyblock/register_misc.lua000066400000000000000000000062101410574302100223400ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- -- set mapgen to singlenode minetest.register_on_mapgen_init(function(mgparams) minetest.set_mapgen_params({mgname='singlenode', water_level=-32000}) end) -- new player minetest.register_on_newplayer(function(player) -- spawn player skyblock.spawn_player(player) end) -- respawn player minetest.register_on_respawnplayer(function(player) -- unset old spawn position if skyblock.dig_new_spawn then local player_name = player:get_player_name() local spawn = skyblock.get_spawn(player_name) skyblock.set_spawn(player_name, nil) skyblock.set_spawn(player_name..'_DEAD', spawn) end -- spawn player skyblock.spawn_player(player) return true end) local spawn_throttle = 1 local function spawn_tick() for _,player in ipairs(minetest.get_connected_players()) do local pos = player:get_pos() -- hit the bottom if pos.y < skyblock.world_bottom then local spawn = skyblock.get_spawn(player:get_player_name()) if minetest.get_node(spawn).name == 'skyblock:quest' then player:set_hp(0) else skyblock.spawn_player(player) end end end minetest.after(spawn_throttle, spawn_tick) end -- register globalstep after the server starts minetest.after(0.1, spawn_tick) -- get content ids local id_cloud = minetest.get_content_id('default:cloud') local id_bottom = minetest.get_content_id(skyblock.world_bottom_node) -- register map generation minetest.register_on_generated(function(minp, maxp, seed) -- do not handle mapchunks which are too heigh or too low if( minp.y > 0 or maxp.y < 0) then return end local vm, area, data, emin, emax -- if no voxelmanip data was passed on, read the data here if not(vm) or not(area) or not(data) then vm, emin, emax = minetest.get_mapgen_object('voxelmanip') if not(vm) then return end area = VoxelArea:new{ MinEdge={x=emin.x, y=emin.y, z=emin.z}, MaxEdge={x=emax.x, y=emax.y, z=emax.z}, } data = vm:get_data() end -- add cloud floor local cloud_y = skyblock.world_bottom-2 if minp.y<=cloud_y and maxp.y>=cloud_y then for x=minp.x,maxp.x do for z=minp.z,maxp.z do data[area:index(x,cloud_y,z)] = id_cloud end end end -- add world_bottom_node if skyblock.world_bottom_node ~= 'air' then local y_start = math.max(cloud_y+1,minp.y) local y_end = math.min(skyblock.start_height,maxp.y) for x=minp.x,maxp.x do for z=minp.z,maxp.z do for y=y_start, y_end do data[area:index(x,y,z)] = id_bottom end end end end -- add starting blocks --[[ local start_pos_list = skyblock.get_start_positions_in_mapchunk(minp, maxp) for _,pos in ipairs(start_pos_list) do skyblock.make_spawn_blocks_on_generated(pos, data, area) end ]]-- -- store the voxelmanip data vm:set_data(data) -- vm:calc_lighting(emin,emax) vm:write_to_map(data) -- vm:update_liquids() data = nil end) -- no placing low nodes minetest.register_on_placenode(function(pos, newnode, placer, oldnode) if pos.y <= skyblock.world_bottom then minetest.remove_node(pos) return true -- give back item end end) minetest-skyblock-0.3.0/skyblock/register_node.lua000066400000000000000000000010231410574302100223270ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- -- quest minetest.register_node('skyblock:quest', { description = 'Skyblock', tiles = {'skyblock_quest.png'}, is_ground_content = true, paramtype = 'light', sunlight_propagates = true, light_source = 14, can_dig = function(pos, player) return false end, on_construct = function(pos) -- do not remove, needed to init the node end, }) minetest-skyblock-0.3.0/skyblock/schems/000077500000000000000000000000001410574302100202615ustar00rootroot00000000000000minetest-skyblock-0.3.0/skyblock/schems/island.schem000066400000000000000000000252351410574302100225630ustar00rootroot00000000000000return {{["x"] = 0, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 3, ["name"] = "default:dirt"}, {["x"] = 0, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 1, ["name"] = "default:dirt_with_grass"}, {["x"] = 0, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 2, ["name"] = "default:dirt_with_grass"}, {["x"] = 0, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 3, ["name"] = "default:dirt_with_grass"}, {["x"] = 0, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 4, ["name"] = "default:dirt_with_grass"}, {["x"] = 0, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 5, ["name"] = "default:dirt_with_grass"}, {["x"] = 1, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 2, ["z"] = 3, ["name"] = "default:dirt"}, {["x"] = 1, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 1, ["name"] = "default:dirt"}, {["x"] = 1, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 2, ["name"] = "default:dirt"}, {["x"] = 1, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 3, ["name"] = "default:dirt"}, {["x"] = 1, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 4, ["name"] = "default:dirt"}, {["x"] = 1, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 5, ["name"] = "default:dirt"}, {["x"] = 1, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 0, ["name"] = "default:dirt_with_grass"}, {["x"] = 1, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 1, ["name"] = "default:dirt_with_grass"}, {["x"] = 1, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 2, ["name"] = "default:dirt_with_grass"}, {["x"] = 1, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 3, ["name"] = "default:dirt_with_grass"}, {["x"] = 1, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 4, ["name"] = "default:dirt_with_grass"}, {["x"] = 1, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 5, ["name"] = "default:dirt_with_grass"}, {["x"] = 1, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 6, ["name"] = "default:dirt_with_grass"}, {["x"] = 2, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 1, ["z"] = 3, ["name"] = "default:dirt"}, {["x"] = 2, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 2, ["z"] = 2, ["name"] = "default:dirt"}, {["x"] = 2, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 2, ["z"] = 3, ["name"] = "default:dirt"}, {["x"] = 2, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 2, ["z"] = 4, ["name"] = "default:dirt"}, {["x"] = 2, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 1, ["name"] = "default:dirt"}, {["x"] = 2, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 2, ["name"] = "default:dirt"}, {["x"] = 2, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 3, ["name"] = "default:dirt"}, {["x"] = 2, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 4, ["name"] = "default:dirt"}, {["x"] = 2, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 5, ["name"] = "default:dirt"}, {["x"] = 2, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 0, ["name"] = "default:dirt_with_grass"}, {["x"] = 2, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 1, ["name"] = "default:dirt_with_grass"}, {["x"] = 2, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 2, ["name"] = "default:dirt_with_grass"}, {["x"] = 2, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 3, ["name"] = "default:dirt_with_grass"}, {["x"] = 2, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 4, ["name"] = "default:dirt_with_grass"}, {["x"] = 2, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 5, ["name"] = "default:dirt_with_grass"}, {["x"] = 2, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 6, ["name"] = "default:dirt_with_grass"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 0, ["z"] = 3, ["name"] = "default:dirt"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 1, ["z"] = 2, ["name"] = "default:dirt"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 1, ["z"] = 3, ["name"] = "default:dirt"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 1, ["z"] = 4, ["name"] = "default:dirt"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 2, ["z"] = 1, ["name"] = "default:dirt"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 2, ["z"] = 2, ["name"] = "default:dirt"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 2, ["z"] = 3, ["name"] = "default:dirt"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 2, ["z"] = 4, ["name"] = "default:dirt"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 2, ["z"] = 5, ["name"] = "default:dirt"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 0, ["name"] = "default:dirt"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 1, ["name"] = "default:dirt"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 2, ["name"] = "default:dirt"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 3, ["name"] = "default:dirt"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 4, ["name"] = "default:dirt"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 5, ["name"] = "default:dirt"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 6, ["name"] = "default:dirt"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 0, ["name"] = "default:dirt_with_grass"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 1, ["name"] = "default:dirt_with_grass"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 2, ["name"] = "default:dirt_with_grass"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 3, ["name"] = "skyblock:quest"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 4, ["name"] = "default:dirt_with_grass"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 5, ["name"] = "default:dirt_with_grass"}, {["x"] = 3, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 6, ["name"] = "default:dirt_with_grass"}, {["x"] = 4, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 1, ["z"] = 3, ["name"] = "default:dirt"}, {["x"] = 4, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 2, ["z"] = 2, ["name"] = "default:dirt"}, {["x"] = 4, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 2, ["z"] = 3, ["name"] = "default:dirt"}, {["x"] = 4, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 2, ["z"] = 4, ["name"] = "default:dirt"}, {["x"] = 4, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 1, ["name"] = "default:dirt"}, {["x"] = 4, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 2, ["name"] = "default:dirt"}, {["x"] = 4, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 3, ["name"] = "default:dirt"}, {["x"] = 4, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 4, ["name"] = "default:dirt"}, {["x"] = 4, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 5, ["name"] = "default:dirt"}, {["x"] = 4, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 0, ["name"] = "default:dirt_with_grass"}, {["x"] = 4, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 1, ["name"] = "default:dirt_with_grass"}, {["x"] = 4, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 2, ["name"] = "default:dirt_with_grass"}, {["x"] = 4, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 3, ["name"] = "default:dirt_with_grass"}, {["x"] = 4, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 4, ["name"] = "default:dirt_with_grass"}, {["x"] = 4, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 5, ["name"] = "default:dirt_with_grass"}, {["x"] = 4, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 6, ["name"] = "default:dirt_with_grass"}, {["x"] = 5, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 2, ["z"] = 3, ["name"] = "default:dirt"}, {["x"] = 5, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 1, ["name"] = "default:dirt"}, {["x"] = 5, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 2, ["name"] = "default:dirt"}, {["x"] = 5, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 3, ["name"] = "default:dirt"}, {["x"] = 5, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 4, ["name"] = "default:dirt"}, {["x"] = 5, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 5, ["name"] = "default:dirt"}, {["x"] = 5, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 0, ["name"] = "default:dirt_with_grass"}, {["x"] = 5, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 1, ["name"] = "default:dirt_with_grass"}, {["x"] = 5, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 2, ["name"] = "default:dirt_with_grass"}, {["x"] = 5, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 3, ["name"] = "default:dirt_with_grass"}, {["x"] = 5, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 4, ["name"] = "default:dirt_with_grass"}, {["x"] = 5, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 5, ["name"] = "default:dirt_with_grass"}, {["x"] = 5, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 6, ["name"] = "default:dirt_with_grass"}, {["x"] = 6, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 3, ["z"] = 3, ["name"] = "default:dirt"}, {["x"] = 6, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 1, ["name"] = "default:dirt_with_grass"}, {["x"] = 6, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 2, ["name"] = "default:dirt_with_grass"}, {["x"] = 6, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 3, ["name"] = "default:dirt_with_grass"}, {["x"] = 6, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 4, ["name"] = "default:dirt_with_grass"}, {["x"] = 6, ["meta"] = {["fields"] = {}, ["inventory"] = {}}, ["y"] = 4, ["z"] = 5, ["name"] = "default:dirt_with_grass"}}minetest-skyblock-0.3.0/skyblock/skyblock.lua000066400000000000000000000216521410574302100213310ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- -- expose functions to other modules skyblock = {} -- -- CONFIG OPTIONS -- -- Debug mode skyblock.debug = minetest.settings:get_bool('skyblock.debug') -- How far apart to set players start positions skyblock.start_gap = tonumber(minetest.settings:get('skyblock.start_gap')) or 32 -- The Y position the spawn nodes will appear skyblock.start_height = tonumber(minetest.settings:get('skyblock.start_height')) or 4 -- How many players will be in 1 row -- skyblock.world_width * skyblock.world_width = total players skyblock.world_width = tonumber(minetest.settings:get('skyblock.world_width')) or 1000 -- How far down (in nodes) before a player dies and is respawned skyblock.world_bottom = tonumber(minetest.settings:get('skyblock.world_bottom')) or -8 -- Difference (in nodes) between islands starting heights skyblock.height_difference = tonumber(minetest.settings:get('skyblock.height_difference')) or 8 -- Node to use for the world bottom skyblock.world_bottom_node = minetest.settings:get('skyblock.world_bottom') or 'air' -- 'air' || 'default:water_source' || 'default:lava_source' -- Should digging the spawn result in a new spawn pos? skyblock.dig_new_spawn = minetest.settings:get_bool('skyblock.dig_new_spawn') -- Should player lose bags on death? skyblock.lose_bags_on_death = minetest.settings:get_bool('skyblock.lose_bags_on_death') -- Which schem file to use skyblock.schem = minetest.settings:get('skyblock.schem') or 'island.schem' -- Schem offset X skyblock.schem_offset_x = tonumber(minetest.settings:get('skyblock.schem_offset_x')) or -3 -- Schem offset Y skyblock.schem_offset_y = tonumber(minetest.settings:get('skyblock.schem_offset_y')) or -4 -- Schem offset Z skyblock.schem_offset_z = tonumber(minetest.settings:get('skyblock.schem_offset_z')) or -3 -- local variables local filename = minetest.get_worldpath()..'/skyblock' local last_start_id = 0 local start_positions = {} local spawnpos = {} -- -- PUBLIC FUNCTIONS -- -- log function skyblock.log(message) if not skyblock.debug then return end minetest.log('action', '[skyblock] '..message) end -- dump_pos function skyblock.dump_pos(pos) if pos==nil then return 'nil' end return '{x='..pos.x..',y='..pos.x..',z='..pos.z..'}' end -- get players spawn position function skyblock.get_spawn(player_name) local spawn = spawnpos[player_name] if spawn then skyblock.log('get_spawn() for '..player_name..' is '..skyblock.dump_pos(spawn)) return spawn end skyblock.log('get_spawn() for '..player_name..' is unknown') end -- get player_name at spawn position function skyblock.get_spawn_player(pos) for player_name,spawn in pairs(spawnpos) do if spawn.x == pos.x and spawn.y == pos.y and spawn.z == pos.z then return player_name end end return nil end -- set players spawn position function skyblock.set_spawn(player_name, pos) skyblock.log('set_spawn() for '..player_name..' at '..skyblock.dump_pos(pos)) spawnpos[player_name] = pos -- save the spawn data from the table to the file local output = io.open(filename..'.spawn', 'w') for i, v in pairs(spawnpos) do if v ~= nil then output:write(v.x..' '..v.y..' '..v.z..' '..i..'\n') end end io.close(output) end -- get next spawn position function skyblock.get_next_spawn() skyblock.log('get_next_spawn()') last_start_id = last_start_id+1 local output = io.open(filename..'.last_start_id', 'w') output:write(last_start_id) io.close(output) local spawn = start_positions[last_start_id] if spawn == nil then print('MAJOR ERROR - no spawn position at id='..last_start_id) end return spawn end -- handle player spawn setup function skyblock.spawn_player(player) local player_name = player:get_player_name() skyblock.log('skyblock.spawn_player() '..player_name) -- find the player spawn point local spawn = skyblock.get_spawn(player_name) if spawn == nil then spawn = skyblock.get_next_spawn() skyblock.set_spawn(player_name,spawn) end -- add the start block and teleport the player skyblock.make_spawn_blocks(spawn,player_name) player:set_pos({x=spawn.x,y=spawn.y+6,z=spawn.z}) player:set_hp(20) end -- load schem local schempath = minetest.get_modpath(minetest.get_current_modname())..'/schems' function skyblock.load_schem(origin, filename) local file,_ = io.open(schempath..'/'..filename, 'rb') local value = file:read('*a') file:close() local nodes = minetest.deserialize(value) if not nodes then return nil end for _,entry in ipairs(nodes) do local pos = { x=entry.x + origin.x + skyblock.schem_offset_x, y=entry.y + origin.y + skyblock.schem_offset_y, z=entry.z + origin.z + skyblock.schem_offset_z, } if minetest.get_node(pos).name == 'air' then minetest.add_node(pos, {name=entry.name}) end end end -- make spawn blocks function skyblock.make_spawn_blocks(pos, player_name) skyblock.log('skyblock.make_spawn_blocks('..skyblock.dump_pos(pos)..', '..player_name..') ') skyblock.load_schem(pos, skyblock.schem) --minetest.add_node(pos, {name='skyblock:quest'}) end -- make spawn blocks on generated --[[ function skyblock.make_spawn_blocks_on_generated(pos, data, area) local id_dirt = minetest.get_content_id('default:dirt') for x=-1,1 do for z=-1,1 do data[area:index(pos.x+x,pos.y,pos.z+z)] = id_dirt data[area:index(pos.x+x,pos.y-1,pos.z+z)] = id_dirt data[area:index(pos.x+x,pos.y-2,pos.z+z)] = id_dirt end end data[area:index(pos.x,pos.y,pos.z)] = minetest.get_content_id('skyblock:quest') --minetest.registered_nodes['skyblock:quest'].on_construct(pos) end ]]-- -- get start positions in mapchunk --[[ skyblock.get_start_positions_in_mapchunk = function(minp, maxp) local list = {}; for i,v in ipairs(start_positions) do if v.x>=minp.x and v.x<=maxp.x and v.y>=minp.y and v.y<=maxp.y and v.z>=minp.z and v.z<=maxp.z then list[#list+1] = {x=v.x, y=v.y, z=v.z} end end return list end ]]-- -- -- LOCAL FUNCTIONS -- -- spiral matrix - used to generate starting positions -- http://rosettacode.org/wiki/Spiral_matrix#Lua av, sn = math.abs, function(s) return s~=0 and s/av(s) or 0 end local function sindex(y, x) -- returns the value at (x, y) in a spiral that starts at 1 and goes outwards if y == -x and y >= x then return (2*y+1)^2 end local l = math.max(av(y), av(x)) return (2*l-1)^2+4*l+2*l*sn(x+y)+sn(y^2-x^2)*(l-(av(y)==l and sn(y)*x or sn(x)*y)) -- OH GOD WHAT end local function spiralt(side) local ret,_ , start, stop = {}, 0, math.floor((-side+1)/2), math.floor((side-1)/2) for i = 1, side do for j = 1, side do local id = side^2 - sindex(stop - i + 1,start + j - 1) ret[id] = {x=i,z=j} end end return ret end -- reverse ipairs local function ripairs(t) local function ripairs_it(t,i) i=i-1 local v=t[i] if v==nil then return v end return i,v end return ripairs_it, t, #t+1 end -- -- INIT FUNCTIONS -- -- load the spawn data from disk local function load_spawn() local input = io.open(filename..'.spawn', 'r') if input then while true do local x = input:read('*n') if x == nil then break end local y = input:read('*n') local z = input:read('*n') local name = input:read('*l') spawnpos[name:sub(2)] = {x = x, y = y, z = z} end io.close(input) else spawnpos = {} end end load_spawn() -- run it now -- load the start positions from disk local function load_start_positions() local input = io.open(filename..'.start_positions', 'r') -- create start_positions file if needed if not input then skyblock.log('generate start positions') local output = io.open(filename..'.start_positions', 'w') local pos for i,v in ripairs(spiralt(skyblock.world_width)) do -- get positions using spiral pos = {x=v.x*skyblock.start_gap, y=math.random(skyblock.start_height-skyblock.height_difference, skyblock.start_height+skyblock.height_difference), z=v.z*skyblock.start_gap} output:write(pos.x..' '..pos.y..' '..pos.z..'\n') end io.close(output) input = io.open(filename..'.start_positions', 'r') end -- read start positions skyblock.log('read start positions') while true do local x = input:read('*n') if x == nil then break end local y = input:read('*n') local z = input:read('*n') table.insert(start_positions,{x = x, y = y, z = z}) end io.close(input) end load_start_positions() -- run it now -- load the last start position from disk local function load_last_start_id() local input = io.open(filename..'.last_start_id', 'r') -- create last_start_id file if needed if not input then local output = io.open(filename..'.last_start_id', 'w') output:write(last_start_id) io.close(output) input = io.open(filename..'.last_start_id', 'r') end -- read last start id last_start_id = input:read('*n') if last_start_id == nil then last_start_id = 0 end io.close(input) end load_last_start_id() -- run it now minetest-skyblock-0.3.0/skyblock/textures/000077500000000000000000000000001410574302100206625ustar00rootroot00000000000000minetest-skyblock-0.3.0/skyblock/textures/README.interface.txt000066400000000000000000000000671410574302100243220ustar00rootroot00000000000000http://opengameart.org/content/lpc-pennomis-ui-elementsminetest-skyblock-0.3.0/skyblock/textures/README.md000066400000000000000000000007501410574302100221430ustar00rootroot00000000000000# Texture Information and Credits * The `skyblock_*.png` were taken from [Minetest Alphabet Mod](http://minetest.net/forum/viewtopic.php?id=2312). * The `checkbox_*.png` was taken from [LPC Pennomi's UI Elements](https://opengameart.org/content/lpc-pennomis-ui-elements) * The interfaces `craft.png`, `goals.png`, `inventory.png`, `rewards.png` were created by cornernote, based on colors from from [LPC Pennomi's UI Elements](https://opengameart.org/content/lpc-pennomis-ui-elements). minetest-skyblock-0.3.0/skyblock/textures/checkbox_checked.png000066400000000000000000000021221410574302100246210ustar00rootroot00000000000000PNG  IHDR DtEXtSoftwareAdobe ImageReadyqe<"iTXtXML:com.adobe.xmp PLTEvXkMJ]\JAtRNSKFIDATx0EQ?Y JZݶL&*@UP&'o))%jK}3`v\ 7nQs^{Kp0]'IENDB`minetest-skyblock-0.3.0/skyblock/textures/checkbox_unchecked.png000066400000000000000000000020411410574302100251640ustar00rootroot00000000000000PNG  IHDR DtEXtSoftwareAdobe ImageReadyqe<"iTXtXML:com.adobe.xmp 3GPLTEvXkMJ]x8tRNSKFaIDATxA DqG(&m!)`_< e k}"1s^ lE֧JW]D}CygIENDB`minetest-skyblock-0.3.0/skyblock/textures/craft.png000066400000000000000000000021451410574302100224710ustar00rootroot00000000000000PNG  IHDRy>tEXtSoftwareAdobe ImageReadyqe<"iTXtXML:com.adobe.xmp 3fEPLTEMJ]vXk%'+9xtRNSރYIDATx0Aſ'.hgO*UEneEyF+39]eLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLL2_C++]* kt vo5*W`{IENDB`minetest-skyblock-0.3.0/skyblock/textures/goals.png000066400000000000000000000024201410574302100224730ustar00rootroot00000000000000PNG  IHDRIԢtEXtSoftwareAdobe ImageReadyqe<"iTXtXML:com.adobe.xmp H~PLTEXkMJ]v%'+AV;tRNSރYLIDATx000n_W'mБj5O><"8ؾxmoIbq*+Vru:z_vhQIENDB`minetest-skyblock-0.3.0/skyblock/textures/inventory.png000066400000000000000000000023411410574302100234250ustar00rootroot00000000000000PNG  IHDRd,tEXtSoftwareAdobe ImageReadyqe<"iTXtXML:com.adobe.xmp '$TPLTEMJ]vXk%'+9xtRNSރYIDATx DAAng&6J؟E}^9>X!)E#_00`7 dhnan޿;y1\75u0` 0` 0` 0` 0` 0` 0` 0` 0` 0` 0` 0` 0` 0` 0` 0` 0`?e.+mܺ QaD 0EEfIENDB`minetest-skyblock-0.3.0/skyblock/textures/rewards.png000066400000000000000000000020511410574302100230350ustar00rootroot00000000000000PNG  IHDRFZ2VtEXtSoftwareAdobe ImageReadyqe<"iTXtXML:com.adobe.xmp [qPLTEvMJ]Xk%'+YYdtRNSރYeIDATxA0 @gIfb g;Uvytmu0e\PQ:@ S[vٟq0"IENDB`minetest-skyblock-0.3.0/skyblock/textures/skyblock_1.png000066400000000000000000000003451410574302100234330ustar00rootroot00000000000000PNG  IHDR sRGB pHYs  tIME 3(ItEXtCommentCreated with GIMPWRIDATH C]l.$DmG=i03Fa22MIB4o  OՓ\nGtJ=R23IENDB`minetest-skyblock-0.3.0/skyblock/textures/skyblock_2.png000066400000000000000000000004641410574302100234360ustar00rootroot00000000000000PNG  IHDR sRGB pHYs  tIME 3$ItEXtCommentCreated with GIMPWIDATH Ee{lS"Z<69G( /3i֓.UjPd- F]Y-ծis֡:s$_\Aꠕ4Eis .mLp +] t"-A }){` N @W4(d`IENDB`minetest-skyblock-0.3.0/skyblock/textures/skyblock_3.png000066400000000000000000000005261410574302100234360ustar00rootroot00000000000000PNG  IHDR szzsRGBbKGD pHYs  tIME 4 h7tEXtCommentCreated with GIMPWIDATXW d!xTSrFX`94utҨ@sİ!3U]/ZM(9]BQ=,N<3ȟEDDɘJyn:.AhYX`(*Zkd2(J=Fѧ_Ǚҙl}SJ+IENDB`minetest-skyblock-0.3.0/skyblock/textures/skyblock_4.png000066400000000000000000000004671410574302100234430ustar00rootroot00000000000000PNG  IHDR szzsRGBbKGD pHYs  tIME 4S zMtEXtCommentCreated with GIMPWIDATXA0 7Vp]`c!GtܔDfϸk| gqw.t2\,(\l-sq [*%v.o/G *&=">; sI4G8: IENDB`minetest-skyblock-0.3.0/skyblock/textures/skyblock_5.png000066400000000000000000000005001410574302100234300ustar00rootroot00000000000000PNG  IHDR szzsRGBbKGD pHYs  tIME 65tEXtCommentCreated with GIMPWIDATXW[ f21F2~ PUi]dop-t 0W*7E%L ,=RCjo{\@\UdU(zz3j1<`e4B3fIENDB`minetest-skyblock-0.3.0/skyblock/textures/skyblock_6.png000066400000000000000000000005451410574302100234420ustar00rootroot00000000000000PNG  IHDR szzsRGBbKGD pHYs  tIME 6/NSdHtEXtCommentCreated with GIMPWIDATXWI 0ٞ %]C[c] ":Di$"9~g%QpͿ\#2:=D ̿Yw0j~oZUB-r Q OUB[@D(Q^DK!@pnؕ::v^`f+xF9\n0x(_N-NLX'kCIENDB`minetest-skyblock-0.3.0/skyblock/textures/skyblock_7.png000066400000000000000000000004601410574302100234370ustar00rootroot00000000000000PNG  IHDR szzsRGBbKGD pHYs  tIME 6:#tEXtCommentCreated with GIMPWIDATXݗQ CWfs4k#`Chj<to bܣGE kBe>d 0Z66!kb] +C 05LƟ&X+H:ë ܫ.0P+ Yc/gpKkqˈfb9xAs5&x@sKȘs"C 1ɈSD}Ema@g?PR@Q`z;`IENDB`minetest-skyblock-0.3.0/skyblock/textures/skyblock_9.png000066400000000000000000000005471410574302100234470ustar00rootroot00000000000000PNG  IHDR szzsRGBbKGD pHYs  tIME 7*'"tEXtCommentCreated with GIMPWIDATXW [ }m-$*Tq =SH :Wl p`Y f`mL)+Wu@f`IN98-U&39MhR#"uX+@e8EU{0;sglvjIENDB`minetest-skyblock-0.3.0/skyblock/textures/skyblock_quest.png000066400000000000000000000004631410574302100244350ustar00rootroot00000000000000PNG  IHDR szzsRGBbKGD pHYs  tIME 97ڧtEXtCommentCreated with GIMPWIDATXK DLW46lc qg_.|JDDlUtt.,<|FDJ4SZ(ȴlim~xFԿR| !N-ԝߣ~ `;[S@KA8j\tC7wvIENDB`minetest-skyblock-0.3.0/skyblock_levels/000077500000000000000000000000001410574302100203515ustar00rootroot00000000000000minetest-skyblock-0.3.0/skyblock_levels/init.lua000066400000000000000000000016271410574302100220250ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- local modpath = minetest.get_modpath('skyblock_levels') dofile(modpath..'/skyblock.craft_guide.lua') dofile(modpath..'/skyblock.feats.lua') dofile(modpath..'/skyblock.levels.lua') dofile(modpath..'/skyblock.levels.1.lua') dofile(modpath..'/skyblock.levels.2.lua') dofile(modpath..'/skyblock.levels.3.lua') dofile(modpath..'/skyblock.levels.4.lua') dofile(modpath..'/skyblock.levels.5.lua') dofile(modpath..'/register_abm.lua') dofile(modpath..'/register_craft.lua') dofile(modpath..'/register_command.lua') dofile(modpath..'/register_node.lua') dofile(modpath..'/register_misc.lua') -- log that we started skyblock.log('[MOD]'..minetest.get_current_modname()..' -- loaded from '..minetest.get_modpath(minetest.get_current_modname()))minetest-skyblock-0.3.0/skyblock_levels/mod.conf000066400000000000000000000002311410574302100217730ustar00rootroot00000000000000name = skyblock_levels depends = default, skyblock, bucket, doors, flowers, stairs, wool, xpanes, protector, farming optional_depends = unified_inventoryminetest-skyblock-0.3.0/skyblock_levels/register_abm.lua000066400000000000000000000024241410574302100235210ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- -- flora spawns on dirt_with_grass minetest.register_abm({ nodenames = {'default:dirt_with_grass'}, interval = 300, chance = 100, action = function(pos, node) pos.y = pos.y+1 local light = minetest.get_node_light(pos) if not light or light < 13 then return end -- check for nearby if minetest.find_node_near(pos, 2, {'group:flora'}) ~= nil then return end if minetest.get_node(pos).name == 'air' then local rand = math.random(1,8); if rand==1 then node = 'default:junglegrass' elseif rand==2 then node = 'default:grass_1' elseif rand==3 then node = 'flowers:dandelion_white' elseif rand==4 then node = 'flowers:dandelion_yellow' elseif rand==5 then node = 'flowers:geranium' elseif rand==6 then node = 'flowers:rose' elseif rand==7 then node = 'flowers:tulip' elseif rand==8 then node = 'flowers:viola' end minetest.set_node(pos, {name=node}) end end }) -- remove bones minetest.register_abm({ nodenames = {'bones:bones'}, interval = 1, chance = 1, action = function(pos, node) minetest.remove_node(pos) end, }) minetest-skyblock-0.3.0/skyblock_levels/register_command.lua000066400000000000000000000032451410574302100244020ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- -- register register_privilege minetest.register_privilege('level', 'Can use /setlevel') -- getlevel minetest.register_chatcommand('getlevel', { description = 'Get a player\'s current level.', params = "", func = function(name, param) local player_name = param if player_name == "" then player_name = name end minetest.chat_send_player(name, player_name..' is on level '..skyblock.feats.get_level(player_name)) return end, }) -- setlevel minetest.register_chatcommand('setlevel', { description = 'Set a player\'s current level', privs = {level = true}, params = " ", func = function(name, param) local found, _, player_name, level = param:find("^([^%s]+)%s+(.+)$") if found and player_name and level then level = tonumber(level) if skyblock.feats.set_level(player_name, level) then minetest.chat_send_player(name, player_name..' has been set to level '..level) else minetest.chat_send_player(name, 'cannot change '..player_name..' to level '..level) end else return false, "Invalid use." end end, }) -- who minetest.register_chatcommand('who', { description = 'Display list of online players and their current level.', func = function(name) minetest.chat_send_player(name, 'Current Players:') for _,player in ipairs(minetest.get_connected_players()) do local player_name = player:get_player_name() minetest.chat_send_player(name, ' - '..player_name..' - level '..skyblock.feats.get_level(player_name)) end end, }) minetest-skyblock-0.3.0/skyblock_levels/register_craft.lua000066400000000000000000000076321410574302100240670ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- -- desert_stone minetest.register_craft({ output = 'default:desert_stone', recipe = { {'default:desert_sand', 'default:desert_sand'}, {'default:desert_sand', 'default:desert_sand'}, } }) -- mossycobble minetest.register_craft({ output = 'default:mossycobble', recipe = { {'group:flora'}, {'default:cobble'}, } }) -- stone_with_coal minetest.register_craft({ output = 'default:stone_with_coal 2', recipe = { {'default:coal_lump'}, {'default:stone'}, } }) -- stone_with_iron minetest.register_craft({ output = 'default:stone_with_iron 2', recipe = { {'default:iron_lump'}, {'default:stone'}, } }) -- stone_with_copper minetest.register_craft({ output = 'default:stone_with_copper 2', recipe = { {'default:copper_lump'}, {'default:stone'}, } }) -- stone_with_gold minetest.register_craft({ output = 'default:stone_with_gold 2', recipe = { {'default:gold_lump'}, {'default:stone'}, } }) -- stone_with_mese minetest.register_craft({ output = 'default:stone_with_mese 2', recipe = { {'default:mese_crystal'}, {'default:stone'}, } }) -- stone_with_diamond minetest.register_craft({ output = 'default:stone_with_diamond 2', recipe = { {'default:diamond'}, {'default:stone'}, } }) -- obsidian minetest.register_craft({ output = 'default:obsidian 2', recipe = { {'default:obsidian_shard'}, {'default:stone'}, } }) -- sand minetest.register_craft({ output = 'default:sand 4', recipe = { {'default:obsidian_shard'}, } }) -- cobble minetest.register_craft({ type = 'cooking', output = 'default:cobble 2', recipe = 'default:dirt', }) -- gravel minetest.register_craft({ output = 'default:gravel 2', recipe = { {'default:cobble'}, } }) -- dirt minetest.register_craft({ output = 'default:dirt 2', recipe = { {'default:gravel'}, } }) -- clay_lump minetest.register_craft({ output = 'default:clay_lump 4', recipe = { {'default:dirt'}, } }) -- locked_chest from chest minetest.register_craft({ output = 'default:chest_locked', recipe = { {'default:steel_ingot'}, {'default:chest'}, } }) -- sapling from leaves and sticks minetest.register_craft({ output = 'default:sapling', recipe = { {'default:leaves', 'default:leaves', 'default:leaves'}, {'default:leaves', 'default:leaves', 'default:leaves'}, {'', 'default:stick', ''}, } }) -- junglesapling from jungleleaves and sticks minetest.register_craft({ output = 'default:junglesapling', recipe = { {'default:jungleleaves', 'default:jungleleaves', 'default:jungleleaves'}, {'default:jungleleaves', 'default:jungleleaves', 'default:jungleleaves'}, {'', 'default:stick', ''}, } }) -- pine_sapling from pine_needles and sticks minetest.register_craft({ output = 'default:pine_sapling', recipe = { {'default:pine_needles', 'default:pine_needles', 'default:pine_needles'}, {'default:pine_needles', 'default:pine_needles', 'default:pine_needles'}, {'', 'default:stick', ''}, } }) -- desert_cobble from dirt and gravel minetest.register_craft({ output = 'default:desert_cobble 2', recipe = { {'default:dirt'}, {'default:gravel'}, } }) -- desert_sand from desert_stone minetest.register_craft({ output = 'default:desert_sand 4', recipe = { {'default:desert_stone'}, } }) -- snowblock from bucket_water minetest.register_craft({ output = 'default:ice', recipe = { {'bucket:bucket_water'}, } }) -- ice from snowblock minetest.register_craft({ output = 'default:ice', recipe = { {'default:snowblock', 'default:snowblock'}, {'default:snowblock', 'default:snowblock'}, } }) -- snowblock from ice minetest.register_craft({ output = 'default:snowblock 4', recipe = { {'default:ice'}, } }) -- glass from desert_sand minetest.register_craft({ type = 'cooking', output = 'default:glass', recipe = 'default:desert_sand', }) minetest-skyblock-0.3.0/skyblock_levels/register_misc.lua000066400000000000000000000030131410574302100237100ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- -- new player minetest.register_on_newplayer(function(player) local player_name = player:get_player_name() -- add rewards to player inventory player:get_inventory():set_size('rewards', 4) -- update feats skyblock.feats.update(player_name) -- init level1 skyblock.levels[1].init(player_name) end) -- join player minetest.register_on_joinplayer(function(player) -- set inventory formspec player:set_inventory_formspec(skyblock.levels.get_formspec(player:get_player_name())) end) -- die player minetest.register_on_dieplayer(function(player) local player_name = player:get_player_name() -- empty inventory skyblock.levels.empty_inventory(player) -- back to beginning if skyblock.levels.restart_on_die then skyblock.feats.reset(player_name) else skyblock.feats.reset_level(player_name) end -- back to start of this level end) -- player receive fields minetest.register_on_player_receive_fields(function(player, formname, fields) -- restart if formname=='skyblock_restart' and fields.restart then player:set_hp(0) end end) -- unified inventory skyblock button if minetest.get_modpath('unified_inventory') then unified_inventory.register_button('skyblock', { type = 'image', image = 'ui_skyblock_icon.png', tooltip = 'Skyblock Quests', action = function(player) skyblock.feats.update(player:get_player_name()) end, }) end minetest-skyblock-0.3.0/skyblock_levels/register_node.lua000066400000000000000000000042771410574302100237170ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- -- quest node minetest.override_item('skyblock:quest', { groups = {crumbly=2,cracky=2}, on_construct = function(pos) local player_name = skyblock.get_spawn_player(pos) if player_name then skyblock.feats.update(player_name) end end, on_punch = function(pos, node, puncher) local player_name = skyblock.get_spawn_player(pos) if player_name then skyblock.feats.update(player_name) end end, can_dig = function(pos, player) return true end, on_dig = function(pos, node, digger) skyblock.show_restart_formspec(digger:get_player_name()) end, on_receive_fields = function(pos, formname, fields, sender) if fields.restart then skyblock.show_restart_formspec(sender:get_player_name()) return end for k,v in pairs(fields) do if string.match(k, 'skyblock_craft_guide_') then minetest.show_formspec(sender:get_player_name(),'skyblock_craft_guide',skyblock.craft_guide.get_formspec(k, fields)) return end end end, }) -- trees local trees = {'default:tree','default:jungletree','default:pinetree'} for k,node in ipairs(trees) do local groups = minetest.registered_nodes[node].groups groups.oddly_breakable_by_hand = 0 minetest.override_item(node, {groups = groups}) end -- leaves local leaves = {'default:leaves','default:jungleleaves','default:pine_needles'} for k,node in ipairs(leaves) do minetest.override_item(node, {climbable = true, walkable = false}) end -- instant grow sapling if there is room minetest.override_item('default:sapling', { after_place_node = function(pos) -- check if node under belongs to the soil group pos.y = pos.y - 1 local node_under = minetest.get_node(pos) pos.y = pos.y + 1 if minetest.get_item_group(node_under.name, "soil") == 0 then return end -- check if we have space to make a tree for dy=1,4 do pos.y = pos.y+dy if minetest.get_node(pos).name ~= 'air' and minetest.get_node(pos).name ~= 'default:leaves' then return end pos.y = pos.y-dy end -- add the tree default.grow_tree(pos, math.random(1, 4) == 1) end, }) minetest-skyblock-0.3.0/skyblock_levels/skyblock.craft_guide.lua000066400000000000000000000130651410574302100251550ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- skyblock.craft_guide = {} -- some common groups local group_placeholder = {} group_placeholder['group:wood'] = 'default:wood' group_placeholder['group:tree'] = 'default:tree' group_placeholder['group:flora'] = 'flowers:tulip' group_placeholder['group:stick'] = 'default:stick' group_placeholder['group:stone'] = 'default:cobble' -- 'default:stone' point people to the cheaper cobble group_placeholder['group:sand'] = 'default:sand' group_placeholder['group:leaves'] = 'default:leaves' group_placeholder['group:wood_slab'] = 'stairs:slab_wood' group_placeholder['group:wool'] = 'wool:white' -- handle the standard dye color groups minetest.after(0.5, function() for index, entry in pairs(minetest.registered_items) do if index:find("dye:") then for k,v in pairs(entry.groups) do if( k ~= 'dye' ) then group_placeholder['group:dye,'..k ] = index end end end end end) -- render an image button for a formspec skyblock.craft_guide.image_button_link = function(stack_string) local group = '' if group_placeholder[stack_string] then stack_string = group_placeholder[stack_string] group = 'G' end local stack = ItemStack(stack_string) local new_node_name = stack_string if( stack and stack:get_name()) then new_node_name = stack:get_name() end return tostring(stack_string)..';skyblock_craft_guide_'..tostring(new_node_name)..';'..group end -- get_formspec skyblock.craft_guide.get_formspec = function(node_name, fields) node_name = node_name:gsub('skyblock_craft_guide_', '') local receipe_nr = 1 if fields.node_name then node_name = fields.node_name receipe_nr = tonumber(fields.receipe_nr) end -- the player may ask for recipe for ingredients to the current receipe if fields then for k,v in pairs(fields) do k = k:gsub('skyblock_craft_guide_', '') if (v and (minetest.registered_items[k] or minetest.registered_nodes[k] or minetest.registered_craftitems[k] or minetest.registered_tools[k] )) then node_name = k receipe_nr = 1 end end end local res = minetest.get_all_craft_recipes(node_name) or {} -- offer all alternate crafting receipes through prev/next buttons if fields and fields.skyblock_craft_guide_prev_receipe and receipe_nr > 1 then receipe_nr = receipe_nr - 1 elseif fields and fields.skyblock_craft_guide_next_receipe and receipe_nr < #res then receipe_nr = receipe_nr + 1 end local formspec = 'size[5,6]' ..'label[4,2;Output]' ..'background[-0.1,0.9;5.2,3.8;craft.png]' ..'button_exit[3,0;2,0.5;close;Close]' --..'button[0,0;2,0.5;main;Back]' ..'field[20,20;0.1,0.1;node_name;node_name;'..node_name..']' -- invisible field for passing on information ..'field[21,21;0.1,0.1;receipe_nr;receipe_nr;'..tostring(receipe_nr)..']' -- another invisible field ..'item_image_button[4,2.5;1.0,1.0;'..tostring(node_name)..';normal;]' if not res or receipe_nr > #res or receipe_nr < 1 then receipe_nr = 1 end if res and receipe_nr > 1 then formspec = formspec..'button[3.0,5.5;1,0.5;skyblock_craft_guide_prev_receipe;prev]' end if( res and receipe_nr < #res ) then formspec = formspec..'button[4.0,5.5;1,0.5;skyblock_craft_guide_next_receipe;next]' end if( not( res ) or #res<1) then formspec = formspec..'label[3,1.5;No receipes.]' if(minetest.registered_nodes[ node_name ] and minetest.registered_nodes[ node_name ].drop ) then local drop = minetest.registered_nodes[ node_name ].drop if( drop and type( drop )=='string' and drop ~= node_name ) then formspec = formspec ..'label[1,1.6;Drops on dig:]' ..'item_image_button[1,2.5;1.0,1.0;'..skyblock.craft_guide.image_button_link( drop )..']' end end else formspec = formspec..'label[1,5.5;Alternate '..tostring( receipe_nr )..'/'..tostring( #res )..']' -- reverse order; default receipes (and thus the most interesting ones) are usually the oldest local receipe = res[ #res+1-receipe_nr ] if (receipe.type=='normal' and receipe.items) then for i=1,9 do if (receipe.items[i]) then formspec = formspec ..'item_image_button['..((i-1)%receipe.width)..','..(math.floor((i-1)/receipe.width)+1.5)..';1.0,1.0;' ..skyblock.craft_guide.image_button_link( receipe.items[i] )..']' end end elseif (receipe.type=='cooking' and receipe.items and #receipe.items==1) then formspec = formspec ..'item_image_button[1,3;1,1;'..skyblock.craft_guide.image_button_link('default:furnace')..']' --default_furnace_front.png]' ..'item_image_button[1,2;1,1;'..skyblock.craft_guide.image_button_link( receipe.items[1] )..']' else formspec = formspec..'label[0,1.5;Error: Unkown receipe.]' end -- show how many of the items the receipe will yield local outstack = ItemStack(receipe.output) if outstack and outstack:get_count() and outstack:get_count()>1 then formspec = formspec..'label[4.5,3;'..tostring(outstack:get_count())..']' end if receipe.type=='normal' then receipe.type = 'craft' elseif receipe.type=='cooking' then receipe.type = 'furnace' end formspec = formspec..'label[0,1; '..receipe.type..' recipe for '..tostring(node_name)..']' end return formspec end -- register_on_player_receive_fields minetest.register_on_player_receive_fields(function(player, formname, fields) for k,v in pairs(fields) do if string.match(k, 'skyblock_craft_guide_') then minetest.show_formspec(player:get_player_name(),'skyblock_craft_guide',skyblock.craft_guide.get_formspec(k, fields)) return end end end) minetest-skyblock-0.3.0/skyblock_levels/skyblock.feats.lua000066400000000000000000000361361410574302100240070ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- -- expose api skyblock.feats = {} -- file to save players feat local filepath = minetest.get_worldpath()..'/feats' -- local variable to save players feats local players_feat = {} -- get players current level function skyblock.feats.get_level(player_name) return skyblock.feats.get(0, player_name, 'level') end -- set players current level function skyblock.feats.set_level(player_name, level) if skyblock.levels[level] then skyblock.feats.set(0, player_name, 'level', level) players_feat[player_name][level] = {} skyblock.levels[level].init(player_name) skyblock.feats.update(player_name) return true end end -- reset feats function skyblock.feats.reset(player_name) skyblock.log('skyblock.feats.reset('..player_name..')') players_feat[player_name] = {} skyblock.feats.save(players_feat[player_name], player_name) skyblock.feats.update(player_name) skyblock.levels[1].init(player_name) end -- reset level function skyblock.feats.reset_level(player_name) skyblock.log('skyblock.feats.reset_level('..player_name..')') local level = skyblock.feats.get_level(player_name) players_feat[player_name][level] = {} skyblock.feats.save(players_feat[player_name], player_name) skyblock.feats.update(player_name) skyblock.levels[level].init(player_name) end -- update feats function skyblock.feats.update(player_name) skyblock.log('skyblock.feats.update('..player_name..')') local level = skyblock.feats.get_level(player_name) local pos = skyblock.get_spawn(player_name) if not pos or not skyblock.levels[level] then return end local info = skyblock.levels[level].get_info(player_name) -- next level if info.count==info.total then --minetest.chat_send_player(player_name, 'You completed level '..level) minetest.chat_send_all(player_name..' completed level '..level) for _, ref in pairs(minetest.get_connected_players()) do if not (ref:get_player_name() == player_name) then minetest.sound_play("skyblock_finish_other", { to_player = ref:get_player_name(), gain = 1.0, }) else minetest.sound_play("skyblock_finish_level_player", { to_player = player_name, gain = 1.0, }) end end minetest.log('action', player_name..' completed level '..level) skyblock.feats.add(0,info.player_name,'level') skyblock.levels[level+1].init(info.player_name) info = skyblock.levels[level+1].get_info(info.player_name) end -- update formspecs local player = minetest.get_player_by_name(player_name) if player then player:set_inventory_formspec(info.formspec) end local meta = minetest.env:get_meta(pos) meta:set_string('formspec', info.formspec_quest) meta:set_string('infotext', info.infotext) end -- get feat function skyblock.feats.get(level,player_name,feat) --skyblock.log('skyblock.feats.get('..level..','..player_name..','..feat..')') if players_feat[player_name] == nil then players_feat[player_name] = skyblock.feats.load(player_name) or {} end if players_feat[player_name][level] == nil then players_feat[player_name][level] = {} end if players_feat[player_name][level][feat] == nil then players_feat[player_name][level][feat] = 0 if feat=='level' then players_feat[player_name][level][feat] = 1 end end return players_feat[player_name][level][feat] end -- add feat function skyblock.feats.add(level,player_name,feat) skyblock.log('skyblock.feats.add('..level..','..player_name..','..feat..')') local player_feat = skyblock.feats.get(level,player_name,feat) players_feat[player_name][level][feat] = player_feat + 1 if level~=0 or feat~='level' then local rewarded = skyblock.levels[level].reward_feat(player_name,feat) if rewarded then minetest.chat_send_all(player_name..' completed the quest "'..feat..'" on level '..level) minetest.sound_play("skyblock_finish_quest", { to_player = player_name, gain = 1.0, }) minetest.log('action', player_name..' completed the quest "'..feat..'" on level '..level) end end skyblock.feats.save(players_feat[player_name], player_name) skyblock.feats.update(player_name) end -- set feat function skyblock.feats.set(level,player_name,feat,value) skyblock.log('skyblock.feats.set('..level..','..player_name..','..feat..')') if not players_feat[player_name] then players_feat[player_name] = skyblock.feats.load(player_name) or {[0] = {}} end players_feat[player_name][level][feat] = value if level~=0 or feat~='level' then local rewarded = skyblock.levels[level].reward_feat(player_name,feat) if rewarded then minetest.chat_send_all(player_name..' completed the quest "'..feat..'" on level '..level) minetest.sound_play("skyblock_finish_quest", { to_player = player_name, gain = 1.0, }) minetest.log('action', player_name..' completed the quest "'..feat..'" on level '..level) end end skyblock.feats.save(players_feat[player_name], player_name) skyblock.feats.update(player_name) end -- give reward function skyblock.feats.give_reward(level,player_name,item_name) skyblock.log('skyblock.feats.give_reward('..level..','..player_name..','..item_name..')') local player = minetest.get_player_by_name(player_name) player:get_inventory():add_item('rewards', item_name) --player:set_inventory_formspec(skyblock.levels.get_formspec(player_name)) end -- track eating function skyblock.feats.on_item_eat(hp_change, replace_with_item, itemstack, user, pointed_thing) if not user then return end local player_name = user:get_player_name() local level = skyblock.feats.get_level(player_name) if skyblock.levels[level].on_item_eat then skyblock.levels[level].on_item_eat(player_name, itemstack) end end minetest.register_on_item_eat(skyblock.feats.on_item_eat) -- track crafting function skyblock.feats.on_craft(itemstack, player, old_craft_grid, craft_inv) local player_name = player:get_player_name() local level = skyblock.feats.get_level(player_name) if skyblock.levels[level].on_craft then skyblock.levels[level].on_craft(player_name, itemstack) end end minetest.register_on_craft(skyblock.feats.on_craft) -- track node digging function skyblock.feats.on_dignode(pos, oldnode, digger) if not digger then return end -- needed to prevent server crash when falling.lua runs callback (L:97) local player_name = digger:get_player_name() local level = skyblock.feats.get_level(player_name) if skyblock.levels[level].on_dignode then skyblock.levels[level].on_dignode(pos, oldnode, digger) end end minetest.register_on_dignode(skyblock.feats.on_dignode) -- track node placing function skyblock.feats.on_placenode(pos, newnode, placer, oldnode) --if not placer then return end -- needed to prevent server crash when player leaves local player_name = placer:get_player_name() local level = skyblock.feats.get_level(player_name) if skyblock.levels[level].on_placenode then skyblock.levels[level].on_placenode(pos, newnode, placer, oldnode) end end minetest.register_on_placenode(skyblock.feats.on_placenode) -- track on_place of items with their own on_place local function on_place(v, is_craftitem) local entity = minetest.registered_items[v] if entity and entity.on_place then local old_on_place = entity.on_place; function entity.on_place(itemstack, placer, pointed_thing) local old_count = itemstack:get_count() local res = old_on_place(itemstack, placer, pointed_thing) if itemstack and itemstack:get_count() == old_count-1 then skyblock.feats.on_placenode(pointed_thing, {name=v,param2=0}, placer, nil) end return res; end if( is_craftitem == 1 ) then minetest.register_craftitem(':'..v, entity) else minetest.register_node(':'..v, entity) end end end for _,v in ipairs({'doors:door_wood','doors:door_glass','doors:door_steel','doors:door_obsidian_glass'}) do on_place(v,1); end for _,v in ipairs({ 'default:cactus', 'farming:seed_wheat', 'farming:seed_cotton', 'default:sign_wall', 'default:sign_wall_wood', 'default:apple'}) do on_place(v,0); end -- track bucket feats function skyblock.feats.bucket_on_use(itemstack, user, pointed_thing) --if not user then return end -- needed to prevent server crash when player leaves local player_name = user:get_player_name() local level = skyblock.feats.get_level(player_name) if skyblock.levels[level].bucket_on_use then skyblock.levels[level].bucket_on_use(player_name, pointed_thing) end end -- track bucket_water feats function skyblock.feats.bucket_water_on_use(itemstack, user, pointed_thing) --if not user then return end -- needed to prevent server crash when player leaves local player_name = user:get_player_name() local level = skyblock.feats.get_level(player_name) if skyblock.levels[level].bucket_water_on_use then skyblock.levels[level].bucket_water_on_use(player_name, pointed_thing) end end -- track bucket_lava feats function skyblock.feats.bucket_lava_on_use(itemstack, user, pointed_thing) --if not user then return end -- needed to prevent server crash when player leaves local player_name = user:get_player_name() local level = skyblock.feats.get_level(player_name) if skyblock.levels[level].bucket_lava_on_use then skyblock.levels[level].bucket_lava_on_use(player_name, pointed_thing) end end -- bucket_empty local function bucket_on_use(itemstack, user, pointed_thing) -- Must be pointing to node if pointed_thing.type ~= 'node' then return end -- Check if protected if minetest.is_protected(pointed_thing.under, user:get_player_name()) then return end -- Get the Node and Registered Item local n = minetest.get_node_or_nil(pointed_thing.under) local ndef if n then ndef = minetest.registered_items[n.name] end -- Call on_rightclick if the pointed node defines it if ndef and ndef.on_rightclick and user and not user:get_player_control().sneak then return ndef.on_rightclick(pointed_thing.under, n, user, itemstack) or itemstack end -- Check if pointing to a liquid source local liquid = bucket.liquids[n.name] if liquid ~= nil and liquid.source == n.name and liquid.itemname ~= nil then -- begin track bucket feats skyblock.feats.bucket_on_use(itemstack, user, pointed_thing) -- end track bucket feats minetest.env:add_node(pointed_thing.under, {name='air'}) return {name=liquid.itemname} end end minetest.override_item('bucket:bucket_empty', { on_place = bucket_on_use, on_use = bucket_on_use, }) -- bucket_water local function bucket_water_on_use(itemstack, user, pointed_thing) -- Must be pointing to node if pointed_thing.type ~= 'node' then return end -- Check if protected if minetest.is_protected(pointed_thing.under, user:get_player_name()) then return end -- Get the Node and Registered Item local n = minetest.get_node_or_nil(pointed_thing.under) local ndef if n then ndef = minetest.registered_items[n.name] end -- Call on_rightclick if the pointed node defines it if ndef and ndef.on_rightclick and user and not user:get_player_control().sneak then return ndef.on_rightclick(pointed_thing.under, n, user, itemstack) or itemstack end -- Check if pointing to a liquid if bucket.liquids[n.name] == nil then -- Not a liquid -- begin anti-grief change local player_name = user:get_player_name() local spawn = skyblock.get_spawn(player_name) local range = tonumber(minetest.settings:get("bucket_use_range")) or false -- how far from spawn you can use water local pos = pointed_thing.under if range and (spawn==nil or (pos.x-spawn.x > range or pos.x-spawn.x < range*-1) or (pos.y-spawn.y > range/2 or pos.y-spawn.y < range*-1/2) or (pos.z-spawn.z > range or pos.z-spawn.z < range*-1)) then minetest.chat_send_player(player_name, 'Cannot use bucket so far from your home.') return end -- end anti-grief change minetest.add_node(pointed_thing.above, {name='default:water_source'}) elseif n.name ~= 'default:water_source' then -- It's a liquid minetest.add_node(pointed_thing.under, {name='default:water_source'}) end -- begin track bucket feats skyblock.feats.bucket_water_on_use(itemstack, user, pointed_thing) -- end track bucket feats return {name='bucket:bucket_empty'} end minetest.override_item('bucket:bucket_water', { on_place = bucket_water_on_use, on_use = bucket_water_on_use, }) -- bucket_lava local function bucket_lava_on_use(itemstack, user, pointed_thing) -- Must be pointing to node if pointed_thing.type ~= 'node' then return end -- Check if protected if minetest.is_protected(pointed_thing.under, user:get_player_name()) then return end -- Get the Node and Registered Item local n = minetest.get_node_or_nil(pointed_thing.under) local ndef if n then ndef = minetest.registered_items[n.name] end -- Call on_rightclick if the pointed node defines it if ndef and ndef.on_rightclick and user and not user:get_player_control().sneak then return ndef.on_rightclick(pointed_thing.under, n, user, itemstack) or itemstack end -- Check if pointing to a liquid if bucket.liquids[n.name] == nil then -- Not a liquid -- begin anti-grief change local player_name = user:get_player_name() local spawn = skyblock.get_spawn(player_name) local range = tonumber(minetest.settings:get("bucket_use_range")) or false -- how far from spawn you can use lava local pos = pointed_thing.under if range and (spawn==nil or (pos.x-spawn.x > range or pos.x-spawn.x < range*-1) or (pos.z-spawn.z > range or pos.z-spawn.z < range*-1)) then --if (pos.y-spawn.y > range/2 or pos.y-spawn.y < range*-1/2) then minetest.chat_send_player(player_name, 'Cannot use bucket so far from your home.') return --end end -- end anti-grief change minetest.add_node(pointed_thing.above, {name='default:lava_source'}) elseif n.name ~= 'default:lava_source' then -- It's a liquid minetest.add_node(pointed_thing.under, {name='default:lava_source'}) end -- begin track bucket feats skyblock.feats.bucket_lava_on_use(itemstack, user, pointed_thing) -- end track bucket feats return {name='bucket:bucket_empty'} end minetest.override_item('bucket:bucket_lava', { on_place = bucket_lava_on_use, on_use = bucket_lava_on_use, }) -- add protection to hoes for _, material in pairs({"wood", "stone", "steel", "bronze", "mese", "diamond"}) do local old_use = minetest.registered_items["farming:hoe_" .. material].on_use minetest.override_item("farming:hoe_" .. material, { on_use = function(itemstack, user, pointed_thing) if not minetest.is_protected(pointed_thing.above, user:get_player_name()) then old_use(itemstack, user, pointed_thing) end end }) end -- make directory local function mkdir(path) if minetest.mkdir then minetest.mkdir(path) else os.execute('mkdir "' .. path .. '"') end end -- save data function skyblock.feats.save(data,player_name) local file = io.open(filepath..'/'..player_name, 'wb') if not file then mkdir(filepath) file = io.open(filepath..'/'..player_name, 'wb') if not file then skyblock.log('cannot open feat file for writing "'..filepath..'/'..player_name..'"') end end file:write(minetest.serialize(data)) file:close() end -- load data function skyblock.feats.load(player_name) local file,err = io.open(filepath..'/'..player_name, 'rb') if err then return nil end local data = file:read('*a') file:close() return minetest.deserialize(data) end minetest-skyblock-0.3.0/skyblock_levels/skyblock.levels.1.lua000066400000000000000000000123131410574302100243250ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- --[[ level 1 feats and rewards: * dig_dirt x10 default:stick * place_dirt x10 default:leaves 6 * place_sapling x1 default:tree * dig_tree x16 default:cobble 8 * place_furnace x1 default:axe_steel * place_cobble x50 default:stair_cobble 4 * place_chest x1 default:papyrus 5 * place_sign x1 default:pick_steel * place_door x1 default:sand 2 * place_glass x2 protector:protect ]]-- local level = 1 -- -- PUBLIC FUNCTIONS -- skyblock.levels[level] = {} -- feats skyblock.levels[level].feats = { { name = 'dig 10 Dirt', hint = nil, feat = 'dig_dirt', count = 10, reward = 'default:stick', dignode = {'default:dirt', 'default:dirt_with_grass', 'default:dirt_with_grass_footsteps'}, }, { name = 'place 10 Dirt', hint = 'default:dirt', feat = 'place_dirt', count = 10, reward = 'default:leaves 6', placenode = {'default:dirt'}, }, { name = 'craft a Sapling and grow a Tree', hint = 'default:sapling', feat = 'place_sapling', count = 1, reward = 'default:tree', placenode = {'default:sapling'}, }, { name = 'craft an Axe and dig 16 Tree', hint = 'default:axe_wood', feat = 'dig_tree', count = 16, reward = 'default:cobble 8', dignode = {'default:tree'}, }, { name = 'craft and place a Furnace', hint = 'default:furnace', feat = 'place_furnace', count = 1, reward = 'default:axe_steel', placenode = {'default:furnace'}, }, { name = 'craft and place 50 Cobblestone', hint = 'default:cobble', feat = 'place_cobble', count = 50, reward = 'stairs:stair_cobble 4', placenode = {'default:cobble'}, }, { name = 'craft and place a Chest', hint = 'default:chest', feat = 'place_chest', count = 1, reward = 'default:papyrus 5', placenode = {'default:chest'}, }, { name = 'craft and place a Sign', hint = 'default:sign_wall_wood', feat = 'place_sign', count = 1, reward = 'default:pick_steel', placenode = {'default:sign_wall_wood'}, }, { name = 'craft and place a Door', hint = 'doors:door_wood_a', feat = 'place_door', count = 1, reward = 'default:sand 2', placenode = {'doors:door_wood_a'}, }, { name = 'craft and place 2 Glass', hint = 'default:glass', feat = 'place_glass', count = 2, reward = 'protector:protect', placenode = {'default:glass'}, }, } -- init level skyblock.levels[level].init = function(player_name) -- revoke perms local privs = core.get_player_privs(player_name) if privs['fly'] or privs['fast'] then privs['fly'] = nil privs['fast'] = nil core.set_player_privs(player_name, privs) minetest.chat_send_player(player_name, 'You have lost FLY and FAST') end end -- get level information skyblock.levels[level].get_info = function(player_name) local info = { level=level, total=10, count=0, player_name=player_name, infotext='', formspec = '', formspec_quest = '', } local text = 'label[0,2.7; --== Quests ==--]' ..'label[0,0.5;Welcome '..player_name..', of the Sky People]' ..'label[0,1.0;We can no longer live on the surface.]' ..'label[0,1.5;Can you help us rebuild in the sky?]' ..'label[0,2.0;Complete the quests to receive great rewards!]' info.formspec = skyblock.levels.get_inventory_formspec(level,info.player_name,true)..text info.formspec_quest = skyblock.levels.get_inventory_formspec(level,info.player_name)..text for k,v in ipairs(skyblock.levels[level].feats) do info.formspec = info.formspec..skyblock.levels.get_feat_formspec(info,k,v.feat,v.count,v.name,v.hint,true) info.formspec_quest = info.formspec_quest..skyblock.levels.get_feat_formspec(info,k,v.feat,v.count,v.name,v.hint) end if info.count>0 then info.count = info.count/2 -- only count once end info.infotext = 'LEVEL '..info.level..' for '..info.player_name..': '..info.count..' of '..info.total return info end -- reward_feat skyblock.levels[level].reward_feat = function(player_name,feat) return skyblock.levels.reward_feat(level, player_name, feat) end -- track digging feats skyblock.levels[level].on_dignode = function(pos, oldnode, digger) skyblock.levels.on_dignode(level, pos, oldnode, digger) end -- track placing feats skyblock.levels[level].on_placenode = function(pos, newnode, placer, oldnode) skyblock.levels.on_placenode(level, pos, newnode, placer, oldnode) end -- track eating feats skyblock.levels[level].on_item_eat = function(player_name, itemstack) skyblock.levels.on_item_eat(level, player_name, itemstack) end -- track crafting feats skyblock.levels[level].on_craft = function(player_name, itemstack) skyblock.levels.on_craft(level, player_name, itemstack) end -- track bucket feats skyblock.levels[level].bucket_on_use = function(player_name, pointed_thing) skyblock.levels.bucket_on_use(level, player_name, pointed_thing) end -- track bucket water feats skyblock.levels[level].bucket_water_on_use = function(player_name, pointed_thing) skyblock.levels.bucket_water_on_use(level, player_name, pointed_thing) end -- track bucket lava feats skyblock.levels[level].bucket_lava_on_use = function(player_name, pointed_thing) skyblock.levels.bucket_lava_on_use(level, player_name, pointed_thing) end minetest-skyblock-0.3.0/skyblock_levels/skyblock.levels.2.lua000066400000000000000000000133541410574302100243340ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- --[[ level 2 feats and rewards: * place_trapdoor x1 default:desert_stonebrick 50 * place_ladder x10 default:desert_cobble 50 * place_fence x20 default:cobble 25 * place_gravel x100 stairs:stair_cobble 4 * place_dirt x100 default:jungleleaves 6 * place_cobble x100 default:coal_lump * dig_stone_with_coal x2 default:sandstonebrick 50 * place_torch x8 default:iron_lump * dig_stone_with_iron x4 default:pine_needles 6 * collect_water x1 default:copper_lump ]]-- local level = 2 -- -- PUBLIC FUNCTIONS -- skyblock.levels[level] = {} -- feats skyblock.levels[level].feats = { { name = 'place a Trapdoor', hint = 'doors:trapdoor', feat = 'place_trapdoor', count = 1, reward = 'default:desert_stonebrick 50', placenode = {'doors:trapdoor'}, }, { name = 'place 10 Ladders', hint = 'default:ladder_wood', feat = 'place_ladder', count = 10, reward = 'default:desert_cobble 50', placenode = {'default:ladder_wood', 'default:ladder_steel'}, }, { name = 'place 20 Wood Fences', hint = 'default:fence_wood', feat = 'place_fence', count = 20, reward = 'default:cobble 25', placenode = {'default:fence_wood'}, }, { name = 'build a structure using 100 Gravel', hint = 'default:gravel', feat = 'place_gravel', count = 100, reward = 'stairs:stair_cobble 4', placenode = {'default:gravel'}, }, { name = 'extend your Island with 100 Dirt', hint = 'default:dirt', feat = 'place_dirt', count = 100, reward = 'default:jungleleaves 6', placenode = {'default:dirt'}, }, { name = 'craft and place 100 Cobblestone', hint = 'default:cobble', feat = 'place_cobble', count = 100, reward = 'default:coal_lump', placenode = {'default:cobble'}, }, { name = 'dig 2 Coal Lumps', hint = 'default:stone_with_coal', feat = 'dig_stone_with_coal', count = 2, reward = 'default:sandstonebrick 50', dignode = {'default:stone_with_coal'}, }, { name = 'place 8 Torches', hint = 'default:torch', feat = 'place_torch', count = 8, reward = 'default:iron_lump', placenode = {'default:torch'}, }, { name = 'dig 4 Iron Lumps', hint = 'default:stone_with_iron', feat = 'dig_stone_with_iron', count = 4, reward = 'default:pine_needles 6', dignode = {'default:stone_with_iron'}, }, { name = 'collect the Water Source', hint = 'bucket:bucket_empty', feat = 'collect_water', count = 1, reward = 'default:copper_lump', bucket = {'default:water_source'}, }, } -- init level skyblock.levels[level].init = function(player_name) end -- get level information skyblock.levels[level].get_info = function(player_name) local info = { level=level, total=10, count=0, player_name=player_name, infotext='', formspec = '', formspec_quest = '', } local text = 'label[0,2.7; --== Quests ==--]' ..'label[0,0.5; Hey '..player_name..', Come Up Here!]' ..'label[0,1; Wow, look at that view... of... nothing...]' ..'label[0,1.5; You should get to work extending this island.]' ..'label[0,2; Perhaps you could build some structures too?]' info.formspec = skyblock.levels.get_inventory_formspec(level,info.player_name,true)..text info.formspec_quest = skyblock.levels.get_inventory_formspec(level,info.player_name)..text for k,v in ipairs(skyblock.levels[level].feats) do info.formspec = info.formspec..skyblock.levels.get_feat_formspec(info,k,v.feat,v.count,v.name,v.hint,true) info.formspec_quest = info.formspec_quest..skyblock.levels.get_feat_formspec(info,k,v.feat,v.count,v.name,v.hint) end if info.count>0 then info.count = info.count/2 -- only count once end info.infotext = 'LEVEL '..info.level..' for '..info.player_name..': '..info.count..' of '..info.total return info end -- reward_feat skyblock.levels[level].reward_feat = function(player_name, feat) local rewarded = skyblock.levels.reward_feat(level, player_name, feat) -- add water after dig_stone_with_iron if rewarded and feat == 'dig_stone_with_iron' then local pos = skyblock.get_spawn(player_name) local y_up = 1 while 1 == 1 do local node = minetest.get_node({x=pos.x, y=pos.y+y_up, z=pos.z}).name if node ~= "air" then if node ~= "ignore" then break else -- Err, place at player's pos... pos = minetest.get_player_by_name(player_name):get_pos() y_up = -1 -- Will get back to 0 end y_up = y_up + 1 else break end end minetest.add_node({x=pos.x,y=pos.y+y_up,z=pos.z}, {name='default:water_source'}) return true end return rewarded end -- track digging feats skyblock.levels[level].on_dignode = function(pos, oldnode, digger) skyblock.levels.on_dignode(level, pos, oldnode, digger) end -- track placing feats skyblock.levels[level].on_placenode = function(pos, newnode, placer, oldnode) skyblock.levels.on_placenode(level, pos, newnode, placer, oldnode) end -- track eating feats skyblock.levels[level].on_item_eat = function(player_name, itemstack) skyblock.levels.on_item_eat(level, player_name, itemstack) end -- track crafting feats skyblock.levels[level].on_craft = function(player_name, itemstack) skyblock.levels.on_craft(level, player_name, itemstack) end -- track bucket feats skyblock.levels[level].bucket_on_use = function(player_name, pointed_thing) skyblock.levels.bucket_on_use(level, player_name, pointed_thing) end -- track bucket water feats skyblock.levels[level].bucket_water_on_use = function(player_name, pointed_thing) skyblock.levels.bucket_water_on_use(level, player_name, pointed_thing) end -- track bucket lava feats skyblock.levels[level].bucket_lava_on_use = function(player_name, pointed_thing) skyblock.levels.bucket_lava_on_use(level, player_name, pointed_thing) end minetest-skyblock-0.3.0/skyblock_levels/skyblock.levels.3.lua000066400000000000000000000136001410574302100243270ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- --[[ level 3 feats and rewards: * dig_papyrus x20 wool:white 50 * place_brick x50 stairs:stair_brick 4 * place_mossycobble x50 wool:blue 50 * place_bookshelf x4 wool:red 50 * place_steelblock x4 default:obsidian_shard * place_sand x50 wool:green 50 * dig_stone_with_copper x4 wool:orange 50 * place_bar_flat x8 default:mese_crystal * dig_stone_with_mese x4 default:gold_lump * place_water_infinite x8 default:diamond ]]-- local level = 3 -- -- PUBLIC FUNCTIONS -- skyblock.levels[level] = {} -- feats skyblock.levels[level].feats = { { name = 'grow and collect 20 Papyrus', hint = nil, feat = 'dig_papyrus', count = 20, reward = 'wool:white 50', dignode = {'default:papyrus'}, }, { name = 'place 50 Brick', hint = 'default:brick', feat = 'place_brick', count = 50, reward = 'stairs:stair_brick 4', placenode = {'default:brick'}, }, { name = 'place 50 Mossy Cobblestone', hint = 'default:mossycobble', feat = 'place_mossycobble', count = 50, reward = 'wool:blue 50', placenode = {'default:mossycobble'}, }, { name = 'place 4 Bookshelves', hint = 'default:bookshelf', feat = 'place_bookshelf', count = 4, reward = 'wool:red 50', placenode = {'default:bookshelf'}, }, { name = 'place 4 Steel Blocks', hint = 'default:steelblock', feat = 'place_steelblock', count = 4, reward = 'default:obsidian_shard', placenode = {'default:steelblock'}, }, { name = 'place 50 Sand', hint = 'default:sand', feat = 'place_sand', count = 50, reward = 'wool:green 50', placenode = {'default:sand'}, }, { name = 'dig 4 Copper lumps', hint = 'default:stone_with_copper', feat = 'dig_stone_with_copper', count = 4, reward = 'wool:orange 50', dignode = {'default:stone_with_copper'}, }, { name = 'place 8 Iron Bars', hint = 'xpanes:bar_flat', feat = 'place_bar_flat', count = 8, reward = 'default:mese_crystal', placenode = {'xpanes:bar_flat'}, }, { name = 'dig 4 Mese Crystals', hint = 'default:stone_with_mese', feat = 'dig_stone_with_mese', count = 4, reward = 'default:gold_lump', dignode = {'default:stone_with_mese'}, }, { name = 'place Infinite Water (diagonal)', hint = 'bucket:bucket_empty', feat = 'place_water_infinite', count = 1, reward = 'default:diamond', --bucket_water = {}, }, } -- init level skyblock.levels[level].init = function(player_name) end -- get level information skyblock.levels[level].get_info = function(player_name) local info = { level=level, total=10, count=0, player_name=player_name, infotext='', formspec = '', formspec_quest = '', } local text = 'label[0,2.7; --== Quests ==--]' ..'label[0,0.5; Oh '..player_name..', Does This Keep Going?]' ..'label[0,1.0; If you are enjoying this world, then stray not]' ..'label[0,1.5; from your mission traveller...]' ..'label[0,2.0; ... for the end is near.]' info.formspec = skyblock.levels.get_inventory_formspec(level,info.player_name,true)..text info.formspec_quest = skyblock.levels.get_inventory_formspec(level,info.player_name)..text for k,v in ipairs(skyblock.levels[level].feats) do info.formspec = info.formspec..skyblock.levels.get_feat_formspec(info,k,v.feat,v.count,v.name,v.hint,true) info.formspec_quest = info.formspec_quest..skyblock.levels.get_feat_formspec(info,k,v.feat,v.count,v.name,v.hint) end if info.count>0 then info.count = info.count/2 -- only count once end info.infotext = 'LEVEL '..info.level..' for '..info.player_name..': '..info.count..' of '..info.total return info end -- reward_feat skyblock.levels[level].reward_feat = function(player_name, feat) local rewarded = skyblock.levels.reward_feat(level, player_name, feat) -- add water after dig_stone_with_mese if rewarded and feat == 'dig_stone_with_mese' then local pos = skyblock.get_spawn(player_name) minetest.add_node({x=pos.x,y=pos.y+1,z=pos.z}, {name='default:water_source'}) return true end return rewarded end -- track digging feats skyblock.levels[level].on_dignode = function(pos, oldnode, digger) skyblock.levels.on_dignode(level, pos, oldnode, digger) end -- track placing feats skyblock.levels[level].on_placenode = function(pos, newnode, placer, oldnode) skyblock.levels.on_placenode(level, pos, newnode, placer, oldnode) end -- track eating feats skyblock.levels[level].on_item_eat = function(player_name, itemstack) skyblock.levels.on_item_eat(level, player_name, itemstack) end -- track crafting feats skyblock.levels[level].on_craft = function(player_name, itemstack) skyblock.levels.on_craft(level, player_name, itemstack) end -- track bucket feats skyblock.levels[level].bucket_on_use = function(player_name, pointed_thing) skyblock.levels.bucket_on_use(level, player_name, pointed_thing) end -- track bucket water feats skyblock.levels[level].bucket_water_on_use = function(player_name, pointed_thing) skyblock.levels.bucket_water_on_use(level, player_name, pointed_thing) -- place_water_infinite local pos = pointed_thing.under if minetest.get_node({x=pos.x-1,y=pos.y,z=pos.z-1}).name=='default:water_source' or minetest.get_node({x=pos.x-1,y=pos.y,z=pos.z+1}).name=='default:water_source' or minetest.get_node({x=pos.x+1,y=pos.y,z=pos.z-1}).name=='default:water_source' or minetest.get_node({x=pos.x+1,y=pos.y,z=pos.z+1}).name=='default:water_source' then skyblock.feats.add(level,player_name,'place_water_infinite') return end end -- track bucket lava feats skyblock.levels[level].bucket_lava_on_use = function(player_name, pointed_thing) skyblock.levels.bucket_lava_on_use(level, player_name, pointed_thing) end minetest-skyblock-0.3.0/skyblock_levels/skyblock.levels.4.lua000066400000000000000000000123371410574302100243360ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- --[[ Level 4 mostly revolving around farming and dying level 4 feats and rewards: * craft_diamondhoe farming:seed_wheat * use_hoe x40 farming:melon_slice * plant_wheatseed default:cactus * craft_flour farming:seed_cotton x10 * place_snowblock x50 dye:red x20 * dig_cactus x10 dye:white x20 * dig_geranium x5 flowers:mushroom_brown x2 * dig_tulip x5 flowers:mushroom_red x2 * dig_brownmushroom x15 farming:corn x50 * craft_ethanol default:meselamp x5 ]]-- local level = 4 -- -- PUBLIC FUNCTIONS -- skyblock.levels[level] = {} -- feats -- Parts of this are purely hypothetical and not implement yet skyblock.levels[level].feats = { { name = "Craft a mese hoe", hint = "farming:hoe_mese", feat = "craft_mesehoe", count = 1, reward = "farming:seed_wheat 2", craft = {"farming:hoe_mese"} }, { name = "Use the hoe 40 times", hint = "farming:hoe_mese", feat = "use_hoe", count = 40, reward = "farming:melon_slice", hoeuse = {} }, { name = "Plant 10 wheat seeds", hint = "farming:seed_wheat", feat = "place_wheatseed", count = 10, reward = "default:cactus", placenode = {"farming:seed_wheat"} }, { name = "Craft 4 lumps of flour", hint = "farming:flour", feat = "craft_flour", count = 4, reward = "farming:seed_cotton 10", craft = {"farming:flour"}, }, { name = "Place 50 snow blocks", hint = "default:snowblock", feat = "place_snowblock", count = 50, reward = "dye:red 20", placenode = {"default:snowblock"}, }, { name = "Dig 10 cacti", hint = "default:cactus", feat = "dig_cactus", count = 10, reward = "dye:white 20", dignode = {"default:cactus"}, }, { name = "Pick 5 Geranium flowers", hint = "flowers:geranium", feat = "dig_geranium", count = 5, reward = "flowers:mushroom_brown 2", dignode = {"flowers:geranium"}, }, { name = "Pick 5 orange tulips", hint = "flowers:tulip", feat = "dig_tulip", count = 5, reward = "flowers:mushroom_red 2", dignode = {"flowers:tulip"}, }, { name = "Dig 10 brown mushrooms", hint = "flowers:mushroom_brown", feat = "dig_brownmushroom", count = 10, reward = "farming:corn", dignode = {"flowers:mushroom_brown"}, }, { name = "Make ethanol!", hint = "farming:corn", feat = "craft_ethanol", count = 1, reward = "default:meselamp 5", craft = {"farming:bottle_ethanol"}, } } -- init level skyblock.levels[level].init = function(player_name) end -- get level information skyblock.levels[level].get_info = function(player_name) local info = { level=level, total=10, count=0, player_name=player_name, infotext='', formspec = '', formspec_quest = '', } local text = 'label[0,2.7; --== Quests ==--]' ..'label[0,0.5; Time Goes On, '..player_name..'...]' ..'label[0,1.0; You may wonder, traveller, where some of your]' ..'label[0,1.5; precious items are. Be patient...]' ..'label[0,2.0; They will come to you in time...]' info.formspec = skyblock.levels.get_inventory_formspec(level,info.player_name,true)..text info.formspec_quest = skyblock.levels.get_inventory_formspec(level,info.player_name)..text for k,v in ipairs(skyblock.levels[level].feats) do info.formspec = info.formspec..skyblock.levels.get_feat_formspec(info,k,v.feat,v.count,v.name,v.hint,true) info.formspec_quest = info.formspec_quest..skyblock.levels.get_feat_formspec(info,k,v.feat,v.count,v.name,v.hint) end if info.count>0 then info.count = info.count/2 -- only count once end info.infotext = 'LEVEL '..info.level..' for '..info.player_name..': '..info.count..' of '..info.total return info end -- Reward feats skyblock.levels[level].reward_feat = function(player_name, feat) return skyblock.levels.reward_feat(level, player_name, feat) end -- Track node placement skyblock.levels[level].on_placenode = function(pos, newnode, placer, oldnode) skyblock.levels.on_placenode(level, pos, newnode, placer, oldnode) end -- Track node digging skyblock.levels[level].on_dignode = function(pos, oldnode, digger) skyblock.levels.on_dignode(level, pos, oldnode, digger) end -- track eating feats skyblock.levels[level].on_item_eat = function(player_name, itemstack) skyblock.levels.on_item_eat(level, player_name, itemstack) end -- track crafting feats skyblock.levels[level].on_craft = function(player_name, itemstack) skyblock.levels.on_craft(level, player_name, itemstack) end -- track hoe use skyblock.levels[level].hoe_on_use = function(player_name, pointed_thing, wieldeditem) skyblock.levels.hoe_on_use(level, player_name, pointed_thing, wieldeditem) end skyblock.levels[level].bucket_on_use = function(player_name, pointed_thing) end skyblock.levels[level].bucket_water_on_use = function(player_name, pointed_thing) end skyblock.levels[level].bucket_lava_on_use = function(player_name, pointed_thing) end minetest-skyblock-0.3.0/skyblock_levels/skyblock.levels.5.lua000066400000000000000000000035621410574302100243370ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- local level = 5 -- -- PUBLIC FUNCTIONS -- skyblock.levels[level] = {} -- feats skyblock.levels[level].feats = {} -- init level skyblock.levels[level].init = function(player_name) local privs = core.get_player_privs(player_name) privs['fly'] = true privs['fast'] = true core.set_player_privs(player_name, privs) minetest.chat_send_player(player_name, 'You can now use FLY and FAST !') end -- get level information skyblock.levels[level].get_info = function(player_name) local info = { level=level, total=1, count=0, player_name=player_name, infotext='', formspec = '', formspec_quest = '', } local text = 'label[0,0.5; THE END]' ..'label[0,1.0; I hope you enjoyed your journey, and you]' ..'label[0,1.5; are welcome to stay and keep building]' ..'label[0,2.0; your new sky world.]' info.formspec = skyblock.levels.get_inventory_formspec(level,info.player_name,true)..text info.formspec_quest = skyblock.levels.get_inventory_formspec(level,info.player_name)..text info.infotext = 'THE END! for '.. player_name ..' ... or is it ...' return info end -- no feat tracking skyblock.levels[level].reward_feat = function(player_name, feat) end skyblock.levels[level].on_placenode = function(pos, newnode, placer, oldnode) end skyblock.levels[level].on_dignode = function(pos, oldnode, digger) end skyblock.levels[level].on_item_eat = function(player_name, itemstack) end skyblock.levels[level].on_craft = function(player_name, itemstack) end skyblock.levels[level].bucket_on_use = function(player_name, pointed_thing) end skyblock.levels[level].bucket_water_on_use = function(player_name, pointed_thing) end skyblock.levels[level].bucket_lava_on_use = function(player_name, pointed_thing) end minetest-skyblock-0.3.0/skyblock_levels/skyblock.levels.X.lua000066400000000000000000000014001410574302100243670ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- --[[ not a real level, just ideas and leftover code feats: * place_cactus * place_papyrus * dig_flower * place_bookshelf * collect_water * place_water_infinite * place_sand * place_desert_sand * place_stone * place_cobble * place_mossycobble * place_steelblock * dig_stone_with_copper * dig_stone * place_glass rewards: * default:lava_source * default:desert_stone 50 * default:brick 50 { name = 'craft a Small Bag', hint = 'unified_inventory:bag_small', feat = 'craft_bag', count = 1, reward = 'protector:protect', craft = {'unified_inventory:bag_small'}, }, --]] minetest-skyblock-0.3.0/skyblock_levels/skyblock.levels.lua000066400000000000000000000172551410574302100242000ustar00rootroot00000000000000--[[ Skyblock for Minetest Copyright (c) 2015 cornernote, Brett O'Donnell Source Code: https://github.com/cornernote/minetest-skyblock License: GPLv3 ]]-- skyblock.levels = {} -- -- CONFIG OPTIONS -- -- true to restart from level1, false to restart from current level skyblock.levels.restart_on_die = minetest.setting_getbool('skyblock.levels.restart_on_die') -- -- Functions -- -- empty inventory function skyblock.levels.empty_inventory(player) local inv = player:get_inventory() if not inv:is_empty('rewards') then for i=1,inv:get_size('rewards') do inv:set_stack('rewards', i, nil) end end if skyblock.levels.lose_bags_on_death then local bags_inv = minetest.get_inventory({type='detached', name=player:get_player_name()..'_bags'}) for bag=1,4 do if not bags_inv:is_empty('bag'..bag) then for i=1,bags_inv:get_size('bag'..bag) do inv:set_stack('bag'..bag, i, nil) end for i=1,bags_inv:get_size('bag'..bag) do bags_inv:set_stack('bag'..bag, i, nil) inv:set_stack('bag'..bag..'contents', i, nil) end end end end end -- -- Formspec -- -- get_formspec function skyblock.levels.get_formspec(player_name) local level = skyblock.feats.get_level(player_name) local level_info = skyblock.levels[level].get_info(player_name) return level_info.formspec end -- get_inventory_formspec function skyblock.levels.get_inventory_formspec(level,player_name,inventory) local formspec = 'size[15,10;]' if inventory then if minetest.get_modpath('unified_inventory') then formspec = formspec..skyblock.get_unified_inventory_buttons() end formspec = formspec..'button_exit[13,0;2,0.5;close;Close]' else formspec = formspec ..'button[11,0;2,0.5;restart;Restart]' ..'button_exit[13,0;2,0.5;close;Close]' end formspec = formspec ..'background[-0.1,-0.1;6.6,10.3;goals.png]' ..'label[0,0; --== LEVEL '..level..' for '..player_name..' ==--]' ..'label[7,1.5; Rewards]' ..'background[6.9,1.4;2.2,2.8;rewards.png]' ..'list[current_player;rewards;7,2;2,2;]' ..'label[10,1.5; Craft]' ..'label[14,2.5;Output]' ..'background[9.9,1.4;5.2,3.8;craft.png]' ..'list[current_player;craft;10,2;3,3;]' ..'list[current_player;craftpreview;14,3;1,1;]' ..'label[7,5.5; Inventory]' ..'background[6.9,5.4;8.2,4.8;inventory.png]' ..'list[current_player;main;7,6;8,4;]' return formspec end -- render an item image button for the formspec local function image_button_link(stack_string) local stack = ItemStack(stack_string); local new_node_name = stack_string; if stack and stack:get_name() then new_node_name = stack:get_name() end return tostring(stack_string)..';item_button_nochange_'..unified_inventory.mangle_for_formspec(new_node_name)..';' end -- get_feat_formspec function skyblock.levels.get_feat_formspec(info,i,feat,required,text,hint,inventory) local y = 2.9+(i*0.6) local count = skyblock.feats.get(info.level,info.player_name,feat) if count > required then count = required end local formspec = 'label[0.5,'..y..'; '..text..' ('..count..'/'..required..')]' if hint then if inventory and minetest.get_modpath('unified_inventory') then formspec = formspec..'item_image_button[5.8,'..y..';0.6,0.6;'..image_button_link(hint)..']' else formspec = formspec..'item_image_button[5.8,'..y..';0.6,0.6;'..skyblock.craft_guide.image_button_link(hint)..']' end end if count == required then formspec = formspec .. 'image[-0.2,'..(y-0.25)..';1,1;checkbox_checked.png]' info.count = info.count + 1 else formspec = formspec .. 'image[-0.2,'..(y-0.25)..';1,1;checkbox_unchecked.png]' end return formspec end -- get_unified_inventory_buttons function skyblock.get_unified_inventory_buttons() local formspec = '' local button_row = 0 local button_col = 0 local main_button_x = 7 local main_button_y = 0 for i, def in pairs(unified_inventory.buttons) do if unified_inventory.lite_mode and i > 4 then button_row = 1 button_col = 1 end local tooltip = def.tooltip or '' if def.type == 'image' then formspec = formspec..'image_button[' ..( main_button_x + 0.65 * (i - 1) - button_col * 0.65 * 4) ..','..(main_button_y + button_row * 0.7)..';0.8,0.8;' ..minetest.formspec_escape(def.image)..';' ..minetest.formspec_escape(def.name)..';]' ..'tooltip['..minetest.formspec_escape(def.name) ..';'..tooltip..']' end end return formspec end -- get_restart_formspec function skyblock.show_restart_formspec(player_name) local formspec = 'size[6,2.5;]' ..'label[0,0.0;-= Are you sure you want to restart? =-]' ..'label[0,0.5;You will lose all your Items and will have to redo]' ..'label[0,1.0;all of your Quests starting from Level 1.]' ..'button[0,2;3,0.5;restart;Confirm Restart]' ..'button_exit[3,2;3,0.5;close;Cancel]' minetest.show_formspec(player_name, 'skyblock_restart', formspec) end -- -- Feat Checks -- -- reward_feat function skyblock.levels.reward_feat(level,player_name,feat) local count = skyblock.feats.get(level,player_name,feat) for _,v in ipairs(skyblock.levels[level].feats) do if v.feat == feat and v.count == count then skyblock.feats.give_reward(level,player_name,v.reward) return true end end end -- track digging feats function skyblock.levels.on_dignode(level,pos,oldnode,digger) local player_name = digger:get_player_name() for _,v in ipairs(skyblock.levels[level].feats) do if v.dignode then for _,vv in ipairs(v.dignode) do if oldnode.name == vv then skyblock.feats.add(level,player_name,v.feat) return end end end end end -- track placing feats function skyblock.levels.on_placenode(level,pos,newnode,placer,oldnode) local player_name = placer:get_player_name() for _,v in ipairs(skyblock.levels[level].feats) do if v.placenode then for _,vv in ipairs(v.placenode) do if newnode.name == vv then skyblock.feats.add(level,player_name,v.feat) return end end end end end -- track eating feats function skyblock.levels.on_item_eat(level,player_name,itemstack) local item_name = itemstack:get_name() for _,v in ipairs(skyblock.levels[level].feats) do if v.item_eat then for _,vv in ipairs(v.item_eat) do if item_name==vv then skyblock.feats.add(level,player_name,v.feat) return end end end end end -- track crafting feats function skyblock.levels.on_craft(level,player_name,itemstack) local item_name = itemstack:get_name() for _,v in ipairs(skyblock.levels[level].feats) do if v.craft then for _,vv in ipairs(v.craft) do if item_name==vv then skyblock.feats.add(level,player_name,v.feat) return end end end end end -- track bucket feats function skyblock.levels.bucket_on_use(level,player_name,pointed_thing) local node = minetest.env:get_node(pointed_thing.under) for _,v in ipairs(skyblock.levels[level].feats) do if v.bucket then for _,vv in ipairs(v.bucket) do if node.name == vv then skyblock.feats.add(level,player_name,v.feat) return end end end end end -- track bucket water feats function skyblock.levels.bucket_water_on_use(level,player_name,pointed_thing) local node = minetest.env:get_node(pointed_thing.under) for _,v in ipairs(skyblock.levels[level].feats) do if v.bucket_water then for _,vv in ipairs(v.bucket_water) do if node.name == vv then skyblock.feats.add(level,player_name,v.feat) return end end end end end -- track bucket lava feats function skyblock.levels.bucket_lava_on_use(level,player_name,pointed_thing) local node = minetest.env:get_node(pointed_thing.under) for _,v in ipairs(skyblock.levels[level].feats) do if v.bucket_lava then for _,vv in ipairs(v.bucket_lava) do if node.name == vv then skyblock.feats.add(level,player_name,v.feat) return end end end end endminetest-skyblock-0.3.0/skyblock_levels/sounds/000077500000000000000000000000001410574302100216645ustar00rootroot00000000000000minetest-skyblock-0.3.0/skyblock_levels/sounds/skyblock_finish_level_player.ogg000077500000000000000000000364021410574302100303160ustar00rootroot00000000000000OggSj{ ubvorbisDOggSj{̤PE?vorbis/Xiph.Org libVorbis I 20140122 (Turpakäräjiin)vorbis!BCVcT)FR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Džh@fM@(6o/ƀ'-}]v@I~\o=8@Ys@= _@;O)}]o͉(_# 2@bT`3=3@+}\}vkIJ"|+| ʚ^ é+ޯ }^o&J"|p{tkb <_}]o ^ qY :n_ Pn*0;t h }^q̫ zdkb __yv._ v@I~mo} ؗ ;@o_ nwp_n2&"p 6._ v@H>o܂ 51u@ p }_/hE"9~w2/dUǭ@7._ vնH:on[ x=tk]vO}u_ v1%{ۿܞe`M D}x._ B_[5k0  '"u_t{ aJ"2 i@@ ,_v@H~_O}P8  ._v$ro/ J5 [(n_@;@p,q$ro/G `@&P W`x ._K_@@>0u [:@',z$r7?ۗ)ttqп~|,_" Ǣ X//N߸vYDgU=J _}+P!Y45a .$>}_֯}DH/S#@*@@'@ so,AA">@20N`_ {{/@"߳|ie o?.Ytminetest-skyblock-0.3.0/skyblock_levels/sounds/skyblock_finish_other.ogg000077500000000000000000000146641410574302100267620ustar00rootroot00000000000000OggS7yapzvorbisDOggS7yac+?vorbis/Xiph.Org libVorbis I 20140122 (Turpakäräjiin)vorbis!BCVcT)FRJs1FbJBHsS9לk SP)RRic)RKI%t:'c[I֘kA RL)ĔRBS)ŔRJB%t:SJ(AsctJ$dLBH)JSNBH5R)sRRjA B АU@ P2((#9cI pIɱ$K,KDQU}6UUu]u]u 4d@H d Y F(BCVb(9&|sf9h*tp"In*s9's8srf1h&sf)h&sAks9qFsAj6s9j.s"Im.s9s9sspN8sZnBs>{sB8s9s9sАUA6q HEiȤݣ$h r GR TI) 4d!RH!RH!R!b) *2,2,2밳:0C KMXckZiJ)RJ) YdAF!R!r)BCV<=<<8;::46 *y[lp@G7Z*֊|"Aa,׹*q[k尀0R {Y$TW򚏭akD`HM\%RvV QV}U1_gsНfJ[ò=)N7L e_@Đd6e+}^:!tkްoZoW_3>7;tr}~O}#YU @\78]$&}<~>MӬtwYNnsIlP6rS?iW;d2a>nC++ |_g¼:d Q@H6zn12m%: j>xڳe 0b8WKZ@/8e z7t?&8m䈜D:*0 @*p ]¢ V,R#/Q@ v1V gq;U>߇ آ|PL:?U)]ÖI>Lʉb#X>Y 2yT {jn )W}COrrEԬ!ĝ4fߛkMG/|Wq*6Hd} м Ϭ*Cl z9n~W5(:~p#8~ZAJ' HD8<:8Ev-f{>sqU ?4]'fr"#-lWhe+G 0 0<4 =]{ʦ^ۧSN`WO>m|NiOhS 2_3oHH/SѶR |Ib 3EP#>_hYD.}ms+l! )@\zGN~)XEIXRv; D!`7@|C7$2 elD.tJ+8!!X(7iI/mOp@G@, Qƒկ~8-$@L(򰃺pQ}(n\>];8!-V͔Gn.}b[KIׯo<N( D>\F,_6-ϯ=_w{8( ?P|_6ȝO}vr0jpz;V;vminetest-skyblock-0.3.0/skyblock_levels/sounds/skyblock_finish_quest.ogg000077500000000000000000000365271410574302100270040ustar00rootroot00000000000000OggSScYl9vorbisDOggSScYA?vorbis/Xiph.Org libVorbis I 20140122 (Turpakäräjiin)vorbis!BCVcT)FRJs1FbJBHsS9לk SP)RRic)RKI%t:'c[I֘kA RL)ĔRBS)ŔRJB%t:SJ(AsctJ$dLBH)JSNBH5R)sRRjA B АU@ P2((#9cI pIɱ$K,KDQU}6UUu]u]u 4d@H d Y F(BCVb(9&|sf9h*tp"In*s9's8srf1h&sf)h&sAks9qFsAj6s9j.s"Im.s9s9sspN8sZnBs>{sB8s9s9sАUA6q HEiȤݣ$h r GR TI) 4d!RH!RH!R!b) *2,2,2밳:0C KMXckZiJ)RJ) YdAF!R!r)BCV^{}=Sׁ" Bh& (=SL|5^0P836q=8Ւ4D/NNoiO%B4>};Nv6@+ ;@H>@;@sh `AoH Mikz`@)&7}-ڕGǫ 6Qn ? Ib'BӁ x @ցDB1 GoOn|=:{k-$U07׍k= XGmݪA _D=Xy*hP@6Q*>@ ANR9aSN}yXt;ae NӀ?DŽ$R9bhI핻+n;‰,X+~ SVAR^Eg&i+\뼚+[?^N++T9/SNJ+!^>loAv6po%yR9ig&~~,d8yBGd T^&X_E|\({A~WyAdFnTBw)!8`1ކދkAk:{z #VVT,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]7`HYD|oi(_nU YL!Ph.>)(_ _sDM(_n hߘp+can=(ߘ $rKqpFcUe(__npH $e u"(_n YL! E{/@"| V5{(6ot;,_n Qt @n~t,_n YLB?*,_n Q1=n@@P>v,_n YLm@,_n Qt )r,_n Ytminetest-skyblock-0.3.0/skyblock_levels/textures/000077500000000000000000000000001410574302100222345ustar00rootroot00000000000000minetest-skyblock-0.3.0/skyblock_levels/textures/ui_skyblock_icon.png000066400000000000000000000455561410574302100263070ustar00rootroot00000000000000PNG  IHDR>a pHYs   OiCCPPhotoshop ICC profilexڝSgTS=BKKoR RB&*! J!QEEȠQ, !{kּ> H3Q5 B.@ $pd!s#~<<+"x M0B\t8K@zB@F&S`cbP-`'{[! eDh;VEX0fK9-0IWfH  0Q){`##xFW<+*x<$9E[-qWW.(I+6aa@.y24x6_-"bbϫp@t~,/;m%h^ uf@Wp~<5j>{-]cK'Xto(hw?G%fIq^D$.Tʳ?D*A, `6B$BB dr`)B(Ͱ*`/@4Qhp.U=pa( Aa!ڈbX#!H$ ɈQ"K5H1RT UH=r9\F;2G1Q= C7F dt1r=6Ыhڏ>C03l0.B8, c˱" VcϱwE 6wB aAHXLXNH $4 7 Q'"K&b21XH,#/{C7$C2'ITFnR#,4H#dk9, +ȅ3![ b@qS(RjJ4e2AURݨT5ZBRQ4u9̓IKhhitݕNWGw Ljg(gwLӋT071oUX**| J&*/Tު UUT^S}FU3S ԖUPSSg;goT?~YYLOCQ_ cx,!k u5&|v*=9C3J3WRf?qtN (~))4L1e\kXHQG6EYAJ'\'GgSSݧ M=:.kDwn^Loy}/TmG X $ <5qo</QC]@Caaᄑ.ȽJtq]zۯ6iܟ4)Y3sCQ? 0k߬~OCOg#/c/Wװwa>>r><72Y_7ȷOo_C#dz%gA[z|!?:eAAA!h쐭!ΑiP~aa~ 'W?pX15wCsDDDޛg1O9-J5*>.j<74?.fYXXIlK9.*6nl {/]py.,:@LN8A*%w% yg"/6шC\*NH*Mz쑼5y$3,幄'L Lݛ:v m2=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