diff --git a/LICENSE b/LICENSE new file mode 100644 index 000000000..e72bfddab --- /dev/null +++ b/LICENSE @@ -0,0 +1,674 @@ + GNU GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + Copyright (C) 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 +. \ No newline at end of file diff --git a/README.md b/README.md index 44cf5fa67..a9a56d319 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,5 @@ # ViaVersion - Spigot, Sponge, BungeeCord, Velocity + [![Latest Release](https://img.shields.io/github/v/release/ViaVersion/ViaVersion)](https://viaversion.com) [![Build Status](https://travis-ci.com/ViaVersion/ViaVersion.svg?branch=master)](https://travis-ci.com/ViaVersion/ViaVersion) [![Discord](https://img.shields.io/badge/chat-on%20discord-blue.svg)](https://viaversion.com/discord) @@ -14,16 +15,13 @@ On Paper you may also use ProtocolSupport, but ensure you have the right build f **User Docs:** https://docs.viaversion.com/display/VIAVERSION/ - - Sources: -------- -**wiki.vg** (Used for various information, we also contribute back) +**[wiki.vg](https://wiki.vg)** (Used for information regarding packet structure, we also contribute back) -**Burger** (See [PAaaS](https://github.com/Matsv/Paaas)) - -**OpenNBT** (used for slot rewriting) +**[Burger](https://github.com/Pokechu22/Burger)** (See [PAaaS](https://github.com/Matsv/Paaas)) +**[OpenNBT](https://github.com/ViaVersion/OpenNBT)** Releases / Dev Builds: @@ -32,7 +30,6 @@ You can find official releases here: https://www.spigotmc.org/resources/viaversion.19254/history - ---------- You can find official dev builds here: @@ -41,17 +38,42 @@ You can find official dev builds here: **JavaDocs:** https://jd.viaversion.com -**Maven Repo:** https://repo.viaversion.com +**Maven Repository:** +```xml + + viaversion-repo + https://repo.viaversion.com + +``` + +**API-artifact:** +```xml + + us.myles + viaversion-api + LATEST + provided + +``` + +Replace the version depending on your needs. + +If you need access to the existing protocol or platform implementations, use the parent artifact `viaversion`. +Please note the [differences in licensing](#license). + Building: -------- +After cloning this repository, build the project with Gradle by running `/gradlew build` and take the created jar out of +the `build/libs` directory. -After cloning this repository, build the project with Gradle by running `/gradlew build` and take the created jar out of the `build/libs` directory. License: -------- +The entirety of the [API directory](api) is licensed under the MIT License; see [licenses/MIT.md](licenses/MIT.md) for +details. -MIT License, see LICENSE.txt for more details. +Everything else, unless explicitly stated otherwise, is licensed under the GNU General Public License, including the end +product as a whole; see [licenses/GPL.md](licenses/GPL.md) for details. - -Special thanks to all our [Contributors](https://github.com/ViaVersion/ViaVersion/graphs/contributors) +Special thanks to all our [Contributors](https://github.com/ViaVersion/ViaVersion/graphs/contributors). diff --git a/api/build.gradle.kts b/api/build.gradle.kts new file mode 100644 index 000000000..8265d0532 --- /dev/null +++ b/api/build.gradle.kts @@ -0,0 +1,20 @@ +plugins { + id("net.kyori.blossom") version "1.1.0" +} + +blossom { + replaceToken("\$VERSION", project.version) + replaceToken("\$IMPL_VERSION", "git-ViaVersion-${project.version}:${rootProject.latestCommitHash()}") +} + +dependencies { + api(project(":adventure", "shadow")) + api("it.unimi.dsi", "fastutil", Versions.fastUtil) + api("com.viaversion", "opennbt", Versions.openNBT) + api("com.google.code.gson", "gson", Versions.gson) + + compileOnlyApi("org.yaml", "snakeyaml", Versions.snakeYaml) + compileOnlyApi("io.netty", "netty-all", Versions.netty) + compileOnlyApi("com.google.guava", "guava", Versions.guava) + compileOnlyApi("org.jetbrains", "annotations", Versions.jetbrainsAnnotations) +} diff --git a/api/src/main/java/us/myles/ViaVersion/ViaManager.java b/api/src/main/java/us/myles/ViaVersion/ViaManager.java new file mode 100644 index 000000000..ad1f8b62e --- /dev/null +++ b/api/src/main/java/us/myles/ViaVersion/ViaManager.java @@ -0,0 +1,76 @@ +package us.myles.ViaVersion; + +import org.jetbrains.annotations.Nullable; +import us.myles.ViaVersion.api.command.ViaVersionCommand; +import us.myles.ViaVersion.api.data.UserConnection; +import us.myles.ViaVersion.api.platform.ViaConnectionManager; +import us.myles.ViaVersion.api.platform.ViaInjector; +import us.myles.ViaVersion.api.platform.ViaPlatform; +import us.myles.ViaVersion.api.platform.ViaPlatformLoader; +import us.myles.ViaVersion.api.platform.providers.ViaProviders; +import us.myles.ViaVersion.api.protocol.Protocol; + +import java.util.Map; +import java.util.Set; +import java.util.UUID; + +public interface ViaManager { + + Set getConnections(); + + /** + * @deprecated use getConnectedClients() + */ + @Deprecated + Map getPortedPlayers(); + + Map getConnectedClients(); + + UUID getConnectedClientId(UserConnection conn); + + /** + * @see ViaConnectionManager#isClientConnected(UUID) + */ + boolean isClientConnected(UUID player); + + void handleLoginSuccess(UserConnection info); + + ViaPlatform getPlatform(); + + ViaProviders getProviders(); + + boolean isDebug(); + + void setDebug(boolean debug); + + ViaInjector getInjector(); + + ViaVersionCommand getCommandHandler(); + + ViaPlatformLoader getLoader(); + + /** + * Returns a mutable set of self-added subplatform version strings. + * This set is expanded by the subplatform itself (e.g. ViaBackwards), and may not contain all running ones. + * + * @return mutable set of subplatform versions + */ + Set getSubPlatforms(); + + /** + * @see ViaConnectionManager#getConnectedClient(UUID) + */ + @Nullable + UserConnection getConnection(UUID playerUUID); + + /** + * Adds a runnable to be executed when ViaVersion has finished its init before the full server load. + * + * @param runnable runnable to be executed + */ + void addEnableListener(Runnable runnable); + + Protocol getBaseProtocol(); + + boolean isBaseProtocol(Protocol protocol); +} diff --git a/common/src/main/java/us/myles/ViaVersion/api/PacketWrapper.java b/api/src/main/java/us/myles/ViaVersion/api/PacketWrapper.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/PacketWrapper.java rename to api/src/main/java/us/myles/ViaVersion/api/PacketWrapper.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/Pair.java b/api/src/main/java/us/myles/ViaVersion/api/Pair.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/Pair.java rename to api/src/main/java/us/myles/ViaVersion/api/Pair.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/Triple.java b/api/src/main/java/us/myles/ViaVersion/api/Triple.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/Triple.java rename to api/src/main/java/us/myles/ViaVersion/api/Triple.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/Via.java b/api/src/main/java/us/myles/ViaVersion/api/Via.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/Via.java rename to api/src/main/java/us/myles/ViaVersion/api/Via.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/ViaAPI.java b/api/src/main/java/us/myles/ViaVersion/api/ViaAPI.java similarity index 87% rename from common/src/main/java/us/myles/ViaVersion/api/ViaAPI.java rename to api/src/main/java/us/myles/ViaVersion/api/ViaAPI.java index 87f2e50f7..0fbf9f72b 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/ViaAPI.java +++ b/api/src/main/java/us/myles/ViaVersion/api/ViaAPI.java @@ -4,7 +4,6 @@ import io.netty.buffer.ByteBuf; import us.myles.ViaVersion.api.boss.BossBar; import us.myles.ViaVersion.api.boss.BossColor; import us.myles.ViaVersion.api.boss.BossStyle; -import us.myles.ViaVersion.api.protocol.ProtocolRegistry; import java.util.SortedSet; import java.util.UUID; @@ -16,6 +15,14 @@ import java.util.UUID; */ public interface ViaAPI { + /** + * Returns the server's protocol version. + * In the case of a proxy, this is the lowest supported version. + * + * @return the server's protocol version + */ + int getServerVersion(); + /** * Get protocol version number from a player. * Will also retrieve version from ProtocolSupport if it's being used. @@ -38,8 +45,8 @@ public interface ViaAPI { * * @param playerUUID UUID of a player * @return true if Via has a cached userconnection for this player - * @deprecated use {@link #isInjected(UUID)} * @see #isInjected(UUID) + * @deprecated use {@link #isInjected(UUID)} */ @Deprecated default boolean isPorted(UUID playerUUID) { @@ -105,7 +112,14 @@ public interface ViaAPI { * This method removes any blocked protocol versions. * * @return a list of protocol versions - * @see ProtocolRegistry#getSupportedVersions() for full list. + * @see #getFullSupportedVersions() for a full list */ SortedSet getSupportedVersions(); + + /** + * Get the supported protocol versions, including blocked protocols. + * + * @return a list of protocol versions + */ + SortedSet getFullSupportedVersions(); } diff --git a/common/src/main/java/us/myles/ViaVersion/api/ViaVersionConfig.java b/api/src/main/java/us/myles/ViaVersion/api/ViaVersionConfig.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/ViaVersionConfig.java rename to api/src/main/java/us/myles/ViaVersion/api/ViaVersionConfig.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/boss/BossBar.java b/api/src/main/java/us/myles/ViaVersion/api/boss/BossBar.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/boss/BossBar.java rename to api/src/main/java/us/myles/ViaVersion/api/boss/BossBar.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/boss/BossColor.java b/api/src/main/java/us/myles/ViaVersion/api/boss/BossColor.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/boss/BossColor.java rename to api/src/main/java/us/myles/ViaVersion/api/boss/BossColor.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/boss/BossFlag.java b/api/src/main/java/us/myles/ViaVersion/api/boss/BossFlag.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/boss/BossFlag.java rename to api/src/main/java/us/myles/ViaVersion/api/boss/BossFlag.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/boss/BossStyle.java b/api/src/main/java/us/myles/ViaVersion/api/boss/BossStyle.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/boss/BossStyle.java rename to api/src/main/java/us/myles/ViaVersion/api/boss/BossStyle.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/command/ViaCommandSender.java b/api/src/main/java/us/myles/ViaVersion/api/command/ViaCommandSender.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/command/ViaCommandSender.java rename to api/src/main/java/us/myles/ViaVersion/api/command/ViaCommandSender.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/command/ViaSubCommand.java b/api/src/main/java/us/myles/ViaVersion/api/command/ViaSubCommand.java similarity index 68% rename from common/src/main/java/us/myles/ViaVersion/api/command/ViaSubCommand.java rename to api/src/main/java/us/myles/ViaVersion/api/command/ViaSubCommand.java index 900d51955..8ffcf9eef 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/command/ViaSubCommand.java +++ b/api/src/main/java/us/myles/ViaVersion/api/command/ViaSubCommand.java @@ -1,6 +1,6 @@ package us.myles.ViaVersion.api.command; -import us.myles.ViaVersion.commands.ViaCommandHandler; +import us.myles.ViaVersion.util.ChatColorUtil; import java.util.Collections; import java.util.List; @@ -60,18 +60,24 @@ public abstract class ViaSubCommand { return Collections.emptyList(); } - public String color(String s) { - return ViaCommandHandler.color(s); + /** + * Replaces color codes in a string. + * + * @param s string to replace + * @return output String + */ + public static String color(String s) { + return ChatColorUtil.translateAlternateColorCodes(s); } /** - * Send message formatted / colored + * Send a color coded string with replacements to a user. * - * @param sender commands sender - * @param message string message - * @param args optional objects + * @param sender target to send the message to + * @param message message + * @param args objects to replace */ - public void sendMessage(ViaCommandSender sender, String message, Object... args) { - ViaCommandHandler.sendMessage(sender, message, args); + public static void sendMessage(ViaCommandSender sender, String message, Object... args) { + sender.sendMessage(color(args == null ? message : String.format(message, args))); } } diff --git a/common/src/main/java/us/myles/ViaVersion/api/command/ViaVersionCommand.java b/api/src/main/java/us/myles/ViaVersion/api/command/ViaVersionCommand.java similarity index 96% rename from common/src/main/java/us/myles/ViaVersion/api/command/ViaVersionCommand.java rename to api/src/main/java/us/myles/ViaVersion/api/command/ViaVersionCommand.java index 03c931450..ef6e4759b 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/command/ViaVersionCommand.java +++ b/api/src/main/java/us/myles/ViaVersion/api/command/ViaVersionCommand.java @@ -47,4 +47,6 @@ public interface ViaVersionCommand { * @return was successful */ List onTabComplete(ViaCommandSender sender, String[] args); + + void showHelp(ViaCommandSender sender); } diff --git a/common/src/main/java/us/myles/ViaVersion/api/configuration/ConfigurationProvider.java b/api/src/main/java/us/myles/ViaVersion/api/configuration/ConfigurationProvider.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/configuration/ConfigurationProvider.java rename to api/src/main/java/us/myles/ViaVersion/api/configuration/ConfigurationProvider.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/data/ExternalJoinGameListener.java b/api/src/main/java/us/myles/ViaVersion/api/data/ExternalJoinGameListener.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/data/ExternalJoinGameListener.java rename to api/src/main/java/us/myles/ViaVersion/api/data/ExternalJoinGameListener.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/data/MappingData.java b/api/src/main/java/us/myles/ViaVersion/api/data/MappingData.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/data/MappingData.java rename to api/src/main/java/us/myles/ViaVersion/api/data/MappingData.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/data/MappingDataLoader.java b/api/src/main/java/us/myles/ViaVersion/api/data/MappingDataLoader.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/data/MappingDataLoader.java rename to api/src/main/java/us/myles/ViaVersion/api/data/MappingDataLoader.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/data/Mappings.java b/api/src/main/java/us/myles/ViaVersion/api/data/Mappings.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/data/Mappings.java rename to api/src/main/java/us/myles/ViaVersion/api/data/Mappings.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/data/ParticleMappings.java b/api/src/main/java/us/myles/ViaVersion/api/data/ParticleMappings.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/data/ParticleMappings.java rename to api/src/main/java/us/myles/ViaVersion/api/data/ParticleMappings.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/data/StoredObject.java b/api/src/main/java/us/myles/ViaVersion/api/data/StoredObject.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/data/StoredObject.java rename to api/src/main/java/us/myles/ViaVersion/api/data/StoredObject.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/data/UserConnection.java b/api/src/main/java/us/myles/ViaVersion/api/data/UserConnection.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/data/UserConnection.java rename to api/src/main/java/us/myles/ViaVersion/api/data/UserConnection.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/entities/Entity1_10Types.java b/api/src/main/java/us/myles/ViaVersion/api/entities/Entity1_10Types.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/entities/Entity1_10Types.java rename to api/src/main/java/us/myles/ViaVersion/api/entities/Entity1_10Types.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/entities/Entity1_11Types.java b/api/src/main/java/us/myles/ViaVersion/api/entities/Entity1_11Types.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/entities/Entity1_11Types.java rename to api/src/main/java/us/myles/ViaVersion/api/entities/Entity1_11Types.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/entities/Entity1_12Types.java b/api/src/main/java/us/myles/ViaVersion/api/entities/Entity1_12Types.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/entities/Entity1_12Types.java rename to api/src/main/java/us/myles/ViaVersion/api/entities/Entity1_12Types.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/entities/Entity1_13Types.java b/api/src/main/java/us/myles/ViaVersion/api/entities/Entity1_13Types.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/entities/Entity1_13Types.java rename to api/src/main/java/us/myles/ViaVersion/api/entities/Entity1_13Types.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/entities/Entity1_14Types.java b/api/src/main/java/us/myles/ViaVersion/api/entities/Entity1_14Types.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/entities/Entity1_14Types.java rename to api/src/main/java/us/myles/ViaVersion/api/entities/Entity1_14Types.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/entities/Entity1_15Types.java b/api/src/main/java/us/myles/ViaVersion/api/entities/Entity1_15Types.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/entities/Entity1_15Types.java rename to api/src/main/java/us/myles/ViaVersion/api/entities/Entity1_15Types.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/entities/Entity1_16Types.java b/api/src/main/java/us/myles/ViaVersion/api/entities/Entity1_16Types.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/entities/Entity1_16Types.java rename to api/src/main/java/us/myles/ViaVersion/api/entities/Entity1_16Types.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/entities/Entity1_16_2Types.java b/api/src/main/java/us/myles/ViaVersion/api/entities/Entity1_16_2Types.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/entities/Entity1_16_2Types.java rename to api/src/main/java/us/myles/ViaVersion/api/entities/Entity1_16_2Types.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/entities/Entity1_17Types.java b/api/src/main/java/us/myles/ViaVersion/api/entities/Entity1_17Types.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/entities/Entity1_17Types.java rename to api/src/main/java/us/myles/ViaVersion/api/entities/Entity1_17Types.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/entities/EntityType.java b/api/src/main/java/us/myles/ViaVersion/api/entities/EntityType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/entities/EntityType.java rename to api/src/main/java/us/myles/ViaVersion/api/entities/EntityType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/entities/ObjectType.java b/api/src/main/java/us/myles/ViaVersion/api/entities/ObjectType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/entities/ObjectType.java rename to api/src/main/java/us/myles/ViaVersion/api/entities/ObjectType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/BlockChangeRecord.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/BlockChangeRecord.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/BlockChangeRecord.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/BlockChangeRecord.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/BlockChangeRecord1_16_2.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/BlockChangeRecord1_16_2.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/BlockChangeRecord1_16_2.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/BlockChangeRecord1_16_2.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/BlockChangeRecord1_8.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/BlockChangeRecord1_8.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/BlockChangeRecord1_8.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/BlockChangeRecord1_8.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/BlockFace.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/BlockFace.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/BlockFace.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/BlockFace.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/Environment.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/Environment.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/Environment.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/Environment.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/EulerAngle.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/EulerAngle.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/EulerAngle.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/EulerAngle.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/Position.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/Position.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/Position.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/Position.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/Vector.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/Vector.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/Vector.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/Vector.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/VillagerData.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/VillagerData.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/VillagerData.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/VillagerData.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/BaseChunk.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/BaseChunk.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/BaseChunk.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/BaseChunk.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/Chunk.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/Chunk.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/Chunk.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/Chunk.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/Chunk1_8.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/Chunk1_8.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/Chunk1_8.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/Chunk1_8.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/ChunkSection.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/ChunkSection.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/ChunkSection.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/ChunkSection.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/NibbleArray.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/NibbleArray.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/NibbleArray.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/chunks/NibbleArray.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/item/Item.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/item/Item.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/item/Item.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/item/Item.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/MetaType.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/MetaType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/MetaType.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/MetaType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/Metadata.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/Metadata.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/Metadata.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/Metadata.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_12.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_12.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_12.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_12.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_13.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_13.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_13.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_13.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_13_2.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_13_2.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_13_2.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_13_2.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_14.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_14.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_14.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_14.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_17.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_17.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_17.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_17.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_8.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_8.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_8.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_8.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_9.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_9.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_9.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/metadata/types/MetaType1_9.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/BinaryTagIO.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/BinaryTagIO.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/BinaryTagIO.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/BinaryTagIO.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/CharBuffer.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/CharBuffer.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/CharBuffer.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/CharBuffer.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/StringTagParseException.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/StringTagParseException.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/StringTagParseException.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/StringTagParseException.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/TagStringReader.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/TagStringReader.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/TagStringReader.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/TagStringReader.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/TagStringWriter.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/TagStringWriter.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/TagStringWriter.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/TagStringWriter.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/Tokens.java b/api/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/Tokens.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/Tokens.java rename to api/src/main/java/us/myles/ViaVersion/api/minecraft/nbt/Tokens.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/platform/TaskId.java b/api/src/main/java/us/myles/ViaVersion/api/platform/TaskId.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/platform/TaskId.java rename to api/src/main/java/us/myles/ViaVersion/api/platform/TaskId.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/platform/ViaConnectionManager.java b/api/src/main/java/us/myles/ViaVersion/api/platform/ViaConnectionManager.java similarity index 98% rename from common/src/main/java/us/myles/ViaVersion/api/platform/ViaConnectionManager.java rename to api/src/main/java/us/myles/ViaVersion/api/platform/ViaConnectionManager.java index f5ac95aed..156e3b072 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/platform/ViaConnectionManager.java +++ b/api/src/main/java/us/myles/ViaVersion/api/platform/ViaConnectionManager.java @@ -87,7 +87,7 @@ public class ViaConnectionManager { if (conn.getProtocolInfo() == null) return null; UUID uuid = conn.getProtocolInfo().getUuid(); UserConnection client = clients.get(uuid); - if (client != null && client.equals(conn)) { + if (conn.equals(client)) { // This is frontend return uuid; } diff --git a/common/src/main/java/us/myles/ViaVersion/api/platform/ViaInjector.java b/api/src/main/java/us/myles/ViaVersion/api/platform/ViaInjector.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/platform/ViaInjector.java rename to api/src/main/java/us/myles/ViaVersion/api/platform/ViaInjector.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/platform/ViaPlatform.java b/api/src/main/java/us/myles/ViaVersion/api/platform/ViaPlatform.java similarity index 95% rename from common/src/main/java/us/myles/ViaVersion/api/platform/ViaPlatform.java rename to api/src/main/java/us/myles/ViaVersion/api/platform/ViaPlatform.java index 29d4e4993..5e9a73ef4 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/platform/ViaPlatform.java +++ b/api/src/main/java/us/myles/ViaVersion/api/platform/ViaPlatform.java @@ -1,7 +1,6 @@ package us.myles.ViaVersion.api.platform; import com.google.gson.JsonObject; -import us.myles.ViaVersion.api.Via; import us.myles.ViaVersion.api.ViaAPI; import us.myles.ViaVersion.api.ViaVersionConfig; import us.myles.ViaVersion.api.command.ViaCommandSender; @@ -127,8 +126,8 @@ public interface ViaPlatform { /** * Disconnects an UserConnection for a reason * - * @param connection The UserConnection - * @param message The message to kick them with + * @param connection The UserConnection + * @param message The message to kick them with * @return True if it was successful */ default boolean disconnect(UserConnection connection, String message) { @@ -194,5 +193,10 @@ public interface ViaPlatform { */ boolean isOldClientsAllowed(); + /** + * Returns the connection manager holding and managing user connections. + * + * @return connection manager + */ ViaConnectionManager getConnectionManager(); } diff --git a/common/src/main/java/us/myles/ViaVersion/api/platform/ViaPlatformLoader.java b/api/src/main/java/us/myles/ViaVersion/api/platform/ViaPlatformLoader.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/platform/ViaPlatformLoader.java rename to api/src/main/java/us/myles/ViaVersion/api/platform/ViaPlatformLoader.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/platform/providers/Provider.java b/api/src/main/java/us/myles/ViaVersion/api/platform/providers/Provider.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/platform/providers/Provider.java rename to api/src/main/java/us/myles/ViaVersion/api/platform/providers/Provider.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/platform/providers/ViaProviders.java b/api/src/main/java/us/myles/ViaVersion/api/platform/providers/ViaProviders.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/platform/providers/ViaProviders.java rename to api/src/main/java/us/myles/ViaVersion/api/platform/providers/ViaProviders.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/protocol/ClientboundPacketType.java b/api/src/main/java/us/myles/ViaVersion/api/protocol/ClientboundPacketType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/protocol/ClientboundPacketType.java rename to api/src/main/java/us/myles/ViaVersion/api/protocol/ClientboundPacketType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/protocol/PacketType.java b/api/src/main/java/us/myles/ViaVersion/api/protocol/PacketType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/protocol/PacketType.java rename to api/src/main/java/us/myles/ViaVersion/api/protocol/PacketType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/protocol/Protocol.java b/api/src/main/java/us/myles/ViaVersion/api/protocol/Protocol.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/protocol/Protocol.java rename to api/src/main/java/us/myles/ViaVersion/api/protocol/Protocol.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/protocol/ProtocolPipeline.java b/api/src/main/java/us/myles/ViaVersion/api/protocol/ProtocolPipeline.java similarity index 96% rename from common/src/main/java/us/myles/ViaVersion/api/protocol/ProtocolPipeline.java rename to api/src/main/java/us/myles/ViaVersion/api/protocol/ProtocolPipeline.java index 8e4473599..5a492a6ae 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/protocol/ProtocolPipeline.java +++ b/api/src/main/java/us/myles/ViaVersion/api/protocol/ProtocolPipeline.java @@ -25,7 +25,7 @@ public class ProtocolPipeline extends SimpleProtocol { protected void registerPackets() { protocolList = new CopyOnWriteArrayList<>(); // This is a pipeline so we register basic pipes - protocolList.add(ProtocolRegistry.BASE_PROTOCOL); + protocolList.add(Via.getManager().getBaseProtocol()); } @Override @@ -56,7 +56,7 @@ public class ProtocolPipeline extends SimpleProtocol { // Move base Protocols to the end, so the login packets can be modified by other protocols List toMove = new ArrayList<>(); for (Protocol p : protocolList) { - if (ProtocolRegistry.isBaseProtocol(p)) { + if (Via.getManager().isBaseProtocol(p)) { toMove.add(p); } } @@ -146,8 +146,8 @@ public class ProtocolPipeline extends SimpleProtocol { } /** - * Cleans the pipe and adds {@link us.myles.ViaVersion.protocols.base.BaseProtocol} - * /!\ WARNING - It doesn't add version-specific base Protocol + * Cleans the pipe and adds the base protocol. + * /!\ WARNING - It doesn't add version-specific base Protocol. */ public void cleanPipes() { pipes().clear(); diff --git a/common/src/main/java/us/myles/ViaVersion/api/protocol/ProtocolVersion.java b/api/src/main/java/us/myles/ViaVersion/api/protocol/ProtocolVersion.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/protocol/ProtocolVersion.java rename to api/src/main/java/us/myles/ViaVersion/api/protocol/ProtocolVersion.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/protocol/ServerboundPacketType.java b/api/src/main/java/us/myles/ViaVersion/api/protocol/ServerboundPacketType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/protocol/ServerboundPacketType.java rename to api/src/main/java/us/myles/ViaVersion/api/protocol/ServerboundPacketType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/protocol/SimpleProtocol.java b/api/src/main/java/us/myles/ViaVersion/api/protocol/SimpleProtocol.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/protocol/SimpleProtocol.java rename to api/src/main/java/us/myles/ViaVersion/api/protocol/SimpleProtocol.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/protocol/VersionRange.java b/api/src/main/java/us/myles/ViaVersion/api/protocol/VersionRange.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/protocol/VersionRange.java rename to api/src/main/java/us/myles/ViaVersion/api/protocol/VersionRange.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/remapper/PacketHandler.java b/api/src/main/java/us/myles/ViaVersion/api/remapper/PacketHandler.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/remapper/PacketHandler.java rename to api/src/main/java/us/myles/ViaVersion/api/remapper/PacketHandler.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/remapper/PacketRemapper.java b/api/src/main/java/us/myles/ViaVersion/api/remapper/PacketRemapper.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/remapper/PacketRemapper.java rename to api/src/main/java/us/myles/ViaVersion/api/remapper/PacketRemapper.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/remapper/TypeRemapper.java b/api/src/main/java/us/myles/ViaVersion/api/remapper/TypeRemapper.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/remapper/TypeRemapper.java rename to api/src/main/java/us/myles/ViaVersion/api/remapper/TypeRemapper.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/remapper/ValueCreator.java b/api/src/main/java/us/myles/ViaVersion/api/remapper/ValueCreator.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/remapper/ValueCreator.java rename to api/src/main/java/us/myles/ViaVersion/api/remapper/ValueCreator.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/remapper/ValueReader.java b/api/src/main/java/us/myles/ViaVersion/api/remapper/ValueReader.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/remapper/ValueReader.java rename to api/src/main/java/us/myles/ViaVersion/api/remapper/ValueReader.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/remapper/ValueTransformer.java b/api/src/main/java/us/myles/ViaVersion/api/remapper/ValueTransformer.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/remapper/ValueTransformer.java rename to api/src/main/java/us/myles/ViaVersion/api/remapper/ValueTransformer.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/remapper/ValueWriter.java b/api/src/main/java/us/myles/ViaVersion/api/remapper/ValueWriter.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/remapper/ValueWriter.java rename to api/src/main/java/us/myles/ViaVersion/api/remapper/ValueWriter.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/ByteBufReader.java b/api/src/main/java/us/myles/ViaVersion/api/type/ByteBufReader.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/ByteBufReader.java rename to api/src/main/java/us/myles/ViaVersion/api/type/ByteBufReader.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/ByteBufWriter.java b/api/src/main/java/us/myles/ViaVersion/api/type/ByteBufWriter.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/ByteBufWriter.java rename to api/src/main/java/us/myles/ViaVersion/api/type/ByteBufWriter.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/PartialType.java b/api/src/main/java/us/myles/ViaVersion/api/type/PartialType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/PartialType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/PartialType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/TypeConverter.java b/api/src/main/java/us/myles/ViaVersion/api/type/TypeConverter.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/TypeConverter.java rename to api/src/main/java/us/myles/ViaVersion/api/type/TypeConverter.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/ArrayType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/ArrayType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/ArrayType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/ArrayType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/BooleanType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/BooleanType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/BooleanType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/BooleanType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/ByteArrayType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/ByteArrayType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/ByteArrayType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/ByteArrayType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/ByteType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/ByteType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/ByteType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/ByteType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/ComponentType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/ComponentType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/ComponentType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/ComponentType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/CustomByteType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/CustomByteType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/CustomByteType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/CustomByteType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/DoubleType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/DoubleType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/DoubleType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/DoubleType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/FloatType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/FloatType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/FloatType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/FloatType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/IntType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/IntType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/IntType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/IntType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/LongArrayType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/LongArrayType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/LongArrayType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/LongArrayType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/LongType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/LongType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/LongType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/LongType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/Particle.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/Particle.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/Particle.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/Particle.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/RemainingBytesType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/RemainingBytesType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/RemainingBytesType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/RemainingBytesType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/ShortType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/ShortType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/ShortType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/ShortType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/StringType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/StringType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/StringType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/StringType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/UUIDIntArrayType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/UUIDIntArrayType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/UUIDIntArrayType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/UUIDIntArrayType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/UUIDType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/UUIDType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/UUIDType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/UUIDType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/UnsignedByteType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/UnsignedByteType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/UnsignedByteType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/UnsignedByteType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/UnsignedShortType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/UnsignedShortType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/UnsignedShortType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/UnsignedShortType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/VarIntArrayType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/VarIntArrayType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/VarIntArrayType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/VarIntArrayType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/VarIntType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/VarIntType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/VarIntType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/VarIntType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/VarLongType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/VarLongType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/VarLongType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/VarLongType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/VoidType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/VoidType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/VoidType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/VoidType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/AbstractMetaListType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/AbstractMetaListType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/AbstractMetaListType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/AbstractMetaListType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/BaseChunkType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/BaseChunkType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/BaseChunkType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/BaseChunkType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/BaseItemArrayType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/BaseItemArrayType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/BaseItemArrayType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/BaseItemArrayType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/BaseItemType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/BaseItemType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/BaseItemType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/BaseItemType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/BlockChangeRecordType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/BlockChangeRecordType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/BlockChangeRecordType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/BlockChangeRecordType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/EulerAngleType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/EulerAngleType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/EulerAngleType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/EulerAngleType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatItemArrayType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatItemArrayType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatItemArrayType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatItemArrayType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatItemType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatItemType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatItemType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatItemType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatVarIntItemArrayType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatVarIntItemArrayType.java similarity index 68% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatVarIntItemArrayType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatVarIntItemArrayType.java index 7c882824d..1ef8db71b 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatVarIntItemArrayType.java +++ b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatVarIntItemArrayType.java @@ -2,7 +2,6 @@ package us.myles.ViaVersion.api.type.types.minecraft; import io.netty.buffer.ByteBuf; import us.myles.ViaVersion.api.minecraft.item.Item; -import us.myles.ViaVersion.api.type.Type; public class FlatVarIntItemArrayType extends BaseItemArrayType { @@ -12,19 +11,19 @@ public class FlatVarIntItemArrayType extends BaseItemArrayType { @Override public Item[] read(ByteBuf buffer) throws Exception { - int amount = Type.SHORT.readPrimitive(buffer); + int amount = SHORT.readPrimitive(buffer); Item[] array = new Item[amount]; for (int i = 0; i < amount; i++) { - array[i] = Type.FLAT_VAR_INT_ITEM.read(buffer); + array[i] = FLAT_VAR_INT_ITEM.read(buffer); } return array; } @Override public void write(ByteBuf buffer, Item[] object) throws Exception { - Type.SHORT.writePrimitive(buffer, (short) object.length); + SHORT.writePrimitive(buffer, (short) object.length); for (Item o : object) { - Type.FLAT_VAR_INT_ITEM.write(buffer, o); + FLAT_VAR_INT_ITEM.write(buffer, o); } } } \ No newline at end of file diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatVarIntItemType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatVarIntItemType.java similarity index 75% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatVarIntItemType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatVarIntItemType.java index c31efc3dd..ebfb4a330 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatVarIntItemType.java +++ b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/FlatVarIntItemType.java @@ -2,7 +2,6 @@ package us.myles.ViaVersion.api.type.types.minecraft; import io.netty.buffer.ByteBuf; import us.myles.ViaVersion.api.minecraft.item.Item; -import us.myles.ViaVersion.api.type.Type; public class FlatVarIntItemType extends BaseItemType { public FlatVarIntItemType() { @@ -16,9 +15,9 @@ public class FlatVarIntItemType extends BaseItemType { return null; } else { Item item = new Item(); - item.setIdentifier(Type.VAR_INT.readPrimitive(buffer)); + item.setIdentifier(VAR_INT.readPrimitive(buffer)); item.setAmount(buffer.readByte()); - item.setTag(Type.NBT.read(buffer)); + item.setTag(NBT.read(buffer)); return item; } } @@ -29,9 +28,9 @@ public class FlatVarIntItemType extends BaseItemType { buffer.writeBoolean(false); } else { buffer.writeBoolean(true); - Type.VAR_INT.writePrimitive(buffer, object.getIdentifier()); + VAR_INT.writePrimitive(buffer, object.getIdentifier()); buffer.writeByte(object.getAmount()); - Type.NBT.write(buffer, object.getTag()); + NBT.write(buffer, object.getTag()); } } } diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ItemArrayType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ItemArrayType.java similarity index 70% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ItemArrayType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ItemArrayType.java index 2176e9a01..cdb8ec1d6 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ItemArrayType.java +++ b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ItemArrayType.java @@ -2,7 +2,6 @@ package us.myles.ViaVersion.api.type.types.minecraft; import io.netty.buffer.ByteBuf; import us.myles.ViaVersion.api.minecraft.item.Item; -import us.myles.ViaVersion.api.type.Type; public class ItemArrayType extends BaseItemArrayType { @@ -12,19 +11,19 @@ public class ItemArrayType extends BaseItemArrayType { @Override public Item[] read(ByteBuf buffer) throws Exception { - int amount = Type.SHORT.readPrimitive(buffer); + int amount = SHORT.readPrimitive(buffer); Item[] array = new Item[amount]; for (int i = 0; i < amount; i++) { - array[i] = Type.ITEM.read(buffer); + array[i] = ITEM.read(buffer); } return array; } @Override public void write(ByteBuf buffer, Item[] object) throws Exception { - Type.SHORT.writePrimitive(buffer, (short) object.length); + SHORT.writePrimitive(buffer, (short) object.length); for (Item o : object) { - Type.ITEM.write(buffer, o); + ITEM.write(buffer, o); } } } \ No newline at end of file diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ItemType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ItemType.java similarity index 87% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ItemType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ItemType.java index 67a962ff2..4f2d43efd 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ItemType.java +++ b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ItemType.java @@ -2,7 +2,6 @@ package us.myles.ViaVersion.api.type.types.minecraft; import io.netty.buffer.ByteBuf; import us.myles.ViaVersion.api.minecraft.item.Item; -import us.myles.ViaVersion.api.type.Type; public class ItemType extends BaseItemType { public ItemType() { @@ -19,7 +18,7 @@ public class ItemType extends BaseItemType { item.setIdentifier(id); item.setAmount(buffer.readByte()); item.setData(buffer.readShort()); - item.setTag(Type.NBT.read(buffer)); + item.setTag(NBT.read(buffer)); return item; } } @@ -32,7 +31,7 @@ public class ItemType extends BaseItemType { buffer.writeShort(object.getIdentifier()); buffer.writeByte(object.getAmount()); buffer.writeShort(object.getData()); - Type.NBT.write(buffer, object.getTag()); + NBT.write(buffer, object.getTag()); } } } diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/MetaListTypeTemplate.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/MetaListTypeTemplate.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/MetaListTypeTemplate.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/MetaListTypeTemplate.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/MetaTypeTemplate.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/MetaTypeTemplate.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/MetaTypeTemplate.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/MetaTypeTemplate.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ModernMetaListType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ModernMetaListType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ModernMetaListType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ModernMetaListType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ModernMetaType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ModernMetaType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ModernMetaType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/ModernMetaType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/NBTType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/NBTType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/NBTType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/NBTType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptPosition1_14Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptPosition1_14Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptPosition1_14Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptPosition1_14Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptPositionType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptPositionType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptPositionType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptPositionType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptUUIDType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptUUIDType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptUUIDType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptUUIDType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptionalComponentType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptionalComponentType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptionalComponentType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptionalComponentType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptionalVarIntType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptionalVarIntType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptionalVarIntType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/OptionalVarIntType.java diff --git a/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/Particle1_13Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/Particle1_13Type.java new file mode 100644 index 000000000..828e3d4b0 --- /dev/null +++ b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/Particle1_13Type.java @@ -0,0 +1,45 @@ +package us.myles.ViaVersion.api.type.types.minecraft; + +import io.netty.buffer.ByteBuf; +import us.myles.ViaVersion.api.type.Type; +import us.myles.ViaVersion.api.type.types.Particle; + +public class Particle1_13Type extends Type { + + public Particle1_13Type() { + super("Particle", Particle.class); + } + + @Override + public void write(ByteBuf buffer, Particle object) throws Exception { + Type.VAR_INT.writePrimitive(buffer, object.getId()); + for (Particle.ParticleData data : object.getArguments()) + data.getType().write(buffer, data.getValue()); + } + + @Override + public Particle read(ByteBuf buffer) throws Exception { + int type = Type.VAR_INT.readPrimitive(buffer); + Particle particle = new Particle(type); + + switch (type) { + // Block / Falling Dust / + case 3: + case 20: + particle.getArguments().add(new Particle.ParticleData(Type.VAR_INT, Type.VAR_INT.readPrimitive(buffer))); // Flat Block + break; + // Dust + case 11: + particle.getArguments().add(new Particle.ParticleData(Type.FLOAT, Type.FLOAT.readPrimitive(buffer))); // Red 0 - 1 + particle.getArguments().add(new Particle.ParticleData(Type.FLOAT, Type.FLOAT.readPrimitive(buffer))); // Green 0 - 1 + particle.getArguments().add(new Particle.ParticleData(Type.FLOAT, Type.FLOAT.readPrimitive(buffer))); // Blue 0 - 1 + particle.getArguments().add(new Particle.ParticleData(Type.FLOAT, Type.FLOAT.readPrimitive(buffer)));// Scale 0.01 - 4 + break; + // Item + case 27: + particle.getArguments().add(new Particle.ParticleData(Type.FLAT_ITEM, Type.FLAT_ITEM.read(buffer))); // Flat item + break; + } + return particle; + } +} diff --git a/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/Particle1_13_2Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/Particle1_13_2Type.java new file mode 100644 index 000000000..18c752a15 --- /dev/null +++ b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/Particle1_13_2Type.java @@ -0,0 +1,45 @@ +package us.myles.ViaVersion.api.type.types.minecraft; + +import io.netty.buffer.ByteBuf; +import us.myles.ViaVersion.api.type.Type; +import us.myles.ViaVersion.api.type.types.Particle; + +public class Particle1_13_2Type extends Type { + + public Particle1_13_2Type() { + super("Particle", Particle.class); + } + + @Override + public void write(ByteBuf buffer, Particle object) throws Exception { + Type.VAR_INT.writePrimitive(buffer, object.getId()); + for (Particle.ParticleData data : object.getArguments()) + data.getType().write(buffer, data.getValue()); + } + + @Override + public Particle read(ByteBuf buffer) throws Exception { + int type = Type.VAR_INT.readPrimitive(buffer); + Particle particle = new Particle(type); + + switch (type) { + // Block / Falling Dust / + case 3: + case 20: + particle.getArguments().add(new Particle.ParticleData(Type.VAR_INT, Type.VAR_INT.readPrimitive(buffer))); // Flat Block + break; + // Dust + case 11: + particle.getArguments().add(new Particle.ParticleData(Type.FLOAT, Type.FLOAT.readPrimitive(buffer))); // Red 0 - 1 + particle.getArguments().add(new Particle.ParticleData(Type.FLOAT, Type.FLOAT.readPrimitive(buffer))); // Green 0 - 1 + particle.getArguments().add(new Particle.ParticleData(Type.FLOAT, Type.FLOAT.readPrimitive(buffer))); // Blue 0 - 1 + particle.getArguments().add(new Particle.ParticleData(Type.FLOAT, Type.FLOAT.readPrimitive(buffer)));// Scale 0.01 - 4 + break; + // Item + case 27: + particle.getArguments().add(new Particle.ParticleData(Type.FLAT_VAR_INT_ITEM, Type.FLAT_VAR_INT_ITEM.read(buffer))); // Flat item + break; + } + return particle; + } +} diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/Particle1_14Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/Particle1_14Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/Particle1_14Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/Particle1_14Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/Particle1_17Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/Particle1_17Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/Particle1_17Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/Particle1_17Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/Position1_14Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/Position1_14Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/Position1_14Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/Position1_14Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/PositionType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/PositionType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/PositionType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/PositionType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/VarLongBlockChangeRecordType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/VarLongBlockChangeRecordType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/VarLongBlockChangeRecordType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/VarLongBlockChangeRecordType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/VectorType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/VectorType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/VectorType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/VectorType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/VillagerDataType.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/VillagerDataType.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/VillagerDataType.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/minecraft/VillagerDataType.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/ChunkSectionType1_13.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/ChunkSectionType1_13.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/ChunkSectionType1_13.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/ChunkSectionType1_13.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/ChunkSectionType1_16.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/ChunkSectionType1_16.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/ChunkSectionType1_16.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/ChunkSectionType1_16.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/ChunkSectionType1_8.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/ChunkSectionType1_8.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/ChunkSectionType1_8.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/ChunkSectionType1_8.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/ChunkSectionType1_9.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/ChunkSectionType1_9.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/ChunkSectionType1_9.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/ChunkSectionType1_9.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_12Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_12Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_12Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_12Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_13Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_13Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_13Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_13Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_13_2Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_13_2Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_13_2Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_13_2Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_14Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_14Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_14Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_14Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_17Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_17Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_17Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_17Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_8Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_8Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_8Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_8Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_9Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_9Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_9Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/Metadata1_9Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_12Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_12Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_12Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_12Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_13Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_13Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_13Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_13Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_13_2Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_13_2Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_13_2Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_13_2Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_14Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_14Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_14Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_14Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_17Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_17Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_17Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_17Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_8Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_8Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_8Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_8Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_9Type.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_9Type.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_9Type.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/MetadataList1_9Type.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_12.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_12.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_12.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_12.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_13.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_13.java similarity index 90% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_13.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_13.java index 12c9d854d..8ba54f191 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_13.java +++ b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_13.java @@ -4,7 +4,7 @@ import us.myles.ViaVersion.api.minecraft.chunks.ChunkSection; import us.myles.ViaVersion.api.minecraft.metadata.Metadata; import us.myles.ViaVersion.api.type.Type; import us.myles.ViaVersion.api.type.types.Particle; -import us.myles.ViaVersion.protocols.protocol1_13to1_12_2.types.Particle1_13Type; +import us.myles.ViaVersion.api.type.types.minecraft.Particle1_13Type; import java.util.List; diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_13_2.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_13_2.java similarity index 78% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_13_2.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_13_2.java index 912ac6c95..c498ec618 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_13_2.java +++ b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_13_2.java @@ -3,7 +3,7 @@ package us.myles.ViaVersion.api.type.types.version; import us.myles.ViaVersion.api.minecraft.metadata.Metadata; import us.myles.ViaVersion.api.type.Type; import us.myles.ViaVersion.api.type.types.Particle; -import us.myles.ViaVersion.protocols.protocol1_13_2to1_13_1.types.Particle1_13_2Type; +import us.myles.ViaVersion.api.type.types.minecraft.Particle1_13_2Type; import java.util.List; @@ -21,5 +21,5 @@ public class Types1_13_2 { /** * Particle type for 1.13.2 */ - public static Type PARTICLE = new Particle1_13_2Type(); + public static final Type PARTICLE = new Particle1_13_2Type(); } diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_14.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_14.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_14.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_14.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_16.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_16.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_16.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_16.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_17.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_17.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_17.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_17.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_8.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_8.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_8.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_8.java diff --git a/common/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_9.java b/api/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_9.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_9.java rename to api/src/main/java/us/myles/ViaVersion/api/type/types/version/Types1_9.java diff --git a/common/src/main/java/us/myles/ViaVersion/exception/CancelCodecException.java b/api/src/main/java/us/myles/ViaVersion/exception/CancelCodecException.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/exception/CancelCodecException.java rename to api/src/main/java/us/myles/ViaVersion/exception/CancelCodecException.java diff --git a/common/src/main/java/us/myles/ViaVersion/exception/CancelDecoderException.java b/api/src/main/java/us/myles/ViaVersion/exception/CancelDecoderException.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/exception/CancelDecoderException.java rename to api/src/main/java/us/myles/ViaVersion/exception/CancelDecoderException.java diff --git a/common/src/main/java/us/myles/ViaVersion/exception/CancelEncoderException.java b/api/src/main/java/us/myles/ViaVersion/exception/CancelEncoderException.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/exception/CancelEncoderException.java rename to api/src/main/java/us/myles/ViaVersion/exception/CancelEncoderException.java diff --git a/common/src/main/java/us/myles/ViaVersion/exception/CancelException.java b/api/src/main/java/us/myles/ViaVersion/exception/CancelException.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/exception/CancelException.java rename to api/src/main/java/us/myles/ViaVersion/exception/CancelException.java diff --git a/common/src/main/java/us/myles/ViaVersion/exception/InformativeException.java b/api/src/main/java/us/myles/ViaVersion/exception/InformativeException.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/exception/InformativeException.java rename to api/src/main/java/us/myles/ViaVersion/exception/InformativeException.java diff --git a/common/src/main/java/us/myles/ViaVersion/packets/Direction.java b/api/src/main/java/us/myles/ViaVersion/packets/Direction.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/packets/Direction.java rename to api/src/main/java/us/myles/ViaVersion/packets/Direction.java diff --git a/common/src/main/java/us/myles/ViaVersion/packets/State.java b/api/src/main/java/us/myles/ViaVersion/packets/State.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/packets/State.java rename to api/src/main/java/us/myles/ViaVersion/packets/State.java diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/base/ProtocolInfo.java b/api/src/main/java/us/myles/ViaVersion/protocols/base/ProtocolInfo.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/protocols/base/ProtocolInfo.java rename to api/src/main/java/us/myles/ViaVersion/protocols/base/ProtocolInfo.java diff --git a/api/src/main/java/us/myles/ViaVersion/protocols/base/VersionProvider.java b/api/src/main/java/us/myles/ViaVersion/protocols/base/VersionProvider.java new file mode 100644 index 000000000..3cfb307f9 --- /dev/null +++ b/api/src/main/java/us/myles/ViaVersion/protocols/base/VersionProvider.java @@ -0,0 +1,9 @@ +package us.myles.ViaVersion.protocols.base; + +import us.myles.ViaVersion.api.data.UserConnection; +import us.myles.ViaVersion.api.platform.providers.Provider; + +public interface VersionProvider extends Provider { + + int getServerProtocol(UserConnection connection) throws Exception; +} diff --git a/common/src/main/java/us/myles/ViaVersion/util/BiIntConsumer.java b/api/src/main/java/us/myles/ViaVersion/util/BiIntConsumer.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/util/BiIntConsumer.java rename to api/src/main/java/us/myles/ViaVersion/util/BiIntConsumer.java diff --git a/common/src/main/java/us/myles/ViaVersion/util/ChatColorUtil.java b/api/src/main/java/us/myles/ViaVersion/util/ChatColorUtil.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/util/ChatColorUtil.java rename to api/src/main/java/us/myles/ViaVersion/util/ChatColorUtil.java diff --git a/common/src/main/java/us/myles/ViaVersion/util/CompactArrayUtil.java b/api/src/main/java/us/myles/ViaVersion/util/CompactArrayUtil.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/util/CompactArrayUtil.java rename to api/src/main/java/us/myles/ViaVersion/util/CompactArrayUtil.java diff --git a/common/src/main/java/us/myles/ViaVersion/util/EntityTypeUtil.java b/api/src/main/java/us/myles/ViaVersion/util/EntityTypeUtil.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/util/EntityTypeUtil.java rename to api/src/main/java/us/myles/ViaVersion/util/EntityTypeUtil.java diff --git a/common/src/main/java/us/myles/ViaVersion/util/GsonUtil.java b/api/src/main/java/us/myles/ViaVersion/util/GsonUtil.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/util/GsonUtil.java rename to api/src/main/java/us/myles/ViaVersion/util/GsonUtil.java diff --git a/common/src/main/java/us/myles/ViaVersion/util/Int2IntBiMap.java b/api/src/main/java/us/myles/ViaVersion/util/Int2IntBiMap.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/util/Int2IntBiMap.java rename to api/src/main/java/us/myles/ViaVersion/util/Int2IntBiMap.java diff --git a/common/src/main/java/us/myles/ViaVersion/util/PipelineUtil.java b/api/src/main/java/us/myles/ViaVersion/util/PipelineUtil.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/util/PipelineUtil.java rename to api/src/main/java/us/myles/ViaVersion/util/PipelineUtil.java diff --git a/common/src/main/java/us/myles/ViaVersion/util/VersionInfo.java b/api/src/main/java/us/myles/ViaVersion/util/VersionInfo.java similarity index 100% rename from common/src/main/java/us/myles/ViaVersion/util/VersionInfo.java rename to api/src/main/java/us/myles/ViaVersion/util/VersionInfo.java diff --git a/build.gradle.kts b/build.gradle.kts index b5f612315..28a722ecf 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -40,8 +40,9 @@ subprojects { ).map { "viaversion-$it" } if (platforms.contains(project.name)) { configureShadowJar() - } - if (project.name == "viaversion") { + } else if (project.name == "viaversion-api") { + configureShadowJarAPI() + } else if (project.name == "viaversion") { apply() } diff --git a/buildSrc/src/main/kotlin/extensions.kt b/buildSrc/src/main/kotlin/extensions.kt index 68d80b984..255f003af 100644 --- a/buildSrc/src/main/kotlin/extensions.kt +++ b/buildSrc/src/main/kotlin/extensions.kt @@ -7,6 +7,25 @@ import org.gradle.kotlin.dsl.invoke import org.gradle.kotlin.dsl.withType import java.io.ByteArrayOutputStream +fun Project.configureShadowJarAPI() { + apply() + tasks { + withType { + archiveClassifier.set("") + configureRelocations() + configureExcludes() + } + getByName("build") { + dependsOn(withType()) + } + withType { + if (name == "jar") { + archiveClassifier.set("unshaded") + } + } + } +} + fun Project.configureShadowJar() { apply() tasks { @@ -24,7 +43,7 @@ fun Project.configureShadowJar() { if (name == "jar") { archiveClassifier.set("unshaded") } - from(project.parent!!.file("LICENSE.txt")) { + from(project.parent!!.file("LICENSE")) { into("") } } diff --git a/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/ViaBukkitListener.java b/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/ViaBukkitListener.java index 33d245c87..be4ff99a8 100644 --- a/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/ViaBukkitListener.java +++ b/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/ViaBukkitListener.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.listeners; import org.bukkit.entity.Player; diff --git a/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/ArmorListener.java b/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/ArmorListener.java index 19aecfd04..2b0b88095 100644 --- a/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/ArmorListener.java +++ b/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/ArmorListener.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.listeners.protocol1_9to1_8; import org.bukkit.Bukkit; diff --git a/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/BlockListener.java b/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/BlockListener.java index 51212c4ab..96d22554a 100644 --- a/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/BlockListener.java +++ b/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/BlockListener.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.listeners.protocol1_9to1_8; import org.bukkit.block.Block; diff --git a/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/DeathListener.java b/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/DeathListener.java index 75df92843..a5b63f4f9 100644 --- a/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/DeathListener.java +++ b/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/DeathListener.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.listeners.protocol1_9to1_8; import org.bukkit.World; diff --git a/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/HandItemCache.java b/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/HandItemCache.java index 11603c003..e4c808199 100644 --- a/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/HandItemCache.java +++ b/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/HandItemCache.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.listeners.protocol1_9to1_8; import org.bukkit.Bukkit; diff --git a/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/PaperPatch.java b/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/PaperPatch.java index 7281ed60f..abd7f9240 100644 --- a/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/PaperPatch.java +++ b/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_9to1_8/PaperPatch.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.listeners.protocol1_9to1_8; import org.bukkit.Location; diff --git a/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/providers/BukkitBlockConnectionProvider.java b/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/providers/BukkitBlockConnectionProvider.java index 70837cd83..2aac74264 100644 --- a/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/providers/BukkitBlockConnectionProvider.java +++ b/bukkit-legacy/src/main/java/us/myles/ViaVersion/bukkit/providers/BukkitBlockConnectionProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.providers; import org.bukkit.Bukkit; @@ -7,7 +24,6 @@ import org.bukkit.block.Block; import org.bukkit.entity.Player; import us.myles.ViaVersion.api.data.UserConnection; import us.myles.ViaVersion.api.minecraft.Position; -import us.myles.ViaVersion.protocols.base.ProtocolInfo; import us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections.providers.BlockConnectionProvider; import java.util.UUID; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/ViaVersionPlugin.java b/bukkit/src/main/java/us/myles/ViaVersion/ViaVersionPlugin.java index d05c19ced..02621f75e 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/ViaVersionPlugin.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/ViaVersionPlugin.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion; import com.google.gson.JsonObject; @@ -53,7 +70,7 @@ public class ViaVersionPlugin extends JavaPlugin implements ViaPlatform // Init platform BukkitViaInjector injector = new BukkitViaInjector(); - Via.init(ViaManager.builder() + Via.init(ViaManagerImpl.builder() .platform(this) .commandHandler(commandHandler) .injector(injector) @@ -106,14 +123,14 @@ public class ViaVersionPlugin extends JavaPlugin implements ViaPlatform getLogger().info("ViaVersion " + getDescription().getVersion() + (compatSpigotBuild ? "compat" : "") + " is now loaded" + (lateBind ? ", waiting for boot. (late-bind)" : ", injecting!")); if (!lateBind) { - Via.getManager().init(); + ((ViaManagerImpl) Via.getManager()).init(); } } @Override public void onEnable() { if (lateBind) { - Via.getManager().init(); + ((ViaManagerImpl) Via.getManager()).init(); } getCommand("viaversion").setExecutor(commandHandler); @@ -141,7 +158,7 @@ public class ViaVersionPlugin extends JavaPlugin implements ViaPlatform @Override public void onDisable() { - Via.getManager().destroy(); + ((ViaManagerImpl) Via.getManager()).destroy(); } @Override diff --git a/bukkit/src/main/java/us/myles/ViaVersion/boss/ViaBossBar.java b/bukkit/src/main/java/us/myles/ViaVersion/boss/ViaBossBar.java index 5314b93a6..16a98422d 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/boss/ViaBossBar.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/boss/ViaBossBar.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.boss; import org.bukkit.entity.Player; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/classgenerator/BasicHandlerConstructor.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/classgenerator/BasicHandlerConstructor.java index d7908de01..d7f653560 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/classgenerator/BasicHandlerConstructor.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/classgenerator/BasicHandlerConstructor.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.classgenerator; import io.netty.handler.codec.ByteToMessageDecoder; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/classgenerator/ClassGenerator.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/classgenerator/ClassGenerator.java index ecd17a0ee..b368d00bd 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/classgenerator/ClassGenerator.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/classgenerator/ClassGenerator.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.classgenerator; import javassist.*; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/classgenerator/HandlerConstructor.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/classgenerator/HandlerConstructor.java index ab16e9967..688898561 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/classgenerator/HandlerConstructor.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/classgenerator/HandlerConstructor.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.classgenerator; import io.netty.handler.codec.ByteToMessageDecoder; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/commands/BukkitCommandHandler.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/commands/BukkitCommandHandler.java index 11bf9771f..93c2f1c1f 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/commands/BukkitCommandHandler.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/commands/BukkitCommandHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.commands; import org.bukkit.command.Command; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/commands/BukkitCommandSender.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/commands/BukkitCommandSender.java index 6eca4a5cf..29f2bd6e6 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/commands/BukkitCommandSender.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/commands/BukkitCommandSender.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.commands; import org.bukkit.command.CommandSender; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/handlers/BukkitChannelInitializer.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/handlers/BukkitChannelInitializer.java index a4529ad3a..8d68215f6 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/handlers/BukkitChannelInitializer.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/handlers/BukkitChannelInitializer.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.handlers; import io.netty.channel.Channel; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/handlers/BukkitDecodeHandler.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/handlers/BukkitDecodeHandler.java index 3930581f9..15696f2d9 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/handlers/BukkitDecodeHandler.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/handlers/BukkitDecodeHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.handlers; import io.netty.buffer.ByteBuf; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/handlers/BukkitEncodeHandler.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/handlers/BukkitEncodeHandler.java index 4ab8efb3b..cee0aa6dc 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/handlers/BukkitEncodeHandler.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/handlers/BukkitEncodeHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.handlers; import io.netty.buffer.ByteBuf; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/handlers/BukkitPacketHandler.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/handlers/BukkitPacketHandler.java index 44d94f6ba..fcf99ead2 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/handlers/BukkitPacketHandler.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/handlers/BukkitPacketHandler.java @@ -1,10 +1,26 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.handlers; import io.netty.buffer.ByteBuf; import io.netty.channel.ChannelHandlerContext; import io.netty.handler.codec.MessageToMessageEncoder; import us.myles.ViaVersion.api.data.UserConnection; -import us.myles.ViaVersion.protocols.base.ProtocolInfo; import java.util.List; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/listeners/ProtocolLibEnableListener.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/listeners/ProtocolLibEnableListener.java index fb9cc395d..2a55bfe1b 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/listeners/ProtocolLibEnableListener.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/listeners/ProtocolLibEnableListener.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.listeners; import org.bukkit.event.EventHandler; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/listeners/UpdateListener.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/listeners/UpdateListener.java index 3d7f74eb9..bf1171efe 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/listeners/UpdateListener.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/listeners/UpdateListener.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.listeners; import org.bukkit.event.EventHandler; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/listeners/multiversion/PlayerSneakListener.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/listeners/multiversion/PlayerSneakListener.java index f457fadb7..376bb0276 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/listeners/multiversion/PlayerSneakListener.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/listeners/multiversion/PlayerSneakListener.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.listeners.multiversion; import org.bukkit.entity.EntityType; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_15to1_14_4/EntityToggleGlideListener.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_15to1_14_4/EntityToggleGlideListener.java index bb290ee50..7588f4785 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_15to1_14_4/EntityToggleGlideListener.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/listeners/protocol1_15to1_14_4/EntityToggleGlideListener.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.listeners.protocol1_15to1_14_4; import org.bukkit.entity.Player; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitTaskId.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitTaskId.java index e2cd22fb5..8b910d12a 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitTaskId.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitTaskId.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.platform; import us.myles.ViaVersion.api.platform.TaskId; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitViaAPI.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitViaAPI.java index 5f6798c87..ab5f5016f 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitViaAPI.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitViaAPI.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.platform; import io.netty.buffer.ByteBuf; @@ -5,20 +22,17 @@ import org.bukkit.Bukkit; import org.bukkit.entity.Player; import us.myles.ViaVersion.ViaVersionPlugin; import us.myles.ViaVersion.api.Via; -import us.myles.ViaVersion.api.ViaAPI; +import us.myles.ViaVersion.api.ViaAPIBase; import us.myles.ViaVersion.api.boss.BossBar; import us.myles.ViaVersion.api.boss.BossColor; import us.myles.ViaVersion.api.boss.BossStyle; import us.myles.ViaVersion.api.data.UserConnection; -import us.myles.ViaVersion.api.protocol.ProtocolRegistry; import us.myles.ViaVersion.boss.ViaBossBar; import us.myles.ViaVersion.bukkit.util.ProtocolSupportUtil; -import java.util.SortedSet; -import java.util.TreeSet; import java.util.UUID; -public class BukkitViaAPI implements ViaAPI { +public class BukkitViaAPI extends ViaAPIBase { private final ViaVersionPlugin plugin; public BukkitViaAPI(ViaVersionPlugin plugin) { @@ -43,23 +57,6 @@ public class BukkitViaAPI implements ViaAPI { return connection.getProtocolInfo().getProtocolVersion(); } - @Override - public boolean isInjected(UUID playerUUID) { - return Via.getManager().isClientConnected(playerUUID); - } - - @Override - public String getVersion() { - return plugin.getDescription().getVersion(); - } - - @Override - public void sendRawPacket(UUID uuid, ByteBuf packet) throws IllegalArgumentException { - if (!isInjected(uuid)) throw new IllegalArgumentException("This player is not controlled by ViaVersion!"); - UserConnection ci = Via.getManager().getConnection(uuid); - ci.sendRawPacket(packet); - } - @Override public void sendRawPacket(Player player, ByteBuf packet) throws IllegalArgumentException { sendRawPacket(player.getUniqueId(), packet); @@ -75,14 +72,6 @@ public class BukkitViaAPI implements ViaAPI { return new ViaBossBar(title, health, color, style); } - @Override - public SortedSet getSupportedVersions() { - SortedSet outputSet = new TreeSet<>(ProtocolRegistry.getSupportedVersions()); - outputSet.removeAll(Via.getPlatform().getConf().getBlockedProtocols()); - - return outputSet; - } - /** * Returns if this version is a compatibility build for spigot. * Eg. 1.9.1 / 1.9.2 allow certain versions to connect diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitViaConfig.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitViaConfig.java index febaded66..94ad42f5e 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitViaConfig.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitViaConfig.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.platform; import org.bukkit.plugin.Plugin; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitViaInjector.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitViaInjector.java index 459abd0af..7bc71587d 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitViaInjector.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitViaInjector.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.platform; import com.google.gson.JsonArray; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitViaLoader.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitViaLoader.java index d20ca655a..28847ba3e 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitViaLoader.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/platform/BukkitViaLoader.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.platform; import org.bukkit.Bukkit; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/providers/BukkitInventoryQuickMoveProvider.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/providers/BukkitInventoryQuickMoveProvider.java index fd815224c..ab771ad15 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/providers/BukkitInventoryQuickMoveProvider.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/providers/BukkitInventoryQuickMoveProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.providers; import org.bukkit.entity.Player; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/providers/BukkitViaBulkChunkTranslator.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/providers/BukkitViaBulkChunkTranslator.java index 42c75e586..2363386f7 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/providers/BukkitViaBulkChunkTranslator.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/providers/BukkitViaBulkChunkTranslator.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.providers; import com.google.common.collect.Lists; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/providers/BukkitViaMovementTransmitter.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/providers/BukkitViaMovementTransmitter.java index c1d95ca89..8b52de19a 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/providers/BukkitViaMovementTransmitter.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/providers/BukkitViaMovementTransmitter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.providers; import org.bukkit.Bukkit; @@ -5,7 +22,6 @@ import org.bukkit.entity.Player; import us.myles.ViaVersion.api.Via; import us.myles.ViaVersion.api.data.UserConnection; import us.myles.ViaVersion.bukkit.util.NMSUtil; -import us.myles.ViaVersion.protocols.base.ProtocolInfo; import us.myles.ViaVersion.protocols.protocol1_9to1_8.providers.MovementTransmitterProvider; import us.myles.ViaVersion.protocols.protocol1_9to1_8.storage.MovementTracker; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/tasks/protocol1_12to1_11_1/BukkitInventoryUpdateTask.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/tasks/protocol1_12to1_11_1/BukkitInventoryUpdateTask.java index 58eb01430..362800c95 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/tasks/protocol1_12to1_11_1/BukkitInventoryUpdateTask.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/tasks/protocol1_12to1_11_1/BukkitInventoryUpdateTask.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.tasks.protocol1_12to1_11_1; import org.bukkit.Bukkit; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/util/NMSUtil.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/util/NMSUtil.java index b4f02acda..6ed2ca578 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/util/NMSUtil.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/util/NMSUtil.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.util; import org.bukkit.Bukkit; diff --git a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/util/ProtocolSupportUtil.java b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/util/ProtocolSupportUtil.java index f740893f8..9d52f9dfa 100644 --- a/bukkit/src/main/java/us/myles/ViaVersion/bukkit/util/ProtocolSupportUtil.java +++ b/bukkit/src/main/java/us/myles/ViaVersion/bukkit/util/ProtocolSupportUtil.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bukkit.util; import org.bukkit.entity.Player; diff --git a/bungee/src/main/java/us/myles/ViaVersion/BungeePlugin.java b/bungee/src/main/java/us/myles/ViaVersion/BungeePlugin.java index bf7f1ff01..f1b3ef438 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/BungeePlugin.java +++ b/bungee/src/main/java/us/myles/ViaVersion/BungeePlugin.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion; import com.google.gson.JsonObject; @@ -58,7 +75,7 @@ public class BungeePlugin extends Plugin implements ViaPlatform, ProxyServer.getInstance().getPluginManager().registerCommand(this, new BungeeCommand(commandHandler)); // Init platform - Via.init(ViaManager.builder() + Via.init(ViaManagerImpl.builder() .platform(this) .injector(new BungeeViaInjector()) .loader(new BungeeViaLoader(this)) @@ -73,7 +90,7 @@ public class BungeePlugin extends Plugin implements ViaPlatform, } // Inject - Via.getManager().init(); + ((ViaManagerImpl) Via.getManager()).init(); } @Override diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/commands/BungeeCommand.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/commands/BungeeCommand.java index 900b562c1..2f4cb721a 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/commands/BungeeCommand.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/commands/BungeeCommand.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.commands; import net.md_5.bungee.api.CommandSender; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/commands/BungeeCommandHandler.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/commands/BungeeCommandHandler.java index 8209a371b..8227cdf85 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/commands/BungeeCommandHandler.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/commands/BungeeCommandHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.commands; import us.myles.ViaVersion.api.Via; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/commands/BungeeCommandSender.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/commands/BungeeCommandSender.java index c6c549af2..e0e8cbd6d 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/commands/BungeeCommandSender.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/commands/BungeeCommandSender.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.commands; import net.md_5.bungee.api.CommandSender; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/commands/subs/ProbeSubCmd.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/commands/subs/ProbeSubCmd.java index a6184efa6..12b859622 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/commands/subs/ProbeSubCmd.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/commands/subs/ProbeSubCmd.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.commands.subs; import us.myles.ViaVersion.api.Via; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/handlers/BungeeChannelInitializer.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/handlers/BungeeChannelInitializer.java index ac7cba74c..2445bfe80 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/handlers/BungeeChannelInitializer.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/handlers/BungeeChannelInitializer.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.handlers; import io.netty.channel.Channel; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/handlers/BungeeDecodeHandler.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/handlers/BungeeDecodeHandler.java index 920af4ad4..ae6afb9c8 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/handlers/BungeeDecodeHandler.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/handlers/BungeeDecodeHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.handlers; import io.netty.buffer.ByteBuf; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/handlers/BungeeEncodeHandler.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/handlers/BungeeEncodeHandler.java index 5c1df2399..f72d6301d 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/handlers/BungeeEncodeHandler.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/handlers/BungeeEncodeHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.handlers; import io.netty.buffer.ByteBuf; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/handlers/BungeeServerHandler.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/handlers/BungeeServerHandler.java index d627a1aff..285e81994 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/handlers/BungeeServerHandler.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/handlers/BungeeServerHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.handlers; import net.md_5.bungee.api.connection.ProxiedPlayer; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/listeners/ElytraPatch.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/listeners/ElytraPatch.java index 8a61369e8..01ed33918 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/listeners/ElytraPatch.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/listeners/ElytraPatch.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.listeners; import net.md_5.bungee.api.event.ServerConnectedEvent; @@ -11,7 +28,6 @@ import us.myles.ViaVersion.api.minecraft.metadata.Metadata; import us.myles.ViaVersion.api.minecraft.metadata.types.MetaType1_9; import us.myles.ViaVersion.api.type.Type; import us.myles.ViaVersion.api.type.types.version.Types1_9; -import us.myles.ViaVersion.protocols.base.ProtocolInfo; import us.myles.ViaVersion.protocols.protocol1_9to1_8.Protocol1_9To1_8; import us.myles.ViaVersion.protocols.protocol1_9to1_8.storage.EntityTracker1_9; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/listeners/UpdateListener.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/listeners/UpdateListener.java index b27ba57e8..8ed61e97b 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/listeners/UpdateListener.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/listeners/UpdateListener.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.listeners; import net.md_5.bungee.api.event.PostLoginEvent; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeBossBar.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeBossBar.java index 538246ec2..d1b9e2712 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeBossBar.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeBossBar.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.platform; import net.md_5.bungee.api.connection.ProxiedPlayer; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeTaskId.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeTaskId.java index 96b9a8045..2469099fb 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeTaskId.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeTaskId.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.platform; import us.myles.ViaVersion.api.platform.TaskId; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeViaAPI.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeViaAPI.java index 0be8c11d7..8c9b2c383 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeViaAPI.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeViaAPI.java @@ -1,53 +1,38 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.platform; import io.netty.buffer.ByteBuf; import net.md_5.bungee.api.config.ServerInfo; import net.md_5.bungee.api.connection.ProxiedPlayer; -import us.myles.ViaVersion.api.Via; -import us.myles.ViaVersion.api.ViaAPI; +import us.myles.ViaVersion.api.ViaAPIBase; import us.myles.ViaVersion.api.boss.BossBar; import us.myles.ViaVersion.api.boss.BossColor; import us.myles.ViaVersion.api.boss.BossStyle; -import us.myles.ViaVersion.api.data.UserConnection; -import us.myles.ViaVersion.api.protocol.ProtocolRegistry; import us.myles.ViaVersion.bungee.service.ProtocolDetectorService; -import java.util.SortedSet; -import java.util.TreeSet; -import java.util.UUID; - -public class BungeeViaAPI implements ViaAPI { +public class BungeeViaAPI extends ViaAPIBase { @Override public int getPlayerVersion(ProxiedPlayer player) { return getPlayerVersion(player.getUniqueId()); } - @Override - public int getPlayerVersion(UUID uuid) { - UserConnection connection = Via.getManager().getConnection(uuid); - return connection != null ? connection.getProtocolInfo().getProtocolVersion() : -1; - } - - @Override - public boolean isInjected(UUID playerUUID) { - return Via.getManager().isClientConnected(playerUUID); - } - - @Override - public String getVersion() { - return Via.getPlatform().getPluginVersion(); - } - - @Override - public void sendRawPacket(UUID uuid, ByteBuf packet) throws IllegalArgumentException { - if (!isInjected(uuid)) { - throw new IllegalArgumentException("This player is not controlled by ViaVersion!"); - } - UserConnection ci = Via.getManager().getConnection(uuid); - ci.sendRawPacket(packet); - } - @Override public void sendRawPacket(ProxiedPlayer player, ByteBuf packet) throws IllegalArgumentException { sendRawPacket(player.getUniqueId(), packet); @@ -63,14 +48,6 @@ public class BungeeViaAPI implements ViaAPI { return new BungeeBossBar(title, health, color, style); } - @Override - public SortedSet getSupportedVersions() { - SortedSet outputSet = new TreeSet<>(ProtocolRegistry.getSupportedVersions()); - outputSet.removeAll(Via.getPlatform().getConf().getBlockedProtocols()); - - return outputSet; - } - /** * Forces ViaVersion to probe a server * diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeViaConfig.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeViaConfig.java index 08fe78561..8ac8e46ae 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeViaConfig.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeViaConfig.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.platform; import us.myles.ViaVersion.AbstractViaConfig; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeViaInjector.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeViaInjector.java index 7f0c0d76a..120826cca 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeViaInjector.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeViaInjector.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.platform; import com.google.gson.JsonObject; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeViaLoader.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeViaLoader.java index 58ad2b316..85a380977 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeViaLoader.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/platform/BungeeViaLoader.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.platform; import net.md_5.bungee.api.ProxyServer; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeBossBarProvider.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeBossBarProvider.java index e3a2ee8f2..b4dbda083 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeBossBarProvider.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeBossBarProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.providers; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeEntityIdProvider.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeEntityIdProvider.java index 3d223ae2f..49c81b553 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeEntityIdProvider.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeEntityIdProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.providers; import net.md_5.bungee.api.connection.ProxiedPlayer; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeMainHandProvider.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeMainHandProvider.java index 67bcc31d4..ba7e76c4f 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeMainHandProvider.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeMainHandProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.providers; import net.md_5.bungee.api.ProxyServer; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeMovementTransmitter.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeMovementTransmitter.java index 72515f78e..92e39f007 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeMovementTransmitter.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeMovementTransmitter.java @@ -1,10 +1,26 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.providers; import us.myles.ViaVersion.api.PacketWrapper; import us.myles.ViaVersion.api.data.UserConnection; import us.myles.ViaVersion.api.type.Type; import us.myles.ViaVersion.packets.State; -import us.myles.ViaVersion.protocols.base.ProtocolInfo; import us.myles.ViaVersion.protocols.protocol1_9to1_8.Protocol1_9To1_8; import us.myles.ViaVersion.protocols.protocol1_9to1_8.providers.MovementTransmitterProvider; import us.myles.ViaVersion.protocols.protocol1_9to1_8.storage.MovementTracker; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeVersionProvider.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeVersionProvider.java index 188e5f3b3..82dcb4bca 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeVersionProvider.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/providers/BungeeVersionProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.providers; import com.google.common.collect.Lists; @@ -5,15 +22,15 @@ import net.md_5.bungee.api.ProxyServer; import us.myles.ViaVersion.api.Via; import us.myles.ViaVersion.api.data.UserConnection; import us.myles.ViaVersion.api.protocol.ProtocolVersion; +import us.myles.ViaVersion.protocols.base.BaseVersionProvider; import us.myles.ViaVersion.protocols.base.ProtocolInfo; -import us.myles.ViaVersion.protocols.base.VersionProvider; import us.myles.ViaVersion.util.ReflectionUtil; import java.util.ArrayList; import java.util.Collections; import java.util.List; -public class BungeeVersionProvider extends VersionProvider { +public class BungeeVersionProvider extends BaseVersionProvider { private static Class ref; static { diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/service/ProtocolDetectorService.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/service/ProtocolDetectorService.java index e0d112b69..52e0ffa6e 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/service/ProtocolDetectorService.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/service/ProtocolDetectorService.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.service; import net.md_5.bungee.api.Callback; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/storage/BungeeStorage.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/storage/BungeeStorage.java index 8723fa2a4..80e3324d7 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/storage/BungeeStorage.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/storage/BungeeStorage.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.storage; import net.md_5.bungee.api.connection.ProxiedPlayer; diff --git a/bungee/src/main/java/us/myles/ViaVersion/bungee/util/BungeePipelineUtil.java b/bungee/src/main/java/us/myles/ViaVersion/bungee/util/BungeePipelineUtil.java index 9cc27c37b..e76dbc774 100644 --- a/bungee/src/main/java/us/myles/ViaVersion/bungee/util/BungeePipelineUtil.java +++ b/bungee/src/main/java/us/myles/ViaVersion/bungee/util/BungeePipelineUtil.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.bungee.util; import io.netty.buffer.ByteBuf; diff --git a/common/build.gradle.kts b/common/build.gradle.kts index 8265d0532..48fb217cb 100644 --- a/common/build.gradle.kts +++ b/common/build.gradle.kts @@ -8,13 +8,5 @@ blossom { } dependencies { - api(project(":adventure", "shadow")) - api("it.unimi.dsi", "fastutil", Versions.fastUtil) - api("com.viaversion", "opennbt", Versions.openNBT) - api("com.google.code.gson", "gson", Versions.gson) - - compileOnlyApi("org.yaml", "snakeyaml", Versions.snakeYaml) - compileOnlyApi("io.netty", "netty-all", Versions.netty) - compileOnlyApi("com.google.guava", "guava", Versions.guava) - compileOnlyApi("org.jetbrains", "annotations", Versions.jetbrainsAnnotations) + api(project(":viaversion-api")) } diff --git a/common/src/main/java/us/myles/ViaVersion/AbstractViaConfig.java b/common/src/main/java/us/myles/ViaVersion/AbstractViaConfig.java index df0b09adf..426539e78 100644 --- a/common/src/main/java/us/myles/ViaVersion/AbstractViaConfig.java +++ b/common/src/main/java/us/myles/ViaVersion/AbstractViaConfig.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion; import it.unimi.dsi.fastutil.ints.IntOpenHashSet; diff --git a/common/src/main/java/us/myles/ViaVersion/ViaManager.java b/common/src/main/java/us/myles/ViaVersion/ViaManagerImpl.java similarity index 86% rename from common/src/main/java/us/myles/ViaVersion/ViaManager.java rename to common/src/main/java/us/myles/ViaVersion/ViaManagerImpl.java index 864bbc73e..13677d163 100644 --- a/common/src/main/java/us/myles/ViaVersion/ViaManager.java +++ b/common/src/main/java/us/myles/ViaVersion/ViaManagerImpl.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion; import org.jetbrains.annotations.Nullable; @@ -9,6 +26,7 @@ import us.myles.ViaVersion.api.platform.ViaInjector; import us.myles.ViaVersion.api.platform.ViaPlatform; import us.myles.ViaVersion.api.platform.ViaPlatformLoader; import us.myles.ViaVersion.api.platform.providers.ViaProviders; +import us.myles.ViaVersion.api.protocol.Protocol; import us.myles.ViaVersion.api.protocol.ProtocolRegistry; import us.myles.ViaVersion.api.protocol.ProtocolVersion; import us.myles.ViaVersion.commands.ViaCommandHandler; @@ -23,7 +41,7 @@ import java.util.Map; import java.util.Set; import java.util.UUID; -public class ViaManager { +public class ViaManagerImpl implements ViaManager { private final ViaPlatform platform; private final ViaProviders providers = new ViaProviders(); // Internals @@ -35,7 +53,7 @@ public class ViaManager { private TaskId mappingLoadingTask; private boolean debug; - public ViaManager(ViaPlatform platform, ViaInjector injector, ViaCommandHandler commandHandler, ViaPlatformLoader loader) { + public ViaManagerImpl(ViaPlatform platform, ViaInjector injector, ViaCommandHandler commandHandler, ViaPlatformLoader loader) { this.platform = platform; this.injector = injector; this.commandHandler = commandHandler; @@ -232,6 +250,16 @@ public class ViaManager { enableListeners.add(runnable); } + @Override + public Protocol getBaseProtocol() { + return ProtocolRegistry.BASE_PROTOCOL; + } + + @Override + public boolean isBaseProtocol(Protocol protocol) { + return ProtocolRegistry.isBaseProtocol(protocol); + } + public static final class ViaManagerBuilder { private ViaPlatform platform; private ViaInjector injector; @@ -258,8 +286,8 @@ public class ViaManager { return this; } - public ViaManager build() { - return new ViaManager(platform, injector, commandHandler, loader); + public ViaManagerImpl build() { + return new ViaManagerImpl(platform, injector, commandHandler, loader); } } } diff --git a/common/src/main/java/us/myles/ViaVersion/api/ViaAPIBase.java b/common/src/main/java/us/myles/ViaVersion/api/ViaAPIBase.java new file mode 100644 index 000000000..5b6a54dfc --- /dev/null +++ b/common/src/main/java/us/myles/ViaVersion/api/ViaAPIBase.java @@ -0,0 +1,72 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ +package us.myles.ViaVersion.api; + +import io.netty.buffer.ByteBuf; +import us.myles.ViaVersion.api.data.UserConnection; +import us.myles.ViaVersion.api.protocol.ProtocolRegistry; + +import java.util.SortedSet; +import java.util.TreeSet; +import java.util.UUID; + +public abstract class ViaAPIBase implements ViaAPI { + + @Override + public int getServerVersion() { + return ProtocolRegistry.SERVER_PROTOCOL; + } + + @Override + public int getPlayerVersion(UUID uuid) { + UserConnection connection = Via.getManager().getConnection(uuid); + return connection != null ? connection.getProtocolInfo().getProtocolVersion() : -1; + } + + @Override + public String getVersion() { + return Via.getPlatform().getPluginVersion(); + } + + @Override + public boolean isInjected(UUID playerUUID) { + return Via.getManager().isClientConnected(playerUUID); + } + + @Override + public void sendRawPacket(UUID uuid, ByteBuf packet) throws IllegalArgumentException { + if (!isInjected(uuid)) { + throw new IllegalArgumentException("This player is not controlled by ViaVersion!"); + } + + UserConnection user = Via.getManager().getConnection(uuid); + user.sendRawPacket(packet); + } + + @Override + public SortedSet getSupportedVersions() { + SortedSet outputSet = new TreeSet<>(ProtocolRegistry.getSupportedVersions()); + outputSet.removeAll(Via.getPlatform().getConf().getBlockedProtocols()); + return outputSet; + } + + @Override + public SortedSet getFullSupportedVersions() { + return ProtocolRegistry.getSupportedVersions(); + } +} diff --git a/common/src/main/java/us/myles/ViaVersion/api/ViaListener.java b/common/src/main/java/us/myles/ViaVersion/api/ViaListener.java index 50d692779..e64f9fdc8 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/ViaListener.java +++ b/common/src/main/java/us/myles/ViaVersion/api/ViaListener.java @@ -1,9 +1,25 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.api; import org.jetbrains.annotations.Nullable; import us.myles.ViaVersion.api.data.UserConnection; import us.myles.ViaVersion.api.protocol.Protocol; -import us.myles.ViaVersion.protocols.base.ProtocolInfo; import java.util.UUID; diff --git a/common/src/main/java/us/myles/ViaVersion/api/protocol/ProtocolRegistry.java b/common/src/main/java/us/myles/ViaVersion/api/protocol/ProtocolRegistry.java index 722cf72f3..85581d5a4 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/protocol/ProtocolRegistry.java +++ b/common/src/main/java/us/myles/ViaVersion/api/protocol/ProtocolRegistry.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.api.protocol; import com.google.common.base.Preconditions; diff --git a/common/src/main/java/us/myles/ViaVersion/api/rewriters/BlockRewriter.java b/common/src/main/java/us/myles/ViaVersion/api/rewriters/BlockRewriter.java index 4c9d641d5..670015ce0 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/rewriters/BlockRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/api/rewriters/BlockRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.api.rewriters; import us.myles.ViaVersion.api.minecraft.BlockChangeRecord; diff --git a/common/src/main/java/us/myles/ViaVersion/api/rewriters/CommandRewriter.java b/common/src/main/java/us/myles/ViaVersion/api/rewriters/CommandRewriter.java index 50c34348f..3d54a6d02 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/rewriters/CommandRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/api/rewriters/CommandRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.api.rewriters; import org.jetbrains.annotations.Nullable; diff --git a/common/src/main/java/us/myles/ViaVersion/api/rewriters/ComponentRewriter.java b/common/src/main/java/us/myles/ViaVersion/api/rewriters/ComponentRewriter.java index 7362f43b2..bce579225 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/rewriters/ComponentRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/api/rewriters/ComponentRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.api.rewriters; import com.google.gson.JsonElement; diff --git a/common/src/main/java/us/myles/ViaVersion/api/rewriters/IdRewriteFunction.java b/common/src/main/java/us/myles/ViaVersion/api/rewriters/IdRewriteFunction.java index 05075e3f3..57726f2e1 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/rewriters/IdRewriteFunction.java +++ b/common/src/main/java/us/myles/ViaVersion/api/rewriters/IdRewriteFunction.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.api.rewriters; @FunctionalInterface diff --git a/common/src/main/java/us/myles/ViaVersion/api/rewriters/ItemRewriter.java b/common/src/main/java/us/myles/ViaVersion/api/rewriters/ItemRewriter.java index ec9cb97cb..5896bcdda 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/rewriters/ItemRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/api/rewriters/ItemRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.api.rewriters; import us.myles.ViaVersion.api.data.ParticleMappings; diff --git a/common/src/main/java/us/myles/ViaVersion/api/rewriters/MetadataRewriter.java b/common/src/main/java/us/myles/ViaVersion/api/rewriters/MetadataRewriter.java index ba391e670..ebebae675 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/rewriters/MetadataRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/api/rewriters/MetadataRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.api.rewriters; import it.unimi.dsi.fastutil.ints.Int2IntMap; diff --git a/common/src/main/java/us/myles/ViaVersion/api/rewriters/RecipeRewriter.java b/common/src/main/java/us/myles/ViaVersion/api/rewriters/RecipeRewriter.java index f876d43da..0a40558fd 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/rewriters/RecipeRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/api/rewriters/RecipeRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.api.rewriters; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/api/rewriters/RegistryType.java b/common/src/main/java/us/myles/ViaVersion/api/rewriters/RegistryType.java index 1eb19fccc..b5db45613 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/rewriters/RegistryType.java +++ b/common/src/main/java/us/myles/ViaVersion/api/rewriters/RegistryType.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.api.rewriters; import org.jetbrains.annotations.Nullable; diff --git a/common/src/main/java/us/myles/ViaVersion/api/rewriters/SoundRewriter.java b/common/src/main/java/us/myles/ViaVersion/api/rewriters/SoundRewriter.java index d877e10e7..1bd2fcb2a 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/rewriters/SoundRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/api/rewriters/SoundRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.api.rewriters; import us.myles.ViaVersion.api.protocol.ClientboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/api/rewriters/StatisticsRewriter.java b/common/src/main/java/us/myles/ViaVersion/api/rewriters/StatisticsRewriter.java index 06ac809bf..d2190da0e 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/rewriters/StatisticsRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/api/rewriters/StatisticsRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.api.rewriters; import org.jetbrains.annotations.Nullable; diff --git a/common/src/main/java/us/myles/ViaVersion/api/rewriters/TagRewriter.java b/common/src/main/java/us/myles/ViaVersion/api/rewriters/TagRewriter.java index 2099d9d2b..0f66f3f1f 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/rewriters/TagRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/api/rewriters/TagRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.api.rewriters; import it.unimi.dsi.fastutil.ints.IntArrayList; diff --git a/common/src/main/java/us/myles/ViaVersion/api/storage/EntityTracker.java b/common/src/main/java/us/myles/ViaVersion/api/storage/EntityTracker.java index bc49bf297..26ad5b845 100644 --- a/common/src/main/java/us/myles/ViaVersion/api/storage/EntityTracker.java +++ b/common/src/main/java/us/myles/ViaVersion/api/storage/EntityTracker.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.api.storage; import org.jetbrains.annotations.Nullable; diff --git a/common/src/main/java/us/myles/ViaVersion/boss/CommonBoss.java b/common/src/main/java/us/myles/ViaVersion/boss/CommonBoss.java index 113c124e0..ab060b030 100644 --- a/common/src/main/java/us/myles/ViaVersion/boss/CommonBoss.java +++ b/common/src/main/java/us/myles/ViaVersion/boss/CommonBoss.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.boss; import com.google.common.base.Preconditions; diff --git a/common/src/main/java/us/myles/ViaVersion/commands/ViaCommandHandler.java b/common/src/main/java/us/myles/ViaVersion/commands/ViaCommandHandler.java index e9cf926d6..d68e6a5f5 100644 --- a/common/src/main/java/us/myles/ViaVersion/commands/ViaCommandHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/commands/ViaCommandHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.commands; import com.google.common.base.Preconditions; @@ -14,7 +31,6 @@ import us.myles.ViaVersion.commands.defaultsubs.HelpSubCmd; import us.myles.ViaVersion.commands.defaultsubs.ListSubCmd; import us.myles.ViaVersion.commands.defaultsubs.PPSSubCmd; import us.myles.ViaVersion.commands.defaultsubs.ReloadSubCmd; -import us.myles.ViaVersion.util.ChatColorUtil; import java.util.ArrayList; import java.util.Arrays; @@ -26,6 +42,8 @@ import java.util.Locale; import java.util.Map; import java.util.Set; +import static us.myles.ViaVersion.api.command.ViaSubCommand.color; + public abstract class ViaCommandHandler implements ViaVersionCommand { private final Map commandMap; @@ -120,6 +138,7 @@ public abstract class ViaCommandHandler implements ViaVersionCommand { * * @param sender The sender to send the help to */ + @Override public void showHelp(ViaCommandSender sender) { Set allowed = calculateAllowedCommands(sender); if (allowed.isEmpty()) { @@ -156,25 +175,4 @@ public abstract class ViaCommandHandler implements ViaVersionCommand { registerSubCommand(new HelpSubCmd()); registerSubCommand(new ReloadSubCmd()); } - - /** - * Replaces colour codes in a string - * - * @param string String to replace - * @return The output String - */ - public static String color(String string) { - return ChatColorUtil.translateAlternateColorCodes(string); - } - - /** - * Send a colour coded string with replacements to a user - * - * @param sender The target to send the message to - * @param message The message - * @param args The objects to replace - */ - public static void sendMessage(ViaCommandSender sender, String message, Object... args) { - sender.sendMessage(color(args == null ? message : String.format(message, args))); - } } diff --git a/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/AutoTeamSubCmd.java b/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/AutoTeamSubCmd.java index eeecc9188..79535258a 100644 --- a/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/AutoTeamSubCmd.java +++ b/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/AutoTeamSubCmd.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.commands.defaultsubs; import us.myles.ViaVersion.api.Via; diff --git a/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/DebugSubCmd.java b/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/DebugSubCmd.java index 47396264c..9c74afb29 100644 --- a/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/DebugSubCmd.java +++ b/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/DebugSubCmd.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.commands.defaultsubs; import us.myles.ViaVersion.api.Via; diff --git a/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/DisplayLeaksSubCmd.java b/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/DisplayLeaksSubCmd.java index 244697ee3..9d0c4f3bb 100644 --- a/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/DisplayLeaksSubCmd.java +++ b/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/DisplayLeaksSubCmd.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.commands.defaultsubs; import io.netty.util.ResourceLeakDetector; diff --git a/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/DontBugMeSubCmd.java b/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/DontBugMeSubCmd.java index e16569c4c..0d09a3cf7 100644 --- a/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/DontBugMeSubCmd.java +++ b/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/DontBugMeSubCmd.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.commands.defaultsubs; import us.myles.ViaVersion.api.Via; diff --git a/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/DumpSubCmd.java b/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/DumpSubCmd.java index ca2030ccb..1c5762e24 100644 --- a/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/DumpSubCmd.java +++ b/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/DumpSubCmd.java @@ -1,8 +1,24 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.commands.defaultsubs; import com.google.common.io.CharStreams; import com.google.gson.JsonObject; -import us.myles.ViaVersion.ViaManager; import us.myles.ViaVersion.api.Via; import us.myles.ViaVersion.api.command.ViaCommandSender; import us.myles.ViaVersion.api.command.ViaSubCommand; diff --git a/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/HelpSubCmd.java b/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/HelpSubCmd.java index 96983349a..036cee03c 100644 --- a/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/HelpSubCmd.java +++ b/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/HelpSubCmd.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.commands.defaultsubs; import us.myles.ViaVersion.api.Via; diff --git a/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/ListSubCmd.java b/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/ListSubCmd.java index 40f34dd89..c265c5a9a 100644 --- a/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/ListSubCmd.java +++ b/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/ListSubCmd.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.commands.defaultsubs; import us.myles.ViaVersion.api.Via; diff --git a/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/PPSSubCmd.java b/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/PPSSubCmd.java index 90a090117..1d210f999 100644 --- a/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/PPSSubCmd.java +++ b/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/PPSSubCmd.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.commands.defaultsubs; import us.myles.ViaVersion.api.Via; diff --git a/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/ReloadSubCmd.java b/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/ReloadSubCmd.java index 8a1bf109c..d024777fa 100644 --- a/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/ReloadSubCmd.java +++ b/common/src/main/java/us/myles/ViaVersion/commands/defaultsubs/ReloadSubCmd.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.commands.defaultsubs; import us.myles.ViaVersion.api.Via; diff --git a/common/src/main/java/us/myles/ViaVersion/dump/DumpTemplate.java b/common/src/main/java/us/myles/ViaVersion/dump/DumpTemplate.java index e1db18b34..de67983cb 100644 --- a/common/src/main/java/us/myles/ViaVersion/dump/DumpTemplate.java +++ b/common/src/main/java/us/myles/ViaVersion/dump/DumpTemplate.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.dump; import com.google.gson.JsonObject; diff --git a/common/src/main/java/us/myles/ViaVersion/dump/PluginInfo.java b/common/src/main/java/us/myles/ViaVersion/dump/PluginInfo.java index 86078d024..a63a34284 100644 --- a/common/src/main/java/us/myles/ViaVersion/dump/PluginInfo.java +++ b/common/src/main/java/us/myles/ViaVersion/dump/PluginInfo.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.dump; import java.util.List; diff --git a/common/src/main/java/us/myles/ViaVersion/dump/VersionInfo.java b/common/src/main/java/us/myles/ViaVersion/dump/VersionInfo.java index 3d1e7f3ff..269e43df0 100644 --- a/common/src/main/java/us/myles/ViaVersion/dump/VersionInfo.java +++ b/common/src/main/java/us/myles/ViaVersion/dump/VersionInfo.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.dump; import java.util.Set; diff --git a/common/src/main/java/us/myles/ViaVersion/handlers/ChannelHandlerContextWrapper.java b/common/src/main/java/us/myles/ViaVersion/handlers/ChannelHandlerContextWrapper.java index 7a57d4269..37c1c0489 100644 --- a/common/src/main/java/us/myles/ViaVersion/handlers/ChannelHandlerContextWrapper.java +++ b/common/src/main/java/us/myles/ViaVersion/handlers/ChannelHandlerContextWrapper.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.handlers; import io.netty.buffer.ByteBuf; diff --git a/common/src/main/java/us/myles/ViaVersion/handlers/ViaHandler.java b/common/src/main/java/us/myles/ViaVersion/handlers/ViaHandler.java index b7d779351..df49db71e 100644 --- a/common/src/main/java/us/myles/ViaVersion/handlers/ViaHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/handlers/ViaHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.handlers; import io.netty.buffer.ByteBuf; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/base/BaseProtocol.java b/common/src/main/java/us/myles/ViaVersion/protocols/base/BaseProtocol.java index 3c261c910..e53780117 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/base/BaseProtocol.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/base/BaseProtocol.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.base; import us.myles.ViaVersion.api.PacketWrapper; @@ -86,7 +103,7 @@ public class BaseProtocol extends SimpleProtocol { @Override protected void register(ViaProviders providers) { - providers.register(VersionProvider.class, new VersionProvider()); + providers.register(VersionProvider.class, new BaseVersionProvider()); } @Override diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/base/BaseProtocol1_16.java b/common/src/main/java/us/myles/ViaVersion/protocols/base/BaseProtocol1_16.java index 7b9a73c28..b32b4dd1b 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/base/BaseProtocol1_16.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/base/BaseProtocol1_16.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.base; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/base/BaseProtocol1_7.java b/common/src/main/java/us/myles/ViaVersion/protocols/base/BaseProtocol1_7.java index 0f9efa479..288b7d231 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/base/BaseProtocol1_7.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/base/BaseProtocol1_7.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.base; import com.google.common.base.Joiner; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/base/BaseVersionProvider.java b/common/src/main/java/us/myles/ViaVersion/protocols/base/BaseVersionProvider.java new file mode 100644 index 000000000..e2f511c24 --- /dev/null +++ b/common/src/main/java/us/myles/ViaVersion/protocols/base/BaseVersionProvider.java @@ -0,0 +1,29 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ +package us.myles.ViaVersion.protocols.base; + +import us.myles.ViaVersion.api.data.UserConnection; +import us.myles.ViaVersion.api.platform.providers.Provider; +import us.myles.ViaVersion.api.protocol.ProtocolRegistry; + +public class BaseVersionProvider implements VersionProvider { + + public int getServerProtocol(UserConnection connection) throws Exception { + return ProtocolRegistry.SERVER_PROTOCOL; + } +} diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/base/VersionProvider.java b/common/src/main/java/us/myles/ViaVersion/protocols/base/VersionProvider.java deleted file mode 100644 index ec30cf4b1..000000000 --- a/common/src/main/java/us/myles/ViaVersion/protocols/base/VersionProvider.java +++ /dev/null @@ -1,12 +0,0 @@ -package us.myles.ViaVersion.protocols.base; - -import us.myles.ViaVersion.api.data.UserConnection; -import us.myles.ViaVersion.api.platform.providers.Provider; -import us.myles.ViaVersion.api.protocol.ProtocolRegistry; - -public class VersionProvider implements Provider { - - public int getServerProtocol(UserConnection connection) throws Exception { - return ProtocolRegistry.SERVER_PROTOCOL; - } -} diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_10to1_9_3/Protocol1_10To1_9_3_4.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_10to1_9_3/Protocol1_10To1_9_3_4.java index 1525d5a32..8dcddc665 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_10to1_9_3/Protocol1_10To1_9_3_4.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_10to1_9_3/Protocol1_10To1_9_3_4.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_10to1_9_3; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_10to1_9_3/packets/InventoryPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_10to1_9_3/packets/InventoryPackets.java index ecf89c327..6e5bc2d9e 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_10to1_9_3/packets/InventoryPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_10to1_9_3/packets/InventoryPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_10to1_9_3.packets; import us.myles.ViaVersion.api.minecraft.item.Item; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_10to1_9_3/storage/ResourcePackTracker.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_10to1_9_3/storage/ResourcePackTracker.java index 7298016be..bf7ef8bb4 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_10to1_9_3/storage/ResourcePackTracker.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_10to1_9_3/storage/ResourcePackTracker.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_10to1_9_3.storage; import us.myles.ViaVersion.api.data.StoredObject; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11_1to1_11/Protocol1_11_1To1_11.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11_1to1_11/Protocol1_11_1To1_11.java index 5b89e0983..5100f3e27 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11_1to1_11/Protocol1_11_1To1_11.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11_1to1_11/Protocol1_11_1To1_11.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_11_1to1_11; import us.myles.ViaVersion.api.protocol.Protocol; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11_1to1_11/packets/InventoryPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11_1to1_11/packets/InventoryPackets.java index 6446f9684..a2dac473d 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11_1to1_11/packets/InventoryPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11_1to1_11/packets/InventoryPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_11_1to1_11.packets; import us.myles.ViaVersion.api.minecraft.item.Item; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/BlockEntityRewriter.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/BlockEntityRewriter.java index fa7b490de..393a75209 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/BlockEntityRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/BlockEntityRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_11to1_10; import com.google.common.collect.BiMap; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/EntityIdRewriter.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/EntityIdRewriter.java index adf3d99f0..d7f6f96b4 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/EntityIdRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/EntityIdRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_11to1_10; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/Protocol1_11To1_10.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/Protocol1_11To1_10.java index bccc72437..6208968ff 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/Protocol1_11To1_10.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/Protocol1_11To1_10.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_11to1_10; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/data/PotionColorMapping.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/data/PotionColorMapping.java index 70b131e85..119afe467 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/data/PotionColorMapping.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/data/PotionColorMapping.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_11to1_10.data; import it.unimi.dsi.fastutil.ints.Int2ObjectMap; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/metadata/MetadataRewriter1_11To1_10.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/metadata/MetadataRewriter1_11To1_10.java index 6681b8e0d..72e534419 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/metadata/MetadataRewriter1_11To1_10.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/metadata/MetadataRewriter1_11To1_10.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_11to1_10.metadata; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/packets/InventoryPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/packets/InventoryPackets.java index 0f66861b5..3f0cf75bc 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/packets/InventoryPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/packets/InventoryPackets.java @@ -1,7 +1,23 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_11to1_10.packets; import us.myles.ViaVersion.api.PacketWrapper; -import us.myles.ViaVersion.api.Via; import us.myles.ViaVersion.api.minecraft.item.Item; import us.myles.ViaVersion.api.remapper.PacketHandler; import us.myles.ViaVersion.api.remapper.PacketRemapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/storage/EntityTracker1_11.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/storage/EntityTracker1_11.java index 10088b9ba..55f0da338 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/storage/EntityTracker1_11.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_11to1_10/storage/EntityTracker1_11.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_11to1_10.storage; import com.google.common.collect.Sets; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12_1to1_12/ClientboundPackets1_12_1.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12_1to1_12/ClientboundPackets1_12_1.java index 85baecbf4..e9c007550 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12_1to1_12/ClientboundPackets1_12_1.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12_1to1_12/ClientboundPackets1_12_1.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_12_1to1_12; import us.myles.ViaVersion.api.protocol.ClientboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12_1to1_12/Protocol1_12_1To1_12.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12_1to1_12/Protocol1_12_1To1_12.java index 09c4d67f5..b781dcf42 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12_1to1_12/Protocol1_12_1To1_12.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12_1to1_12/Protocol1_12_1To1_12.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_12_1to1_12; import us.myles.ViaVersion.api.protocol.Protocol; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12_1to1_12/ServerboundPackets1_12_1.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12_1to1_12/ServerboundPackets1_12_1.java index 1dd24b7fa..3fada4548 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12_1to1_12/ServerboundPackets1_12_1.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12_1to1_12/ServerboundPackets1_12_1.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_12_1to1_12; import us.myles.ViaVersion.api.protocol.ServerboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12_2to1_12_1/Protocol1_12_2To1_12_1.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12_2to1_12_1/Protocol1_12_2To1_12_1.java index 450092bfa..04b15440d 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12_2to1_12_1/Protocol1_12_2To1_12_1.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12_2to1_12_1/Protocol1_12_2To1_12_1.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_12_2to1_12_1; import us.myles.ViaVersion.api.protocol.Protocol; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/BedRewriter.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/BedRewriter.java index e31501a8d..72e4fc458 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/BedRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/BedRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_12to1_11_1; import us.myles.ViaVersion.api.minecraft.item.Item; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/ChatItemRewriter.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/ChatItemRewriter.java index f74b2b5ed..9a1e7567d 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/ChatItemRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/ChatItemRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_12to1_11_1; import com.google.gson.JsonArray; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/ClientboundPackets1_12.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/ClientboundPackets1_12.java index a3499e252..0828ed54a 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/ClientboundPackets1_12.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/ClientboundPackets1_12.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_12to1_11_1; import us.myles.ViaVersion.api.protocol.ClientboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/Protocol1_12To1_11_1.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/Protocol1_12To1_11_1.java index 16d060119..7e91f99a6 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/Protocol1_12To1_11_1.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/Protocol1_12To1_11_1.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_12to1_11_1; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/ServerboundPackets1_12.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/ServerboundPackets1_12.java index 5c10d99f0..cea0c8068 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/ServerboundPackets1_12.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/ServerboundPackets1_12.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_12to1_11_1; import us.myles.ViaVersion.api.protocol.ServerboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/TranslateRewriter.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/TranslateRewriter.java index 2adcf5903..87b32cac5 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/TranslateRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/TranslateRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_12to1_11_1; import com.google.gson.JsonArray; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/data/AchievementTranslationMapping.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/data/AchievementTranslationMapping.java index efb401e4d..d9551720e 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/data/AchievementTranslationMapping.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/data/AchievementTranslationMapping.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_12to1_11_1.data; import it.unimi.dsi.fastutil.objects.Object2ObjectOpenHashMap; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/metadata/MetadataRewriter1_12To1_11_1.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/metadata/MetadataRewriter1_12To1_11_1.java index b7c30fe3c..3bb0dd302 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/metadata/MetadataRewriter1_12To1_11_1.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/metadata/MetadataRewriter1_12To1_11_1.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_12to1_11_1.metadata; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/packets/InventoryPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/packets/InventoryPackets.java index 4306e48cc..fa1c922c5 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/packets/InventoryPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/packets/InventoryPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_12to1_11_1.packets; import us.myles.ViaVersion.api.PacketWrapper; @@ -7,7 +24,6 @@ import us.myles.ViaVersion.api.remapper.PacketHandler; import us.myles.ViaVersion.api.remapper.PacketRemapper; import us.myles.ViaVersion.api.rewriters.ItemRewriter; import us.myles.ViaVersion.api.type.Type; -import us.myles.ViaVersion.protocols.protocol1_11to1_10.EntityIdRewriter; import us.myles.ViaVersion.protocols.protocol1_9_3to1_9_1_2.ClientboundPackets1_9_3; import us.myles.ViaVersion.protocols.protocol1_12to1_11_1.BedRewriter; import us.myles.ViaVersion.protocols.protocol1_12to1_11_1.Protocol1_12To1_11_1; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/providers/InventoryQuickMoveProvider.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/providers/InventoryQuickMoveProvider.java index dffe0b114..f99e0e3da 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/providers/InventoryQuickMoveProvider.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/providers/InventoryQuickMoveProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_12to1_11_1.providers; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/storage/EntityTracker1_12.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/storage/EntityTracker1_12.java index 56340db15..cd3374f4f 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/storage/EntityTracker1_12.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/storage/EntityTracker1_12.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_12to1_11_1.storage; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/storage/ItemTransaction.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/storage/ItemTransaction.java index 00441065c..cdb1a1973 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/storage/ItemTransaction.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_12to1_11_1/storage/ItemTransaction.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_12to1_11_1.storage; public class ItemTransaction { diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/Protocol1_13_1To1_13.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/Protocol1_13_1To1_13.java index 285c8143f..d09cfc2d8 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/Protocol1_13_1To1_13.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/Protocol1_13_1To1_13.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13_1to1_13; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/metadata/MetadataRewriter1_13_1To1_13.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/metadata/MetadataRewriter1_13_1To1_13.java index d5ad83d3b..c79bc7599 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/metadata/MetadataRewriter1_13_1To1_13.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/metadata/MetadataRewriter1_13_1To1_13.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13_1to1_13.metadata; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/packets/EntityPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/packets/EntityPackets.java index 182a3d09e..c5f01ae5b 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/packets/EntityPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/packets/EntityPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13_1to1_13.packets; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/packets/InventoryPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/packets/InventoryPackets.java index f4a3018c8..542a6c206 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/packets/InventoryPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/packets/InventoryPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13_1to1_13.packets; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/packets/WorldPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/packets/WorldPackets.java index 41e3ec0bb..79c4b60cf 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/packets/WorldPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_1to1_13/packets/WorldPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13_1to1_13.packets; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/Protocol1_13_2To1_13_1.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/Protocol1_13_2To1_13_1.java index 5fa6099e9..d33105401 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/Protocol1_13_2To1_13_1.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/Protocol1_13_2To1_13_1.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13_2to1_13_1; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/packets/EntityPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/packets/EntityPackets.java index ea5511460..4380a52a3 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/packets/EntityPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/packets/EntityPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13_2to1_13_1.packets; import us.myles.ViaVersion.api.minecraft.metadata.Metadata; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/packets/InventoryPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/packets/InventoryPackets.java index 62017c3d3..9cb749a31 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/packets/InventoryPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/packets/InventoryPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13_2to1_13_1.packets; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/packets/WorldPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/packets/WorldPackets.java index d97e6d5f5..e6ccc2dbb 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/packets/WorldPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/packets/WorldPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13_2to1_13_1.packets; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/types/Particle1_13_2Type.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/types/Particle1_13_2Type.java index 3db93b35c..cf734a0e1 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/types/Particle1_13_2Type.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13_2to1_13_1/types/Particle1_13_2Type.java @@ -1,9 +1,27 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13_2to1_13_1.types; import io.netty.buffer.ByteBuf; import us.myles.ViaVersion.api.type.Type; import us.myles.ViaVersion.api.type.types.Particle; +@Deprecated public class Particle1_13_2Type extends Type { public Particle1_13_2Type() { super("Particle", Particle.class); diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/ChatRewriter.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/ChatRewriter.java index a2fcd4d67..e76810a8b 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/ChatRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/ChatRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2; import com.google.gson.JsonElement; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/ClientboundPackets1_13.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/ClientboundPackets1_13.java index 05ccd9f6b..49e815b43 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/ClientboundPackets1_13.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/ClientboundPackets1_13.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2; import us.myles.ViaVersion.api.protocol.ClientboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/Protocol1_13To1_12_2.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/Protocol1_13To1_12_2.java index 605d24cc8..a6dbc1676 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/Protocol1_13To1_12_2.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/Protocol1_13To1_12_2.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2; import com.google.common.collect.Sets; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/ServerboundPackets1_13.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/ServerboundPackets1_13.java index 7540a3a87..890da9b04 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/ServerboundPackets1_13.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/ServerboundPackets1_13.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2; import us.myles.ViaVersion.api.protocol.ServerboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/TabCompleteThread.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/TabCompleteThread.java index 52bf034fe..56e088ddc 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/TabCompleteThread.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/TabCompleteThread.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2; import us.myles.ViaVersion.api.Via; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/AbstractFenceConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/AbstractFenceConnectionHandler.java index b5be3055e..575344291 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/AbstractFenceConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/AbstractFenceConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/AbstractStempConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/AbstractStempConnectionHandler.java index 7ac6d1a45..ec2720271 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/AbstractStempConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/AbstractStempConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/BasicFenceConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/BasicFenceConnectionHandler.java index 5f38bc25b..5b68fe6fe 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/BasicFenceConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/BasicFenceConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import java.util.ArrayList; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/BlockData.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/BlockData.java index 7ca651847..fd08d4463 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/BlockData.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/BlockData.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import us.myles.ViaVersion.api.minecraft.BlockFace; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ChestConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ChestConnectionHandler.java index 279d5dd3e..c0b9e887b 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ChestConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ChestConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ChorusPlantConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ChorusPlantConnectionHandler.java index da94d8a02..737a856c6 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ChorusPlantConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ChorusPlantConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ConnectionData.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ConnectionData.java index 66ecab8d9..f52761b37 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ConnectionData.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ConnectionData.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import com.google.gson.JsonArray; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ConnectionHandler.java index e0c568221..3a1b78810 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/ConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import us.myles.ViaVersion.api.Via; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/DoorConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/DoorConnectionHandler.java index 52d4e0a4e..7e1da9f3e 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/DoorConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/DoorConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/FireConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/FireConnectionHandler.java index e3ddc50bc..05ebd542c 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/FireConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/FireConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/FlowerConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/FlowerConnectionHandler.java index 0ede1d469..cc1e0bdda 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/FlowerConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/FlowerConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import it.unimi.dsi.fastutil.ints.Int2IntMap; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/GlassConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/GlassConnectionHandler.java index 0f4ce4af3..5e354ca86 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/GlassConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/GlassConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/MelonConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/MelonConnectionHandler.java index 9f8339ec7..843b1f83a 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/MelonConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/MelonConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; public class MelonConnectionHandler extends AbstractStempConnectionHandler { diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/NetherFenceConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/NetherFenceConnectionHandler.java index b021999d9..e00087aa8 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/NetherFenceConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/NetherFenceConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; public class NetherFenceConnectionHandler extends AbstractFenceConnectionHandler { diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/PumpkinConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/PumpkinConnectionHandler.java index 24b819ca8..c605c34ec 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/PumpkinConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/PumpkinConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; public class PumpkinConnectionHandler extends AbstractStempConnectionHandler { diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/RedstoneConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/RedstoneConnectionHandler.java index 4f147800f..7c9568725 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/RedstoneConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/RedstoneConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import it.unimi.dsi.fastutil.ints.Int2IntMap; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/SnowyGrassConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/SnowyGrassConnectionHandler.java index b0941689a..fc4f9362a 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/SnowyGrassConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/SnowyGrassConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import us.myles.ViaVersion.api.Pair; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/StairConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/StairConnectionHandler.java index ebd416007..d54dff540 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/StairConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/StairConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/TripwireConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/TripwireConnectionHandler.java index d19986699..1809d8bd3 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/TripwireConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/TripwireConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/VineConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/VineConnectionHandler.java index e6b238f9a..7d280d743 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/VineConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/VineConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/WallConnectionHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/WallConnectionHandler.java index 8acf6a875..eb00eebe7 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/WallConnectionHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/WallConnectionHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/WrappedBlockData.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/WrappedBlockData.java index 212307d35..71aabf876 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/WrappedBlockData.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/WrappedBlockData.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections; import us.myles.ViaVersion.api.Via; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/providers/BlockConnectionProvider.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/providers/BlockConnectionProvider.java index 89f70eabe..e5ff98af7 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/providers/BlockConnectionProvider.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/providers/BlockConnectionProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections.providers; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/providers/PacketBlockConnectionProvider.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/providers/PacketBlockConnectionProvider.java index 7ce459696..708599cd8 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/providers/PacketBlockConnectionProvider.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/blockconnections/providers/PacketBlockConnectionProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.blockconnections.providers; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/BlockIdData.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/BlockIdData.java index 24c9255d4..38824f290 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/BlockIdData.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/BlockIdData.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.data; import com.google.common.collect.ObjectArrays; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/ComponentRewriter1_13.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/ComponentRewriter1_13.java index 0f1016482..99f9b8076 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/ComponentRewriter1_13.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/ComponentRewriter1_13.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.data; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/EntityNameRewriter.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/EntityNameRewriter.java index d1a5b83ba..c9f7e9cdd 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/EntityNameRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/EntityNameRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.data; import java.util.HashMap; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/EntityTypeRewriter.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/EntityTypeRewriter.java index a6f1f53cc..5e895f2b7 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/EntityTypeRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/EntityTypeRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.data; import it.unimi.dsi.fastutil.ints.Int2IntMap; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/MappingData.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/MappingData.java index f5c502ca4..718f752fc 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/MappingData.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/MappingData.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.data; import com.google.common.collect.BiMap; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/NamedSoundRewriter.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/NamedSoundRewriter.java index fa300c7d7..f71c6f814 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/NamedSoundRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/NamedSoundRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.data; import java.util.HashMap; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/ParticleRewriter.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/ParticleRewriter.java index a9fa72eec..8cb74af0a 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/ParticleRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/ParticleRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.data; import us.myles.ViaVersion.api.Via; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/RecipeData.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/RecipeData.java index 4290b798e..1d0c9237f 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/RecipeData.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/RecipeData.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.data; import com.google.gson.reflect.TypeToken; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/RecipeRewriter1_13_2.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/RecipeRewriter1_13_2.java index 47892541e..d7b8b106b 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/RecipeRewriter1_13_2.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/RecipeRewriter1_13_2.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.data; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/SoundSource.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/SoundSource.java index c5a837e38..077f32939 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/SoundSource.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/SoundSource.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.data; import java.util.Optional; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/SpawnEggRewriter.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/SpawnEggRewriter.java index fc351c1c8..b5cca9b4e 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/SpawnEggRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/SpawnEggRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.data; import com.google.common.collect.BiMap; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/StatisticData.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/StatisticData.java index 317a0ce7f..e0d21b803 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/StatisticData.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/StatisticData.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.data; public class StatisticData { diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/StatisticMappings.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/StatisticMappings.java index 94cbd445b..699fe0d7f 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/StatisticMappings.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/data/StatisticMappings.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.data; import java.util.HashMap; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/metadata/MetadataRewriter1_13To1_12_2.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/metadata/MetadataRewriter1_13To1_12_2.java index 4e648f65e..24d7c04f0 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/metadata/MetadataRewriter1_13To1_12_2.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/metadata/MetadataRewriter1_13To1_12_2.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.metadata; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/packets/EntityPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/packets/EntityPackets.java index 5bcc7595f..b67316229 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/packets/EntityPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/packets/EntityPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.packets; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/packets/InventoryPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/packets/InventoryPackets.java index 388aacc78..f1af23167 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/packets/InventoryPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/packets/InventoryPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.packets; import com.github.steveice10.opennbt.conversion.ConverterRegistry; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/packets/WorldPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/packets/WorldPackets.java index 05a3d542e..1274e5404 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/packets/WorldPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/packets/WorldPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.packets; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/BlockEntityProvider.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/BlockEntityProvider.java index 84cee1aeb..26bec87c1 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/BlockEntityProvider.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/BlockEntityProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.providers; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/PaintingProvider.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/PaintingProvider.java index b1f507c5b..31c7d1a8f 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/PaintingProvider.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/PaintingProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.providers; import us.myles.ViaVersion.api.platform.providers.Provider; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/BannerHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/BannerHandler.java index 18f621628..992eeca4b 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/BannerHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/BannerHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.providers.blockentities; import com.github.steveice10.opennbt.tag.builtin.*; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/BedHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/BedHandler.java index b079fad05..f82c68dc2 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/BedHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/BedHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.providers.blockentities; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/CommandBlockHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/CommandBlockHandler.java index 15d743236..429440b9f 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/CommandBlockHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/CommandBlockHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.providers.blockentities; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/FlowerPotHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/FlowerPotHandler.java index 47fa806f9..e987c69e8 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/FlowerPotHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/FlowerPotHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.providers.blockentities; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/SkullHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/SkullHandler.java index 56412a270..65d47959f 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/SkullHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/SkullHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.providers.blockentities; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/SpawnerHandler.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/SpawnerHandler.java index ad0b50519..5684a6ac1 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/SpawnerHandler.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/providers/blockentities/SpawnerHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.providers.blockentities; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/storage/BlockConnectionStorage.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/storage/BlockConnectionStorage.java index 31dee69e6..f95e05982 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/storage/BlockConnectionStorage.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/storage/BlockConnectionStorage.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.storage; import us.myles.ViaVersion.api.Pair; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/storage/BlockStorage.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/storage/BlockStorage.java index 91728d621..d374ccf7a 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/storage/BlockStorage.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/storage/BlockStorage.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.storage; import it.unimi.dsi.fastutil.ints.IntOpenHashSet; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/storage/EntityTracker1_13.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/storage/EntityTracker1_13.java index da5ea486b..185fcf036 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/storage/EntityTracker1_13.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/storage/EntityTracker1_13.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.storage; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/storage/TabCompleteTracker.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/storage/TabCompleteTracker.java index b3d7e99c4..a7df259a7 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/storage/TabCompleteTracker.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/storage/TabCompleteTracker.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.storage; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/types/Chunk1_13Type.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/types/Chunk1_13Type.java index 0732b4c95..3913ba6ba 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/types/Chunk1_13Type.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/types/Chunk1_13Type.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.types; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/types/Particle1_13Type.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/types/Particle1_13Type.java index 5abc24ea3..d7089473b 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/types/Particle1_13Type.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_13to1_12_2/types/Particle1_13Type.java @@ -1,10 +1,27 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_13to1_12_2.types; import io.netty.buffer.ByteBuf; import us.myles.ViaVersion.api.type.Type; import us.myles.ViaVersion.api.type.types.Particle; -// TODO make future proof +@Deprecated public class Particle1_13Type extends Type { public Particle1_13Type() { super("Particle", Particle.class); diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_1to1_14/Protocol1_14_1To1_14.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_1to1_14/Protocol1_14_1To1_14.java index 20886fcb1..6f4875c93 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_1to1_14/Protocol1_14_1To1_14.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_1to1_14/Protocol1_14_1To1_14.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14_1to1_14; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_1to1_14/metadata/MetadataRewriter1_14_1To1_14.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_1to1_14/metadata/MetadataRewriter1_14_1To1_14.java index aa7906601..fa182e1e3 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_1to1_14/metadata/MetadataRewriter1_14_1To1_14.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_1to1_14/metadata/MetadataRewriter1_14_1To1_14.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14_1to1_14.metadata; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_1to1_14/packets/EntityPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_1to1_14/packets/EntityPackets.java index 8c9307ac6..7d1f7c19f 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_1to1_14/packets/EntityPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_1to1_14/packets/EntityPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14_1to1_14.packets; import us.myles.ViaVersion.api.entities.Entity1_14Types; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_1to1_14/storage/EntityTracker1_14_1.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_1to1_14/storage/EntityTracker1_14_1.java index ac377517a..0b31dd6ce 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_1to1_14/storage/EntityTracker1_14_1.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_1to1_14/storage/EntityTracker1_14_1.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14_1to1_14.storage; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_2to1_14_1/Protocol1_14_2To1_14_1.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_2to1_14_1/Protocol1_14_2To1_14_1.java index 277dfcd8b..ad86be2fe 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_2to1_14_1/Protocol1_14_2To1_14_1.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_2to1_14_1/Protocol1_14_2To1_14_1.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14_2to1_14_1; import us.myles.ViaVersion.api.protocol.Protocol; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_3to1_14_2/Protocol1_14_3To1_14_2.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_3to1_14_2/Protocol1_14_3To1_14_2.java index 18dcb1f06..84ef41fda 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_3to1_14_2/Protocol1_14_3To1_14_2.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_3to1_14_2/Protocol1_14_3To1_14_2.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14_3to1_14_2; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_4to1_14_3/Protocol1_14_4To1_14_3.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_4to1_14_3/Protocol1_14_4To1_14_3.java index 911e89b75..208bf489d 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_4to1_14_3/Protocol1_14_4To1_14_3.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14_4to1_14_3/Protocol1_14_4To1_14_3.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14_4to1_14_3; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/ClientboundPackets1_14.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/ClientboundPackets1_14.java index 513188c5d..84839b68c 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/ClientboundPackets1_14.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/ClientboundPackets1_14.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14to1_13_2; import us.myles.ViaVersion.api.protocol.ClientboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/Protocol1_14To1_13_2.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/Protocol1_14To1_13_2.java index eb6f00a03..247beebb1 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/Protocol1_14To1_13_2.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/Protocol1_14To1_13_2.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14to1_13_2; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/ServerboundPackets1_14.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/ServerboundPackets1_14.java index bb287f33d..c466f867d 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/ServerboundPackets1_14.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/ServerboundPackets1_14.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14to1_13_2; import us.myles.ViaVersion.api.protocol.ServerboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/data/CommandRewriter1_14.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/data/CommandRewriter1_14.java index e958c988c..1d986f5a9 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/data/CommandRewriter1_14.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/data/CommandRewriter1_14.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14to1_13_2.data; import org.jetbrains.annotations.Nullable; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/data/ComponentRewriter1_14.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/data/ComponentRewriter1_14.java index 7f0bffbdb..fe4335874 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/data/ComponentRewriter1_14.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/data/ComponentRewriter1_14.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14to1_13_2.data; import com.google.gson.JsonObject; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/data/MappingData.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/data/MappingData.java index 00ca1459a..350996347 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/data/MappingData.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/data/MappingData.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14to1_13_2.data; import com.google.gson.JsonArray; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/data/RecipeRewriter1_14.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/data/RecipeRewriter1_14.java index 93dac1e94..46f750e13 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/data/RecipeRewriter1_14.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/data/RecipeRewriter1_14.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14to1_13_2.data; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/metadata/MetadataRewriter1_14To1_13_2.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/metadata/MetadataRewriter1_14To1_13_2.java index c9634fef6..200a9fab7 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/metadata/MetadataRewriter1_14To1_13_2.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/metadata/MetadataRewriter1_14To1_13_2.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14to1_13_2.metadata; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/packets/EntityPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/packets/EntityPackets.java index 289767fd3..f0777efff 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/packets/EntityPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/packets/EntityPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14to1_13_2.packets; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/packets/InventoryPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/packets/InventoryPackets.java index 638cd7091..6aec84ea0 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/packets/InventoryPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/packets/InventoryPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14to1_13_2.packets; import com.github.steveice10.opennbt.tag.builtin.*; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/packets/PlayerPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/packets/PlayerPackets.java index 75a4ce6fb..fb806f465 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/packets/PlayerPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/packets/PlayerPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14to1_13_2.packets; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/packets/WorldPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/packets/WorldPackets.java index ad7317032..aeb2cdc63 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/packets/WorldPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/packets/WorldPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14to1_13_2.packets; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/storage/EntityTracker1_14.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/storage/EntityTracker1_14.java index 2691a3745..ae03e1b3a 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/storage/EntityTracker1_14.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/storage/EntityTracker1_14.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14to1_13_2.storage; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/types/Chunk1_14Type.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/types/Chunk1_14Type.java index 240cdbc05..77ac65486 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/types/Chunk1_14Type.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_14to1_13_2/types/Chunk1_14Type.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_14to1_13_2.types; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15_1to1_15/Protocol1_15_1To1_15.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15_1to1_15/Protocol1_15_1To1_15.java index 93acae479..492509909 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15_1to1_15/Protocol1_15_1To1_15.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15_1to1_15/Protocol1_15_1To1_15.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_15_1to1_15; import us.myles.ViaVersion.api.protocol.Protocol; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15_2to1_15_1/Protocol1_15_2To1_15_1.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15_2to1_15_1/Protocol1_15_2To1_15_1.java index e140f3b1e..7a885069f 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15_2to1_15_1/Protocol1_15_2To1_15_1.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15_2to1_15_1/Protocol1_15_2To1_15_1.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_15_2to1_15_1; import us.myles.ViaVersion.api.protocol.Protocol; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/ClientboundPackets1_15.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/ClientboundPackets1_15.java index 2ec9a0170..3ac66c14d 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/ClientboundPackets1_15.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/ClientboundPackets1_15.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_15to1_14_4; import us.myles.ViaVersion.api.protocol.ClientboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/Protocol1_15To1_14_4.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/Protocol1_15To1_14_4.java index d612323dd..f5d6a9ba1 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/Protocol1_15To1_14_4.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/Protocol1_15To1_14_4.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_15to1_14_4; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/data/MappingData.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/data/MappingData.java index ed2d7f1be..7ccf3612e 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/data/MappingData.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/data/MappingData.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_15to1_14_4.data; import com.google.gson.JsonObject; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/metadata/MetadataRewriter1_15To1_14_4.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/metadata/MetadataRewriter1_15To1_14_4.java index 573b8d737..8a9f680c7 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/metadata/MetadataRewriter1_15To1_14_4.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/metadata/MetadataRewriter1_15To1_14_4.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_15to1_14_4.metadata; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/packets/EntityPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/packets/EntityPackets.java index 31c403213..ce5f9ad37 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/packets/EntityPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/packets/EntityPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_15to1_14_4.packets; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/packets/InventoryPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/packets/InventoryPackets.java index 5dcd6fa99..c6377b3f0 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/packets/InventoryPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/packets/InventoryPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_15to1_14_4.packets; import us.myles.ViaVersion.api.minecraft.item.Item; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/packets/PlayerPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/packets/PlayerPackets.java index 47020370d..7e7fab613 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/packets/PlayerPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/packets/PlayerPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_15to1_14_4.packets; import us.myles.ViaVersion.api.Via; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/packets/WorldPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/packets/WorldPackets.java index 0a3f0f8e6..0d9855afa 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/packets/WorldPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/packets/WorldPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_15to1_14_4.packets; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/storage/EntityTracker1_15.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/storage/EntityTracker1_15.java index 6917dde4a..152448775 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/storage/EntityTracker1_15.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/storage/EntityTracker1_15.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_15to1_14_4.storage; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/types/Chunk1_15Type.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/types/Chunk1_15Type.java index 718d33b8f..a188c49a6 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/types/Chunk1_15Type.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_15to1_14_4/types/Chunk1_15Type.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_15to1_14_4.types; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_1to1_16/Protocol1_16_1To1_16.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_1to1_16/Protocol1_16_1To1_16.java index 9be545f11..58b27ceaa 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_1to1_16/Protocol1_16_1To1_16.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_1to1_16/Protocol1_16_1To1_16.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16_1to1_16; import us.myles.ViaVersion.api.protocol.Protocol; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/ClientboundPackets1_16_2.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/ClientboundPackets1_16_2.java index 6b476922b..a1b8fddfc 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/ClientboundPackets1_16_2.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/ClientboundPackets1_16_2.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16_2to1_16_1; import us.myles.ViaVersion.api.protocol.ClientboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/Protocol1_16_2To1_16_1.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/Protocol1_16_2To1_16_1.java index 5b5cabb7f..f345f795c 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/Protocol1_16_2To1_16_1.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/Protocol1_16_2To1_16_1.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16_2to1_16_1; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/ServerboundPackets1_16_2.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/ServerboundPackets1_16_2.java index ae202c783..9e9a4c39a 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/ServerboundPackets1_16_2.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/ServerboundPackets1_16_2.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16_2to1_16_1; import us.myles.ViaVersion.api.protocol.ServerboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/data/MappingData.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/data/MappingData.java index 3d1961e55..e10bedb31 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/data/MappingData.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/data/MappingData.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16_2to1_16_1.data; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/metadata/MetadataRewriter1_16_2To1_16_1.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/metadata/MetadataRewriter1_16_2To1_16_1.java index e9531d168..f1c8d7a57 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/metadata/MetadataRewriter1_16_2To1_16_1.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/metadata/MetadataRewriter1_16_2To1_16_1.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16_2to1_16_1.metadata; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/packets/EntityPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/packets/EntityPackets.java index 33afe4943..1316fc363 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/packets/EntityPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/packets/EntityPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16_2to1_16_1.packets; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/packets/InventoryPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/packets/InventoryPackets.java index e1bfbb08f..5a7582cd5 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/packets/InventoryPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/packets/InventoryPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16_2to1_16_1.packets; import us.myles.ViaVersion.api.minecraft.item.Item; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/packets/WorldPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/packets/WorldPackets.java index ecbb08f0c..c75266ed8 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/packets/WorldPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/packets/WorldPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16_2to1_16_1.packets; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/storage/EntityTracker1_16_2.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/storage/EntityTracker1_16_2.java index 1133571db..5f51b60a4 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/storage/EntityTracker1_16_2.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/storage/EntityTracker1_16_2.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16_2to1_16_1.storage; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/types/Chunk1_16_2Type.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/types/Chunk1_16_2Type.java index 08d27bc95..3de21a139 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/types/Chunk1_16_2Type.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_2to1_16_1/types/Chunk1_16_2Type.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16_2to1_16_1.types; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_3to1_16_2/Protocol1_16_3To1_16_2.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_3to1_16_2/Protocol1_16_3To1_16_2.java index 8d38dd978..f3f8d7641 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_3to1_16_2/Protocol1_16_3To1_16_2.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_3to1_16_2/Protocol1_16_3To1_16_2.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16_3to1_16_2; import us.myles.ViaVersion.api.protocol.Protocol; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_4to1_16_3/Protocol1_16_4To1_16_3.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_4to1_16_3/Protocol1_16_4To1_16_3.java index ce98bb909..3e69b4a3b 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_4to1_16_3/Protocol1_16_4To1_16_3.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16_4to1_16_3/Protocol1_16_4To1_16_3.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16_4to1_16_3; import us.myles.ViaVersion.api.protocol.Protocol; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/ClientboundPackets1_16.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/ClientboundPackets1_16.java index 485c43b9a..e639ce474 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/ClientboundPackets1_16.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/ClientboundPackets1_16.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16to1_15_2; import us.myles.ViaVersion.api.protocol.ClientboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/Protocol1_16To1_15_2.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/Protocol1_16To1_15_2.java index d436fc91f..939e2328f 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/Protocol1_16To1_15_2.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/Protocol1_16To1_15_2.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16to1_15_2; import com.google.common.base.Joiner; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/ServerboundPackets1_16.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/ServerboundPackets1_16.java index 9cb91b26e..5a4041ec8 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/ServerboundPackets1_16.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/ServerboundPackets1_16.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16to1_15_2; import us.myles.ViaVersion.api.protocol.ServerboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/data/MappingData.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/data/MappingData.java index d6a798fe8..ee52abe3d 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/data/MappingData.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/data/MappingData.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16to1_15_2.data; import com.google.common.collect.BiMap; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/data/RecipeRewriter1_16.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/data/RecipeRewriter1_16.java index 2ebfc0304..8893a7b53 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/data/RecipeRewriter1_16.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/data/RecipeRewriter1_16.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16to1_15_2.data; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/data/TranslationMappings.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/data/TranslationMappings.java index 916313faa..2af5fe8c0 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/data/TranslationMappings.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/data/TranslationMappings.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16to1_15_2.data; import com.google.gson.JsonElement; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/metadata/MetadataRewriter1_16To1_15_2.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/metadata/MetadataRewriter1_16To1_15_2.java index 43cf49c60..16f5b24f4 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/metadata/MetadataRewriter1_16To1_15_2.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/metadata/MetadataRewriter1_16To1_15_2.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16to1_15_2.metadata; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/packets/EntityPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/packets/EntityPackets.java index 878e79280..de8507725 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/packets/EntityPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/packets/EntityPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16to1_15_2.packets; import com.github.steveice10.opennbt.tag.builtin.ByteTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/packets/InventoryPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/packets/InventoryPackets.java index 70ea2b87a..a2717c770 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/packets/InventoryPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/packets/InventoryPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16to1_15_2.packets; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/packets/WorldPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/packets/WorldPackets.java index 811cbbd5e..782b418ed 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/packets/WorldPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/packets/WorldPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16to1_15_2.packets; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/storage/EntityTracker1_16.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/storage/EntityTracker1_16.java index 18d3c560e..66099466d 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/storage/EntityTracker1_16.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/storage/EntityTracker1_16.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16to1_15_2.storage; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/storage/InventoryTracker1_16.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/storage/InventoryTracker1_16.java index d19501e9b..f140a501a 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/storage/InventoryTracker1_16.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/storage/InventoryTracker1_16.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16to1_15_2.storage; import us.myles.ViaVersion.api.data.StoredObject; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/types/Chunk1_16Type.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/types/Chunk1_16Type.java index c2e2d39c4..5ac6247b3 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/types/Chunk1_16Type.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_16to1_15_2/types/Chunk1_16Type.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_16to1_15_2.types; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/ClientboundPackets1_17.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/ClientboundPackets1_17.java index aa8c2978f..389f88c24 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/ClientboundPackets1_17.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/ClientboundPackets1_17.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_17to1_16_4; import us.myles.ViaVersion.api.protocol.ClientboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/Protocol1_17To1_16_4.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/Protocol1_17To1_16_4.java index 026c3c3dc..9d5bb51b4 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/Protocol1_17To1_16_4.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/Protocol1_17To1_16_4.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_17to1_16_4; import org.jetbrains.annotations.Nullable; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/ServerboundPackets1_17.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/ServerboundPackets1_17.java index 4808b068b..3cef71e60 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/ServerboundPackets1_17.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/ServerboundPackets1_17.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_17to1_16_4; import us.myles.ViaVersion.api.protocol.ServerboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/metadata/MetadataRewriter1_17To1_16_4.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/metadata/MetadataRewriter1_17To1_16_4.java index 191d19021..b171906e6 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/metadata/MetadataRewriter1_17To1_16_4.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/metadata/MetadataRewriter1_17To1_16_4.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_17to1_16_4.metadata; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/packets/EntityPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/packets/EntityPackets.java index 5d9e243e6..590de5431 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/packets/EntityPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/packets/EntityPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_17to1_16_4.packets; import us.myles.ViaVersion.api.entities.Entity1_17Types; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/packets/InventoryPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/packets/InventoryPackets.java index 7edc25319..d77181964 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/packets/InventoryPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/packets/InventoryPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_17to1_16_4.packets; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/packets/WorldPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/packets/WorldPackets.java index 56591d575..514a86401 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/packets/WorldPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/packets/WorldPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_17to1_16_4.packets; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/storage/BiomeStorage.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/storage/BiomeStorage.java index 869b8080a..24b631237 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/storage/BiomeStorage.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/storage/BiomeStorage.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_17to1_16_4.storage; import org.jetbrains.annotations.Nullable; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/storage/EntityTracker1_17.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/storage/EntityTracker1_17.java index 2693b6b0b..f5b5971b3 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/storage/EntityTracker1_17.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/storage/EntityTracker1_17.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_17to1_16_4.storage; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/types/Chunk1_17Type.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/types/Chunk1_17Type.java index 50ebb76f1..351c5aa76 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/types/Chunk1_17Type.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_17to1_16_4/types/Chunk1_17Type.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_17to1_16_4.types; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_8/ClientboundPackets1_8.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_8/ClientboundPackets1_8.java index 962162ab7..432691511 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_8/ClientboundPackets1_8.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_8/ClientboundPackets1_8.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_8; import us.myles.ViaVersion.api.protocol.ClientboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_8/ServerboundPackets1_8.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_8/ServerboundPackets1_8.java index 85b339d2c..bba61e8fa 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_8/ServerboundPackets1_8.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_8/ServerboundPackets1_8.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_8; import us.myles.ViaVersion.api.protocol.ServerboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_1_2to1_9_3_4/Protocol1_9_1_2To1_9_3_4.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_1_2to1_9_3_4/Protocol1_9_1_2To1_9_3_4.java index 1401659b4..4c1195c2e 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_1_2to1_9_3_4/Protocol1_9_1_2To1_9_3_4.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_1_2to1_9_3_4/Protocol1_9_1_2To1_9_3_4.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9_1_2to1_9_3_4; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_1_2to1_9_3_4/chunks/BlockEntity.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_1_2to1_9_3_4/chunks/BlockEntity.java index ace9d85bc..c24e1bf7d 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_1_2to1_9_3_4/chunks/BlockEntity.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_1_2to1_9_3_4/chunks/BlockEntity.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9_1_2to1_9_3_4.chunks; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_1_2to1_9_3_4/types/Chunk1_9_3_4Type.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_1_2to1_9_3_4/types/Chunk1_9_3_4Type.java index 00047fe90..535b3eeb8 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_1_2to1_9_3_4/types/Chunk1_9_3_4Type.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_1_2to1_9_3_4/types/Chunk1_9_3_4Type.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9_1_2to1_9_3_4.types; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_1to1_9/Protocol1_9_1To1_9.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_1to1_9/Protocol1_9_1To1_9.java index 45be14ce7..e2d53f516 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_1to1_9/Protocol1_9_1To1_9.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_1to1_9/Protocol1_9_1To1_9.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9_1to1_9; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/ClientboundPackets1_9_3.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/ClientboundPackets1_9_3.java index 77558b97f..a8c0fa215 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/ClientboundPackets1_9_3.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/ClientboundPackets1_9_3.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9_3to1_9_1_2; import us.myles.ViaVersion.api.protocol.ClientboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/Protocol1_9_3To1_9_1_2.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/Protocol1_9_3To1_9_1_2.java index d080bb1a1..7c5d04b21 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/Protocol1_9_3To1_9_1_2.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/Protocol1_9_3To1_9_1_2.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9_3to1_9_1_2; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/ServerboundPackets1_9_3.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/ServerboundPackets1_9_3.java index f20e4f55e..2ef8c340a 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/ServerboundPackets1_9_3.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/ServerboundPackets1_9_3.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9_3to1_9_1_2; import us.myles.ViaVersion.api.protocol.ServerboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/chunks/FakeTileEntity.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/chunks/FakeTileEntity.java index 8f26d24dc..1a8090223 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/chunks/FakeTileEntity.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/chunks/FakeTileEntity.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9_3to1_9_1_2.chunks; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/storage/ClientWorld.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/storage/ClientWorld.java index 6131e9d12..dd0f2c4e2 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/storage/ClientWorld.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/storage/ClientWorld.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9_3to1_9_1_2.storage; import us.myles.ViaVersion.api.data.StoredObject; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/types/Chunk1_9_1_2Type.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/types/Chunk1_9_1_2Type.java index 6b123ae50..ab242e789 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/types/Chunk1_9_1_2Type.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9_3to1_9_1_2/types/Chunk1_9_1_2Type.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9_3to1_9_1_2.types; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ArmorType.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ArmorType.java index f302dbe88..2c04a0a3b 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ArmorType.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ArmorType.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8; import java.util.HashMap; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ClientboundPackets1_9.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ClientboundPackets1_9.java index 65b566467..4296d9f67 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ClientboundPackets1_9.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ClientboundPackets1_9.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8; import us.myles.ViaVersion.api.protocol.ClientboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ItemRewriter.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ItemRewriter.java index c4e77a067..e24d9e778 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ItemRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ItemRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/PlayerMovementMapper.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/PlayerMovementMapper.java index ed080865f..fe2c5276f 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/PlayerMovementMapper.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/PlayerMovementMapper.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/Protocol1_9To1_8.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/Protocol1_9To1_8.java index ce0516b6a..2826d7d53 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/Protocol1_9To1_8.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/Protocol1_9To1_8.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8; import com.google.gson.JsonElement; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ServerboundPackets1_9.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ServerboundPackets1_9.java index fd2ae5781..9d820aa48 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ServerboundPackets1_9.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ServerboundPackets1_9.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8; import us.myles.ViaVersion.api.protocol.ServerboundPacketType; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ViaIdleThread.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ViaIdleThread.java index 6d77c3ee4..0d405b4fd 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ViaIdleThread.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/ViaIdleThread.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8; import us.myles.ViaVersion.api.Via; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/chat/ChatRewriter.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/chat/ChatRewriter.java index 4215a01a1..916d8f408 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/chat/ChatRewriter.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/chat/ChatRewriter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.chat; import com.google.gson.JsonArray; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/chat/GameMode.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/chat/GameMode.java index cb69ee7d3..4992df231 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/chat/GameMode.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/chat/GameMode.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.chat; public enum GameMode { diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/metadata/MetaIndex.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/metadata/MetaIndex.java index 1769c6a8f..54e6ac7e3 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/metadata/MetaIndex.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/metadata/MetaIndex.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.metadata; import us.myles.ViaVersion.api.Pair; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/metadata/MetadataRewriter1_9To1_8.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/metadata/MetadataRewriter1_9To1_8.java index 4fab7b1cb..6bb2ee462 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/metadata/MetadataRewriter1_9To1_8.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/metadata/MetadataRewriter1_9To1_8.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.metadata; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/EntityPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/EntityPackets.java index 128236ec2..f5683d34a 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/EntityPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/EntityPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.packets; import com.google.common.collect.ImmutableList; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/InventoryPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/InventoryPackets.java index a3eaeb03c..93e30fb3c 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/InventoryPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/InventoryPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.packets; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/PlayerPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/PlayerPackets.java index 2d3c594fd..be276950d 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/PlayerPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/PlayerPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.packets; import com.google.gson.JsonObject; @@ -9,7 +26,6 @@ import us.myles.ViaVersion.api.remapper.PacketHandler; import us.myles.ViaVersion.api.remapper.PacketRemapper; import us.myles.ViaVersion.api.remapper.ValueCreator; import us.myles.ViaVersion.api.type.Type; -import us.myles.ViaVersion.protocols.base.ProtocolInfo; import us.myles.ViaVersion.protocols.protocol1_8.ClientboundPackets1_8; import us.myles.ViaVersion.protocols.protocol1_9to1_8.ItemRewriter; import us.myles.ViaVersion.protocols.protocol1_9to1_8.PlayerMovementMapper; @@ -21,7 +37,6 @@ import us.myles.ViaVersion.protocols.protocol1_9to1_8.providers.CommandBlockProv import us.myles.ViaVersion.protocols.protocol1_9to1_8.providers.MainHandProvider; import us.myles.ViaVersion.protocols.protocol1_9to1_8.storage.ClientChunks; import us.myles.ViaVersion.protocols.protocol1_9to1_8.storage.EntityTracker1_9; -import us.myles.ViaVersion.util.GsonUtil; public class PlayerPackets { public static void register(Protocol1_9To1_8 protocol) { diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/SpawnPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/SpawnPackets.java index 072b35088..56f30c41f 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/SpawnPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/SpawnPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.packets; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/WorldPackets.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/WorldPackets.java index 17dd515e9..e137e4f4c 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/WorldPackets.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/packets/WorldPackets.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.packets; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/BossBarProvider.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/BossBarProvider.java index 2890d1d4b..aa6bb5357 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/BossBarProvider.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/BossBarProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.providers; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/BulkChunkTranslatorProvider.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/BulkChunkTranslatorProvider.java index 1eaf59ba9..a6ffd125a 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/BulkChunkTranslatorProvider.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/BulkChunkTranslatorProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.providers; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/CommandBlockProvider.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/CommandBlockProvider.java index 1dd81abba..90c78619e 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/CommandBlockProvider.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/CommandBlockProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.providers; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/EntityIdProvider.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/EntityIdProvider.java index 6111e1b8f..d9d6f346d 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/EntityIdProvider.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/EntityIdProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.providers; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/HandItemProvider.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/HandItemProvider.java index 3f9aef55b..2ee573159 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/HandItemProvider.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/HandItemProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.providers; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/MainHandProvider.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/MainHandProvider.java index 4735eadb8..aa91e844e 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/MainHandProvider.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/MainHandProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.providers; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/MovementTransmitterProvider.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/MovementTransmitterProvider.java index 311859e90..8921cc7b8 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/MovementTransmitterProvider.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/providers/MovementTransmitterProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.providers; import io.netty.channel.ChannelHandlerContext; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/sounds/Effect.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/sounds/Effect.java index fb16e9cc7..3d9bcc41f 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/sounds/Effect.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/sounds/Effect.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.sounds; import it.unimi.dsi.fastutil.ints.Int2IntMap; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/sounds/SoundCategory.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/sounds/SoundCategory.java index 23b52e2f3..d0b75c9fe 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/sounds/SoundCategory.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/sounds/SoundCategory.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.sounds; public enum SoundCategory { diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/sounds/SoundEffect.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/sounds/SoundEffect.java index 5f4c04a84..f9a0eb35d 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/sounds/SoundEffect.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/sounds/SoundEffect.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.sounds; import java.util.HashMap; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/ClientChunks.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/ClientChunks.java index aab46341f..5e4e01eab 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/ClientChunks.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/ClientChunks.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.storage; import com.google.common.collect.Sets; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/CommandBlockStorage.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/CommandBlockStorage.java index 05d5cc102..463d0689f 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/CommandBlockStorage.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/CommandBlockStorage.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.storage; import com.github.steveice10.opennbt.tag.builtin.ByteTag; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/EntityTracker1_9.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/EntityTracker1_9.java index f92904185..41b808869 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/EntityTracker1_9.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/EntityTracker1_9.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.storage; import com.google.common.cache.CacheBuilder; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/InventoryTracker.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/InventoryTracker.java index 0f2f443bc..0d5566e79 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/InventoryTracker.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/InventoryTracker.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.storage; import us.myles.ViaVersion.api.data.StoredObject; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/MovementTracker.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/MovementTracker.java index d56726d73..e4ff9d715 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/MovementTracker.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/MovementTracker.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.storage; import us.myles.ViaVersion.api.data.StoredObject; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/PlaceBlockTracker.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/PlaceBlockTracker.java index 95c93854f..efe4d046a 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/PlaceBlockTracker.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/storage/PlaceBlockTracker.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.storage; import us.myles.ViaVersion.api.data.StoredObject; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/types/Chunk1_9to1_8Type.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/types/Chunk1_9to1_8Type.java index 92b0a0cdb..e2a46f215 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/types/Chunk1_9to1_8Type.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_8/types/Chunk1_9to1_8Type.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_8.types; import com.github.steveice10.opennbt.tag.builtin.CompoundTag; @@ -10,7 +27,6 @@ import us.myles.ViaVersion.api.type.Type; import us.myles.ViaVersion.api.type.types.minecraft.BaseChunkType; import us.myles.ViaVersion.api.type.types.version.Types1_8; import us.myles.ViaVersion.api.type.types.version.Types1_9; -import us.myles.ViaVersion.protocols.base.ProtocolInfo; import us.myles.ViaVersion.protocols.protocol1_10to1_9_3.Protocol1_10To1_9_3_4; import us.myles.ViaVersion.api.minecraft.chunks.Chunk1_8; import us.myles.ViaVersion.protocols.protocol1_9to1_8.storage.ClientChunks; diff --git a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_9_1/Protocol1_9To1_9_1.java b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_9_1/Protocol1_9To1_9_1.java index dab2a898b..e5c1f11d5 100644 --- a/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_9_1/Protocol1_9To1_9_1.java +++ b/common/src/main/java/us/myles/ViaVersion/protocols/protocol1_9to1_9_1/Protocol1_9To1_9_1.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.protocols.protocol1_9to1_9_1; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/common/src/main/java/us/myles/ViaVersion/update/UpdateUtil.java b/common/src/main/java/us/myles/ViaVersion/update/UpdateUtil.java index 9d989dde5..1fca4456c 100644 --- a/common/src/main/java/us/myles/ViaVersion/update/UpdateUtil.java +++ b/common/src/main/java/us/myles/ViaVersion/update/UpdateUtil.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.update; import com.google.gson.JsonObject; diff --git a/common/src/main/java/us/myles/ViaVersion/update/Version.java b/common/src/main/java/us/myles/ViaVersion/update/Version.java index 7812a1c1c..61f234b7d 100644 --- a/common/src/main/java/us/myles/ViaVersion/update/Version.java +++ b/common/src/main/java/us/myles/ViaVersion/update/Version.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.update; import com.google.common.base.Joiner; diff --git a/common/src/main/java/us/myles/ViaVersion/util/CommentStore.java b/common/src/main/java/us/myles/ViaVersion/util/CommentStore.java index 33acbe4c8..96a7b89ef 100644 --- a/common/src/main/java/us/myles/ViaVersion/util/CommentStore.java +++ b/common/src/main/java/us/myles/ViaVersion/util/CommentStore.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.util; import com.google.common.base.Joiner; diff --git a/common/src/main/java/us/myles/ViaVersion/util/ConcurrentList.java b/common/src/main/java/us/myles/ViaVersion/util/ConcurrentList.java index 77c1dca85..cf0583f92 100644 --- a/common/src/main/java/us/myles/ViaVersion/util/ConcurrentList.java +++ b/common/src/main/java/us/myles/ViaVersion/util/ConcurrentList.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.util; import java.lang.reflect.Field; diff --git a/common/src/main/java/us/myles/ViaVersion/util/Config.java b/common/src/main/java/us/myles/ViaVersion/util/Config.java index b2d863f7f..12010816d 100644 --- a/common/src/main/java/us/myles/ViaVersion/util/Config.java +++ b/common/src/main/java/us/myles/ViaVersion/util/Config.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.util; import org.jetbrains.annotations.Nullable; diff --git a/common/src/main/java/us/myles/ViaVersion/util/ListWrapper.java b/common/src/main/java/us/myles/ViaVersion/util/ListWrapper.java index 9237fd8ce..9c1121f36 100644 --- a/common/src/main/java/us/myles/ViaVersion/util/ListWrapper.java +++ b/common/src/main/java/us/myles/ViaVersion/util/ListWrapper.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.util; import java.util.Collection; diff --git a/common/src/main/java/us/myles/ViaVersion/util/ReflectionUtil.java b/common/src/main/java/us/myles/ViaVersion/util/ReflectionUtil.java index f44622297..8096d7314 100644 --- a/common/src/main/java/us/myles/ViaVersion/util/ReflectionUtil.java +++ b/common/src/main/java/us/myles/ViaVersion/util/ReflectionUtil.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.util; import com.google.common.collect.Maps; diff --git a/common/src/main/java/us/myles/ViaVersion/util/YamlConstructor.java b/common/src/main/java/us/myles/ViaVersion/util/YamlConstructor.java index 4bc53061a..bf6be6d6c 100644 --- a/common/src/main/java/us/myles/ViaVersion/util/YamlConstructor.java +++ b/common/src/main/java/us/myles/ViaVersion/util/YamlConstructor.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.util; import org.yaml.snakeyaml.constructor.Constructor; diff --git a/common/src/test/java/us/myles/ViaVersion/common/entities/EntityTypesTest.java b/common/src/test/java/us/myles/ViaVersion/common/entities/EntityTypesTest.java index a7b98db9c..ad935795b 100644 --- a/common/src/test/java/us/myles/ViaVersion/common/entities/EntityTypesTest.java +++ b/common/src/test/java/us/myles/ViaVersion/common/entities/EntityTypesTest.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.common.entities; import org.junit.jupiter.api.Assertions; diff --git a/common/src/test/java/us/myles/ViaVersion/common/protocol/ProtocolVersionTest.java b/common/src/test/java/us/myles/ViaVersion/common/protocol/ProtocolVersionTest.java index facc0efab..7a28415dd 100644 --- a/common/src/test/java/us/myles/ViaVersion/common/protocol/ProtocolVersionTest.java +++ b/common/src/test/java/us/myles/ViaVersion/common/protocol/ProtocolVersionTest.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.common.protocol; import org.junit.jupiter.api.Assertions; diff --git a/common/src/test/java/us/myles/ViaVersion/common/type/ItemTypeTest.java b/common/src/test/java/us/myles/ViaVersion/common/type/ItemTypeTest.java index 645bc8cd0..58643124f 100644 --- a/common/src/test/java/us/myles/ViaVersion/common/type/ItemTypeTest.java +++ b/common/src/test/java/us/myles/ViaVersion/common/type/ItemTypeTest.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.common.type; import io.netty.buffer.ByteBuf; diff --git a/common/src/test/java/us/myles/ViaVersion/common/type/StringTypeTest.java b/common/src/test/java/us/myles/ViaVersion/common/type/StringTypeTest.java index 7af67906b..a86e11086 100644 --- a/common/src/test/java/us/myles/ViaVersion/common/type/StringTypeTest.java +++ b/common/src/test/java/us/myles/ViaVersion/common/type/StringTypeTest.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.common.type; import io.netty.buffer.ByteBuf; diff --git a/fabric/src/main/resources/fabric.mod.json b/fabric/src/main/resources/fabric.mod.json index d13b09fc7..edce65974 100644 --- a/fabric/src/main/resources/fabric.mod.json +++ b/fabric/src/main/resources/fabric.mod.json @@ -4,7 +4,7 @@ "name": "ViaVersion", "version": "${version}", "description": "${description}", - "license": "MIT", + "license": "GPL-3.0", "contact": { "homepage": "https://viaversion.com/", "issues": "https://github.com/ViaVersion/ViaVersion/issues", diff --git a/licenses/GPL.md b/licenses/GPL.md new file mode 100644 index 000000000..01a7a8018 --- /dev/null +++ b/licenses/GPL.md @@ -0,0 +1,675 @@ +### GNU GENERAL PUBLIC LICENSE + +Version 3, 29 June 2007 + +Copyright (C) 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 . \ No newline at end of file diff --git a/LICENSE.txt b/licenses/MIT.md similarity index 93% rename from LICENSE.txt rename to licenses/MIT.md index 81f990d60..735e2b199 100644 --- a/LICENSE.txt +++ b/licenses/MIT.md @@ -1,6 +1,6 @@ -MIT License +### MIT License -Copyright (c) 2020 +Copyright (c) 2016-2021 ViaVersion and contributors Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/settings.gradle.kts b/settings.gradle.kts index 810cdad71..54ca742dd 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -2,6 +2,7 @@ rootProject.name = "viaversion-parent" include("adventure") +setupViaSubproject("api") setupViaSubproject("common") setupViaSubproject("bukkit") setupViaSubproject("bukkit-legacy") diff --git a/sponge-legacy/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/ItemGrabber.java b/sponge-legacy/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/ItemGrabber.java index 8f1069caa..cafdc5c98 100644 --- a/sponge-legacy/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/ItemGrabber.java +++ b/sponge-legacy/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/ItemGrabber.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.listeners.protocol1_9to1_8; import org.spongepowered.api.entity.living.player.Player; diff --git a/sponge-legacy/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/sponge4/Sponge4ArmorListener.java b/sponge-legacy/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/sponge4/Sponge4ArmorListener.java index bcd52044e..589730d45 100644 --- a/sponge-legacy/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/sponge4/Sponge4ArmorListener.java +++ b/sponge-legacy/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/sponge4/Sponge4ArmorListener.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.listeners.protocol1_9to1_8.sponge4; import org.spongepowered.api.Sponge; diff --git a/sponge-legacy/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/sponge4/Sponge4ItemGrabber.java b/sponge-legacy/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/sponge4/Sponge4ItemGrabber.java index 17da6eb35..c9252e9e8 100644 --- a/sponge-legacy/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/sponge4/Sponge4ItemGrabber.java +++ b/sponge-legacy/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/sponge4/Sponge4ItemGrabber.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.listeners.protocol1_9to1_8.sponge4; import org.spongepowered.api.entity.living.player.Player; diff --git a/sponge/src/main/java/us/myles/ViaVersion/SpongePlugin.java b/sponge/src/main/java/us/myles/ViaVersion/SpongePlugin.java index a6b2716dc..565fad0db 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/SpongePlugin.java +++ b/sponge/src/main/java/us/myles/ViaVersion/SpongePlugin.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion; import com.google.gson.JsonObject; @@ -71,7 +88,7 @@ public class SpongePlugin implements ViaPlatform { logger.info("ViaVersion " + getPluginVersion() + " is now loaded!"); // Init platform - Via.init(ViaManager.builder() + Via.init(ViaManagerImpl.builder() .platform(this) .commandHandler(commandHandler) .injector(new SpongeViaInjector()) @@ -87,12 +104,12 @@ public class SpongePlugin implements ViaPlatform { // Inject! logger.info("ViaVersion is injecting!"); - Via.getManager().init(); + ((ViaManagerImpl) Via.getManager()).init(); } @Listener public void onServerStop(GameStoppingServerEvent event) { - Via.getManager().destroy(); + ((ViaManagerImpl) Via.getManager()).destroy(); } @Override diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/commands/SpongeCommandHandler.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/commands/SpongeCommandHandler.java index 1207f0b70..649b2c73c 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/commands/SpongeCommandHandler.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/commands/SpongeCommandHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.commands; import org.jetbrains.annotations.Nullable; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/commands/SpongeCommandSender.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/commands/SpongeCommandSender.java index d6dd6606e..75aba21a5 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/commands/SpongeCommandSender.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/commands/SpongeCommandSender.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.commands; import org.spongepowered.api.command.CommandSource; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/handlers/SpongeChannelInitializer.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/handlers/SpongeChannelInitializer.java index c27c2a771..c33439765 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/handlers/SpongeChannelInitializer.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/handlers/SpongeChannelInitializer.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.handlers; import io.netty.channel.Channel; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/handlers/SpongeDecodeHandler.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/handlers/SpongeDecodeHandler.java index 975a62896..cf36bbc09 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/handlers/SpongeDecodeHandler.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/handlers/SpongeDecodeHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.handlers; import io.netty.buffer.ByteBuf; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/handlers/SpongeEncodeHandler.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/handlers/SpongeEncodeHandler.java index d6d3b0240..4c69e3465 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/handlers/SpongeEncodeHandler.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/handlers/SpongeEncodeHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.handlers; import io.netty.buffer.ByteBuf; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/handlers/SpongePacketHandler.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/handlers/SpongePacketHandler.java index 220d34f78..ceb311c58 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/handlers/SpongePacketHandler.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/handlers/SpongePacketHandler.java @@ -1,10 +1,26 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.handlers; import io.netty.buffer.ByteBuf; import io.netty.channel.ChannelHandlerContext; import io.netty.handler.codec.MessageToMessageEncoder; import us.myles.ViaVersion.api.data.UserConnection; -import us.myles.ViaVersion.protocols.base.ProtocolInfo; import java.util.List; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/UpdateListener.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/UpdateListener.java index 010570a63..e127932b9 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/UpdateListener.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/UpdateListener.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.listeners; import org.spongepowered.api.event.Listener; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/ViaSpongeListener.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/ViaSpongeListener.java index 637f12a73..3b42276b3 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/ViaSpongeListener.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/ViaSpongeListener.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.listeners; import org.spongepowered.api.Sponge; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/BlockListener.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/BlockListener.java index b5c0b75ee..356767af5 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/BlockListener.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/BlockListener.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.listeners.protocol1_9to1_8; import org.spongepowered.api.entity.living.player.Player; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/DeathListener.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/DeathListener.java index f44e3bde1..01d9116e7 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/DeathListener.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/DeathListener.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.listeners.protocol1_9to1_8; import org.spongepowered.api.entity.living.player.Player; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/HandItemCache.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/HandItemCache.java index 694218d7d..5a1d0abef 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/HandItemCache.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/HandItemCache.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.listeners.protocol1_9to1_8; import org.spongepowered.api.Sponge; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/sponge5/Sponge5ArmorListener.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/sponge5/Sponge5ArmorListener.java index 24fe4c91b..7ab2ca2b8 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/sponge5/Sponge5ArmorListener.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/sponge5/Sponge5ArmorListener.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.listeners.protocol1_9to1_8.sponge5; import org.spongepowered.api.data.type.HandTypes; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/sponge5/Sponge5ItemGrabber.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/sponge5/Sponge5ItemGrabber.java index f9128ec86..8b612a7be 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/sponge5/Sponge5ItemGrabber.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/listeners/protocol1_9to1_8/sponge5/Sponge5ItemGrabber.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.listeners.protocol1_9to1_8.sponge5; import org.spongepowered.api.data.type.HandTypes; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeBossBar.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeBossBar.java index 3f0930ba4..3fdf8c54f 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeBossBar.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeBossBar.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.platform; import org.spongepowered.api.entity.living.player.Player; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeTaskId.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeTaskId.java index 4cae58f84..bc9caff03 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeTaskId.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeTaskId.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.platform; import org.spongepowered.api.scheduler.Task; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeViaAPI.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeViaAPI.java index 066b10aa9..ce7381d60 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeViaAPI.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeViaAPI.java @@ -1,49 +1,36 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.platform; import io.netty.buffer.ByteBuf; import org.spongepowered.api.entity.living.player.Player; -import us.myles.ViaVersion.api.Via; -import us.myles.ViaVersion.api.ViaAPI; +import us.myles.ViaVersion.api.ViaAPIBase; import us.myles.ViaVersion.api.boss.BossBar; import us.myles.ViaVersion.api.boss.BossColor; import us.myles.ViaVersion.api.boss.BossStyle; -import us.myles.ViaVersion.api.data.UserConnection; -import us.myles.ViaVersion.api.protocol.ProtocolRegistry; -import java.util.SortedSet; -import java.util.TreeSet; -import java.util.UUID; - -public class SpongeViaAPI implements ViaAPI { +public class SpongeViaAPI extends ViaAPIBase { @Override public int getPlayerVersion(Player player) { return getPlayerVersion(player.getUniqueId()); } - @Override - public int getPlayerVersion(UUID uuid) { - UserConnection connection = Via.getManager().getConnection(uuid); - return connection != null ? connection.getProtocolInfo().getProtocolVersion() : -1; - } - - @Override - public boolean isInjected(UUID playerUUID) { - return Via.getManager().isClientConnected(playerUUID); - } - - @Override - public String getVersion() { - return Via.getPlatform().getPluginVersion(); - } - - @Override - public void sendRawPacket(UUID uuid, ByteBuf packet) throws IllegalArgumentException { - if (!isInjected(uuid)) throw new IllegalArgumentException("This player is not controlled by ViaVersion!"); - UserConnection ci = Via.getManager().getConnection(uuid); - ci.sendRawPacket(packet); - } - @Override public void sendRawPacket(Player player, ByteBuf packet) throws IllegalArgumentException { sendRawPacket(player.getUniqueId(), packet); @@ -58,12 +45,4 @@ public class SpongeViaAPI implements ViaAPI { public BossBar createBossBar(String title, float health, BossColor color, BossStyle style) { return new SpongeBossBar(title, health, color, style); } - - @Override - public SortedSet getSupportedVersions() { - SortedSet outputSet = new TreeSet<>(ProtocolRegistry.getSupportedVersions()); - outputSet.removeAll(Via.getPlatform().getConf().getBlockedProtocols()); - - return outputSet; - } } diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeViaConfig.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeViaConfig.java index 1c218cade..c873cfe29 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeViaConfig.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeViaConfig.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.platform; import org.spongepowered.api.asset.Asset; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeViaInjector.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeViaInjector.java index 284ad0d24..656a18ce4 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeViaInjector.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeViaInjector.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.platform; import com.google.gson.JsonArray; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeViaLoader.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeViaLoader.java index ce04c477a..a3b7ec3a0 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeViaLoader.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/platform/SpongeViaLoader.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.platform; import org.spongepowered.api.Sponge; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/providers/SpongeViaBulkChunkTranslator.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/providers/SpongeViaBulkChunkTranslator.java index 04bc61172..04c47be76 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/providers/SpongeViaBulkChunkTranslator.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/providers/SpongeViaBulkChunkTranslator.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.providers; import com.google.common.collect.Lists; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/providers/SpongeViaMovementTransmitter.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/providers/SpongeViaMovementTransmitter.java index 346b5f08b..49187e56d 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/providers/SpongeViaMovementTransmitter.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/providers/SpongeViaMovementTransmitter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.providers; import us.myles.ViaVersion.protocols.protocol1_9to1_8.providers.MovementTransmitterProvider; diff --git a/sponge/src/main/java/us/myles/ViaVersion/sponge/util/LoggerWrapper.java b/sponge/src/main/java/us/myles/ViaVersion/sponge/util/LoggerWrapper.java index 819019c8f..31a676dea 100644 --- a/sponge/src/main/java/us/myles/ViaVersion/sponge/util/LoggerWrapper.java +++ b/sponge/src/main/java/us/myles/ViaVersion/sponge/util/LoggerWrapper.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.sponge.util; import org.slf4j.Logger; diff --git a/velocity/src/main/java/us/myles/ViaVersion/VelocityPlugin.java b/velocity/src/main/java/us/myles/ViaVersion/VelocityPlugin.java index 6ecff9b6d..63dfdb81f 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/VelocityPlugin.java +++ b/velocity/src/main/java/us/myles/ViaVersion/VelocityPlugin.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion; import com.google.gson.JsonObject; @@ -73,7 +90,7 @@ public class VelocityPlugin implements ViaPlatform { conf = new VelocityViaConfig(configDir.toFile()); logger = new LoggerWrapper(loggerslf4j); connectionManager = new ViaConnectionManager(); - Via.init(ViaManager.builder() + Via.init(ViaManagerImpl.builder() .platform(this) .commandHandler(commandHandler) .loader(new VelocityViaLoader()) @@ -86,7 +103,7 @@ public class VelocityPlugin implements ViaPlatform { @Subscribe(order = PostOrder.LAST) public void onProxyLateInit(ProxyInitializeEvent e) { - Via.getManager().init(); + ((ViaManagerImpl) Via.getManager()).init(); } @Override diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/command/VelocityCommandHandler.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/command/VelocityCommandHandler.java index 3a60557a9..872cc7144 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/command/VelocityCommandHandler.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/command/VelocityCommandHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.command; import com.velocitypowered.api.command.SimpleCommand; diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/command/VelocityCommandSender.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/command/VelocityCommandSender.java index aad6e8fdd..1a9ff13f4 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/command/VelocityCommandSender.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/command/VelocityCommandSender.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.command; import com.velocitypowered.api.command.CommandSource; diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/command/subs/ProbeSubCmd.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/command/subs/ProbeSubCmd.java index 1470f49f1..3e57e3890 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/command/subs/ProbeSubCmd.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/command/subs/ProbeSubCmd.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.command.subs; import us.myles.ViaVersion.api.Via; diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/handlers/VelocityChannelInitializer.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/handlers/VelocityChannelInitializer.java index d4674ecfd..13b636b47 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/handlers/VelocityChannelInitializer.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/handlers/VelocityChannelInitializer.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.handlers; import io.netty.channel.Channel; diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/handlers/VelocityDecodeHandler.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/handlers/VelocityDecodeHandler.java index 69e0f47f1..d83b6ed56 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/handlers/VelocityDecodeHandler.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/handlers/VelocityDecodeHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.handlers; import io.netty.buffer.ByteBuf; diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/handlers/VelocityEncodeHandler.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/handlers/VelocityEncodeHandler.java index 0d8cf4276..0aefe19c3 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/handlers/VelocityEncodeHandler.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/handlers/VelocityEncodeHandler.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.handlers; import io.netty.buffer.ByteBuf; diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/listeners/UpdateListener.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/listeners/UpdateListener.java index d12069810..f9a73b4c0 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/listeners/UpdateListener.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/listeners/UpdateListener.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.listeners; import com.velocitypowered.api.event.Subscribe; diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityBossBar.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityBossBar.java index 46a767c6a..91e03afff 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityBossBar.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityBossBar.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.platform; import com.velocitypowered.api.proxy.Player; diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityTaskId.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityTaskId.java index 1df49c27e..5139b9d7e 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityTaskId.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityTaskId.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.platform; import com.velocitypowered.api.scheduler.ScheduledTask; diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityViaAPI.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityViaAPI.java index dff032f6b..50cbc3eae 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityViaAPI.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityViaAPI.java @@ -1,49 +1,36 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.platform; import com.velocitypowered.api.proxy.Player; import io.netty.buffer.ByteBuf; -import us.myles.ViaVersion.api.Via; -import us.myles.ViaVersion.api.ViaAPI; +import us.myles.ViaVersion.api.ViaAPIBase; import us.myles.ViaVersion.api.boss.BossBar; import us.myles.ViaVersion.api.boss.BossColor; import us.myles.ViaVersion.api.boss.BossStyle; -import us.myles.ViaVersion.api.data.UserConnection; -import us.myles.ViaVersion.api.protocol.ProtocolRegistry; -import java.util.SortedSet; -import java.util.TreeSet; -import java.util.UUID; - -public class VelocityViaAPI implements ViaAPI { +public class VelocityViaAPI extends ViaAPIBase { @Override public int getPlayerVersion(Player player) { return getPlayerVersion(player.getUniqueId()); } - @Override - public int getPlayerVersion(UUID uuid) { - UserConnection connection = Via.getManager().getConnection(uuid); - return connection != null ? connection.getProtocolInfo().getProtocolVersion() : -1; - } - - @Override - public boolean isInjected(UUID playerUUID) { - return Via.getManager().isClientConnected(playerUUID); - } - - @Override - public String getVersion() { - return Via.getPlatform().getPluginVersion(); - } - - @Override - public void sendRawPacket(UUID uuid, ByteBuf packet) throws IllegalArgumentException { - if (!isInjected(uuid)) throw new IllegalArgumentException("This player is not controlled by ViaVersion!"); - UserConnection ci = Via.getManager().getConnection(uuid); - ci.sendRawPacket(packet); - } - @Override public void sendRawPacket(Player player, ByteBuf packet) throws IllegalArgumentException { sendRawPacket(player.getUniqueId(), packet); @@ -58,13 +45,4 @@ public class VelocityViaAPI implements ViaAPI { public BossBar createBossBar(String title, float health, BossColor color, BossStyle style) { return new VelocityBossBar(title, health, color, style); } - - @Override - public SortedSet getSupportedVersions() { - SortedSet outputSet = new TreeSet<>(ProtocolRegistry.getSupportedVersions()); - outputSet.removeAll(Via.getPlatform().getConf().getBlockedProtocols()); - - return outputSet; - } - } diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityViaConfig.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityViaConfig.java index 57246dfc2..5af39203f 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityViaConfig.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityViaConfig.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.platform; import us.myles.ViaVersion.AbstractViaConfig; diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityViaInjector.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityViaInjector.java index d9e0803ca..43a8d3f55 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityViaInjector.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityViaInjector.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.platform; import com.google.gson.JsonObject; diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityViaLoader.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityViaLoader.java index 2d635fa7c..f4a9336ff 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityViaLoader.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/platform/VelocityViaLoader.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.platform; import com.velocitypowered.api.plugin.PluginContainer; diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/providers/VelocityBossBarProvider.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/providers/VelocityBossBarProvider.java index 276d4b931..35266505c 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/providers/VelocityBossBarProvider.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/providers/VelocityBossBarProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.providers; import us.myles.ViaVersion.api.data.UserConnection; diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/providers/VelocityMovementTransmitter.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/providers/VelocityMovementTransmitter.java index 831b97653..99a6c5219 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/providers/VelocityMovementTransmitter.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/providers/VelocityMovementTransmitter.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.providers; import us.myles.ViaVersion.api.PacketWrapper; diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/providers/VelocityVersionProvider.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/providers/VelocityVersionProvider.java index 0fde41837..93b83ec01 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/providers/VelocityVersionProvider.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/providers/VelocityVersionProvider.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.providers; import com.velocitypowered.api.proxy.ServerConnection; @@ -6,7 +23,7 @@ import us.myles.ViaVersion.VelocityPlugin; import us.myles.ViaVersion.api.Via; import us.myles.ViaVersion.api.data.UserConnection; import us.myles.ViaVersion.api.protocol.ProtocolVersion; -import us.myles.ViaVersion.protocols.base.VersionProvider; +import us.myles.ViaVersion.protocols.base.BaseVersionProvider; import us.myles.ViaVersion.velocity.platform.VelocityViaInjector; import us.myles.ViaVersion.velocity.service.ProtocolDetectorService; @@ -14,7 +31,7 @@ import java.lang.reflect.Method; import java.util.Arrays; import java.util.stream.IntStream; -public class VelocityVersionProvider extends VersionProvider { +public class VelocityVersionProvider extends BaseVersionProvider { private static Method getAssociation; static { diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/service/ProtocolDetectorService.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/service/ProtocolDetectorService.java index c5363c48f..d026f4e0d 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/service/ProtocolDetectorService.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/service/ProtocolDetectorService.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.service; import com.velocitypowered.api.proxy.server.RegisteredServer; diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/storage/VelocityStorage.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/storage/VelocityStorage.java index 9d43f3a1e..80ec3152a 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/storage/VelocityStorage.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/storage/VelocityStorage.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.storage; import com.velocitypowered.api.proxy.Player; diff --git a/velocity/src/main/java/us/myles/ViaVersion/velocity/util/LoggerWrapper.java b/velocity/src/main/java/us/myles/ViaVersion/velocity/util/LoggerWrapper.java index 60300e8c7..aa6190d8f 100644 --- a/velocity/src/main/java/us/myles/ViaVersion/velocity/util/LoggerWrapper.java +++ b/velocity/src/main/java/us/myles/ViaVersion/velocity/util/LoggerWrapper.java @@ -1,3 +1,20 @@ +/* + * This file is part of ViaVersion - https://github.com/ViaVersion/ViaVersion + * Copyright (C) 2016-2021 ViaVersion and contributors + * + * 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 . + */ package us.myles.ViaVersion.velocity.util; import org.slf4j.Logger;