diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index e84afdb5..869c5a8e 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,29 +1,37 @@ # How to contribute to EcoEnchants ## Codestyle + 1. The EcoEnchants checkstyle is in /config/checkstyle.xml + - The pull request must not have any checkstyle issues. - Every method and field must have a javadoc attached. 2. Use lombok wherever possible. + - As of 6.0.0, EcoEnchants is now built with lombok. - @Getter, @Setter, @ToString, @EqualsAndHashCode, @UtilityClass are the most important. 3. Use JetBrains annotations + - Every parameter should be annotated with @NotNull or @Nullable - Use @NotNull over lombok @NonNull 4. Imports + - No group (*) imports. - No static imports. ## Dependency Injection + - EcoEnchants uses Dependency Injection since 6.0.0. - Any calls to AbstractEcoPlugin#getInstance are code smells and should never be used unless **absolutely necessary**. - NamespacedKeys, FixedMetadataValues, Runnables, and Schedules should be managed using EcoEnchantsPlugin through DI. -- Any DI class should extend PluginDependent where possible. If the class extends another, then you **must** store the plugin instance in a private final variable called **plugin** with a private or protected getter. +- Any DI class should extend PluginDependent where possible. If the class extends another, then you **must** store the + plugin instance in a private final variable called **plugin** with a private or protected getter. ## Other + - All drops **must** be sent through a DropQueue - calls to World#dropItem will get your PR rejected. - EcoEnchants is built with java 8. Usage of J9+ will get your PR rejected. - Any non-plugin-specific changes **must** be made to eco-util, or core-proxy, rather than core-plugin. \ No newline at end of file diff --git a/LICENSE.md b/LICENSE.md index 6b111d16..0a74fe45 100644 --- a/LICENSE.md +++ b/LICENSE.md @@ -2,71 +2,52 @@ 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. +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 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. +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. +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. +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. +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. +(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. +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. +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 +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. +The precise terms and conditions for copying, distribution and modification follow. TERMS AND CONDITIONS @@ -74,142 +55,106 @@ modification follow. "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. +"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 +"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. +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. +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 "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. +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. +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. +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. +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 +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. +(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" 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 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. +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. +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. +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. +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. +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. +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 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. +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: +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. @@ -232,22 +177,17 @@ terms of section 4, provided that you also meet all of these conditions: 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. +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: +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 @@ -290,77 +230,55 @@ in one of these ways: 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 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. +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. +"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). +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. +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. +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. +"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. +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: +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 @@ -385,251 +303,182 @@ that material) supplement the terms of this License with terms: 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. +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. +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. +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). +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. +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. +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. +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 +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. +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. +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. +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" 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. +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. +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. +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 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. +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. +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. +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. +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. +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. +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 +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. +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. +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. +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. +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. +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. +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. +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) @@ -649,26 +498,21 @@ the "copyright" line and a pointer to where the full notice is found. 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: +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". +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 +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 +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 . diff --git a/README.md b/README.md index 40771224..9c164202 100644 --- a/README.md +++ b/README.md @@ -31,6 +31,7 @@ [![Compatibility](https://i.imgur.com/mlAGlKn.png)]() ## License -*Click here to read [the entire license](https://github.com/Auxilor/EcoEnchants/blob/master/LICENSE.md).* + +*Click here to read [the entire license](https://github.com/Auxilor/EcoEnchants/blob/master/LICENSE.md).* Distributing compiled versions of the plugin is not permitted. diff --git a/build.gradle b/build.gradle index 0c300c14..39de726d 100644 --- a/build.gradle +++ b/build.gradle @@ -49,7 +49,7 @@ allprojects { } dependencies { - compileOnly 'com.willfp:eco:4.3.1' + compileOnly 'com.willfp:eco:5.0.0' compileOnly 'org.jetbrains:annotations:19.0.0' diff --git a/eco-core/core-nms/v1_15_R1/build.gradle b/eco-core/core-nms/v1_15_R1/build.gradle deleted file mode 100644 index 52cdf754..00000000 --- a/eco-core/core-nms/v1_15_R1/build.gradle +++ /dev/null @@ -1,6 +0,0 @@ -group 'com.willfp' -version rootProject.version - -dependencies { - compileOnly 'org.spigotmc:spigot:1.15.2-R0.1-SNAPSHOT' -} \ No newline at end of file diff --git a/eco-core/core-nms/v1_15_R1/src/main/java/com/willfp/ecoenchants/proxy/v1_15_R1/FastGetEnchants.java b/eco-core/core-nms/v1_15_R1/src/main/java/com/willfp/ecoenchants/proxy/v1_15_R1/FastGetEnchants.java deleted file mode 100644 index 42b48d42..00000000 --- a/eco-core/core-nms/v1_15_R1/src/main/java/com/willfp/ecoenchants/proxy/v1_15_R1/FastGetEnchants.java +++ /dev/null @@ -1,53 +0,0 @@ -package com.willfp.ecoenchants.proxy.v1_15_R1; - -import com.willfp.ecoenchants.proxy.proxies.FastGetEnchantsProxy; -import net.minecraft.server.v1_15_R1.NBTBase; -import net.minecraft.server.v1_15_R1.NBTTagCompound; -import net.minecraft.server.v1_15_R1.NBTTagList; -import org.bukkit.craftbukkit.v1_15_R1.inventory.CraftItemStack; -import org.bukkit.craftbukkit.v1_15_R1.util.CraftNamespacedKey; -import org.bukkit.enchantments.Enchantment; -import org.bukkit.inventory.ItemStack; -import org.jetbrains.annotations.NotNull; - -import java.util.HashMap; -import java.util.Map; - -public final class FastGetEnchants implements FastGetEnchantsProxy { - @Override - public Map getEnchantmentsOnItem(@NotNull final ItemStack itemStack) { - net.minecraft.server.v1_15_R1.ItemStack nmsStack = CraftItemStack.asNMSCopy(itemStack); - NBTTagList enchantmentNBT = nmsStack.getEnchantments(); - HashMap foundEnchantments = new HashMap<>(); - - for (NBTBase base : enchantmentNBT) { - NBTTagCompound compound = (NBTTagCompound) base; - String key = compound.getString("id"); - int level = '\uffff' & compound.getShort("lvl"); - - Enchantment found = Enchantment.getByKey(CraftNamespacedKey.fromStringOrNull(key)); - if (found != null) { - foundEnchantments.put(found, level); - } - } - return foundEnchantments; - } - - @Override - public int getLevelOnItem(@NotNull final ItemStack itemStack, - @NotNull final Enchantment enchantment) { - net.minecraft.server.v1_15_R1.ItemStack nmsStack = CraftItemStack.asNMSCopy(itemStack); - NBTTagList enchantmentNBT = nmsStack.getEnchantments(); - - for (NBTBase base : enchantmentNBT) { - NBTTagCompound compound = (NBTTagCompound) base; - String key = compound.getString("id"); - if (!key.equals(enchantment.getKey().toString())) { - continue; - } - - return '\uffff' & compound.getShort("lvl"); - } - return 0; - } -} diff --git a/eco-core/core-nms/v1_15_R1/src/main/java/com/willfp/ecoenchants/proxy/v1_15_R1/OpenInventory.java b/eco-core/core-nms/v1_15_R1/src/main/java/com/willfp/ecoenchants/proxy/v1_15_R1/OpenInventory.java deleted file mode 100644 index 6b2a0dfb..00000000 --- a/eco-core/core-nms/v1_15_R1/src/main/java/com/willfp/ecoenchants/proxy/v1_15_R1/OpenInventory.java +++ /dev/null @@ -1,13 +0,0 @@ -package com.willfp.ecoenchants.proxy.v1_15_R1; - -import com.willfp.ecoenchants.proxy.proxies.OpenInventoryProxy; -import org.bukkit.craftbukkit.v1_15_R1.entity.CraftPlayer; -import org.bukkit.entity.Player; -import org.jetbrains.annotations.NotNull; - -public final class OpenInventory implements OpenInventoryProxy { - @Override - public Object getOpenInventory(@NotNull final Player player) { - return ((CraftPlayer) player).getHandle().activeContainer; - } -} diff --git a/eco-core/core-nms/v1_15_R1/src/main/java/com/willfp/ecoenchants/proxy/v1_15_R1/RepairCost.java b/eco-core/core-nms/v1_15_R1/src/main/java/com/willfp/ecoenchants/proxy/v1_15_R1/RepairCost.java deleted file mode 100644 index 8996a2e9..00000000 --- a/eco-core/core-nms/v1_15_R1/src/main/java/com/willfp/ecoenchants/proxy/v1_15_R1/RepairCost.java +++ /dev/null @@ -1,22 +0,0 @@ -package com.willfp.ecoenchants.proxy.v1_15_R1; - -import com.willfp.ecoenchants.proxy.proxies.RepairCostProxy; -import org.bukkit.craftbukkit.v1_15_R1.inventory.CraftItemStack; -import org.bukkit.inventory.ItemStack; -import org.jetbrains.annotations.NotNull; - -public final class RepairCost implements RepairCostProxy { - @Override - public ItemStack setRepairCost(@NotNull final ItemStack itemStack, - final int cost) { - net.minecraft.server.v1_15_R1.ItemStack nmsStack = CraftItemStack.asNMSCopy(itemStack); - nmsStack.setRepairCost(cost); - return CraftItemStack.asBukkitCopy(nmsStack); - } - - @Override - public int getRepairCost(@NotNull final ItemStack itemStack) { - net.minecraft.server.v1_15_R1.ItemStack nmsStack = CraftItemStack.asNMSCopy(itemStack); - return nmsStack.getRepairCost(); - } -} diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/EcoEnchantsPlugin.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/EcoEnchantsPlugin.java index f6f714e4..6694a388 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/EcoEnchantsPlugin.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/EcoEnchantsPlugin.java @@ -1,18 +1,19 @@ package com.willfp.ecoenchants; -import com.willfp.eco.util.bukkit.scheduling.TimedRunnable; -import com.willfp.eco.util.command.AbstractCommand; -import com.willfp.eco.util.display.DisplayModule; -import com.willfp.eco.util.drops.telekinesis.TelekinesisUtils; -import com.willfp.eco.util.integrations.IntegrationLoader; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; -import com.willfp.eco.util.protocollib.AbstractPacketAdapter; +import com.willfp.eco.core.AbstractPacketAdapter; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.command.AbstractCommand; +import com.willfp.eco.core.display.DisplayModule; +import com.willfp.eco.core.integrations.IntegrationLoader; +import com.willfp.eco.util.TelekinesisUtils; import com.willfp.ecoenchants.command.commands.CommandEcodebug; import com.willfp.ecoenchants.command.commands.CommandEcoreload; import com.willfp.ecoenchants.command.commands.CommandEnchantinfo; import com.willfp.ecoenchants.command.commands.CommandRandomenchant; import com.willfp.ecoenchants.command.tabcompleters.TabCompleterEnchantinfo; import com.willfp.ecoenchants.config.EcoEnchantsConfigs; +import com.willfp.ecoenchants.config.configs.RarityYml; +import com.willfp.ecoenchants.config.configs.TargetYml; import com.willfp.ecoenchants.display.EnchantDisplay; import com.willfp.ecoenchants.display.EnchantmentCache; import com.willfp.ecoenchants.enchantments.EcoEnchants; @@ -25,6 +26,7 @@ import com.willfp.ecoenchants.enchantments.support.obtaining.EnchantingListeners import com.willfp.ecoenchants.enchantments.support.obtaining.LootPopulator; import com.willfp.ecoenchants.enchantments.support.obtaining.VillagerListeners; import com.willfp.ecoenchants.enchantments.util.ItemConversions; +import com.willfp.ecoenchants.enchantments.util.TimedRunnable; import com.willfp.ecoenchants.enchantments.util.WatcherTriggers; import com.willfp.ecoenchants.integrations.essentials.EssentialsManager; import com.willfp.ecoenchants.integrations.essentials.plugins.IntegrationEssentials; @@ -42,19 +44,34 @@ import java.util.Arrays; import java.util.List; @SuppressWarnings("unused") -public class EcoEnchantsPlugin extends AbstractEcoPlugin { +public class EcoEnchantsPlugin extends EcoPlugin { /** * Instance of the plugin. */ @Getter private static EcoEnchantsPlugin instance; + /** + * Rarity.yml. + */ + @Getter + private final RarityYml rarityYml; + + /** + * Target.yml. + */ + @Getter + private final TargetYml targetYml; + /** * Internal constructor called by bukkit on plugin load. */ public EcoEnchantsPlugin() { super("EcoEnchants", 79573, 7666, "com.willfp.ecoenchants.proxy", "&a"); instance = this; + + rarityYml = new RarityYml(this); + targetYml = new TargetYml(this); } /** @@ -65,13 +82,13 @@ public class EcoEnchantsPlugin extends AbstractEcoPlugin { this.getExtensionLoader().loadExtensions(); if (this.getExtensionLoader().getLoadedExtensions().isEmpty()) { - this.getLog().info("&cNo extensions found"); + this.getLogger().info("&cNo extensions found"); } else { - this.getLog().info("Extensions Loaded:"); - this.getExtensionLoader().getLoadedExtensions().forEach(extension -> this.getLog().info("- " + extension.getName() + " v" + extension.getVersion())); + this.getLogger().info("Extensions Loaded:"); + this.getExtensionLoader().getLoadedExtensions().forEach(extension -> this.getLogger().info("- " + extension.getName() + " v" + extension.getVersion())); } - this.getLog().info(EcoEnchants.values().size() + " Enchantments Loaded"); + this.getLogger().info(EcoEnchants.values().size() + " Enchantments Loaded"); TelekinesisUtils.registerTest(player -> ProxyUtils.getProxy(FastGetEnchantsProxy.class).getLevelOnItem(player.getInventory().getItemInMainHand(), EcoEnchants.TELEKINESIS) > 0); } @@ -106,6 +123,8 @@ public class EcoEnchantsPlugin extends AbstractEcoPlugin { */ @Override public void onReload() { + targetYml.update(); + rarityYml.update(); ((EnchantDisplay) this.getDisplayModule()).update(); EcoEnchants.values().forEach((ecoEnchant -> { HandlerList.unregisterAll(ecoEnchant); diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/commands/CommandEcodebug.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/commands/CommandEcodebug.java index 58ba4e5b..98d407e0 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/commands/CommandEcodebug.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/commands/CommandEcodebug.java @@ -2,9 +2,9 @@ package com.willfp.ecoenchants.command.commands; import com.comphenix.protocol.ProtocolLibrary; import com.comphenix.protocol.events.ListenerPriority; -import com.willfp.eco.util.command.AbstractCommand; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; -import com.willfp.eco.util.proxy.ProxyConstants; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.command.AbstractCommand; +import com.willfp.eco.core.proxy.ProxyConstants; import com.willfp.ecoenchants.display.EnchantmentCache; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; @@ -32,7 +32,7 @@ public class CommandEcodebug extends AbstractCommand { * * @param plugin The plugin for the commands to listen for. */ - public CommandEcodebug(@NotNull final AbstractEcoPlugin plugin) { + public CommandEcodebug(@NotNull final EcoPlugin plugin) { super(plugin, "ecodebug", "ecoenchants.ecodebug", false); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/commands/CommandEcoreload.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/commands/CommandEcoreload.java index 9c5d2039..42705f5a 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/commands/CommandEcoreload.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/commands/CommandEcoreload.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.command.commands; -import com.willfp.eco.util.command.AbstractCommand; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.command.AbstractCommand; import org.bukkit.command.CommandSender; import org.jetbrains.annotations.NotNull; @@ -13,7 +13,7 @@ public class CommandEcoreload extends AbstractCommand { * * @param plugin The plugin for the commands to listen for. */ - public CommandEcoreload(@NotNull final AbstractEcoPlugin plugin) { + public CommandEcoreload(@NotNull final EcoPlugin plugin) { super(plugin, "ecoreload", "ecoenchants.reload", false); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/commands/CommandEnchantinfo.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/commands/CommandEnchantinfo.java index 84802634..05f7545c 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/commands/CommandEnchantinfo.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/commands/CommandEnchantinfo.java @@ -1,9 +1,9 @@ package com.willfp.ecoenchants.command.commands; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.command.AbstractCommand; +import com.willfp.eco.core.command.AbstractTabCompleter; import com.willfp.eco.util.StringUtils; -import com.willfp.eco.util.command.AbstractCommand; -import com.willfp.eco.util.command.AbstractTabCompleter; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; import com.willfp.ecoenchants.command.tabcompleters.TabCompleterEnchantinfo; import com.willfp.ecoenchants.display.EnchantmentCache; import com.willfp.ecoenchants.enchantments.EcoEnchant; @@ -26,7 +26,7 @@ public class CommandEnchantinfo extends AbstractCommand { * * @param plugin The plugin for the commands to listen for. */ - public CommandEnchantinfo(@NotNull final AbstractEcoPlugin plugin) { + public CommandEnchantinfo(@NotNull final EcoPlugin plugin) { super(plugin, "enchantinfo", "ecoenchants.enchantinfo", false); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/commands/CommandRandomenchant.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/commands/CommandRandomenchant.java index 021f6aea..3371010d 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/commands/CommandRandomenchant.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/commands/CommandRandomenchant.java @@ -1,8 +1,8 @@ package com.willfp.ecoenchants.command.commands; -import com.willfp.eco.util.command.AbstractCommand; -import com.willfp.eco.util.command.AbstractTabCompleter; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.command.AbstractCommand; +import com.willfp.eco.core.command.AbstractTabCompleter; import com.willfp.ecoenchants.command.tabcompleters.TabCompleterRandomEnchant; import com.willfp.ecoenchants.display.EnchantmentCache; import com.willfp.ecoenchants.enchantments.EcoEnchant; @@ -28,7 +28,7 @@ public class CommandRandomenchant extends AbstractCommand { * * @param plugin The plugin for the commands to listen for. */ - public CommandRandomenchant(@NotNull final AbstractEcoPlugin plugin) { + public CommandRandomenchant(@NotNull final EcoPlugin plugin) { super(plugin, "randomenchant", "ecoenchants.randomenchant", false); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/tabcompleters/TabCompleterEnchantinfo.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/tabcompleters/TabCompleterEnchantinfo.java index f400afaf..fc4bb9a2 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/tabcompleters/TabCompleterEnchantinfo.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/tabcompleters/TabCompleterEnchantinfo.java @@ -1,9 +1,9 @@ package com.willfp.ecoenchants.command.tabcompleters; +import com.willfp.eco.core.command.AbstractCommand; +import com.willfp.eco.core.command.AbstractTabCompleter; +import com.willfp.eco.core.config.ConfigUpdater; import com.willfp.eco.util.StringUtils; -import com.willfp.eco.util.command.AbstractCommand; -import com.willfp.eco.util.command.AbstractTabCompleter; -import com.willfp.eco.util.config.updating.annotations.ConfigUpdater; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import org.bukkit.ChatColor; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/tabcompleters/TabCompleterRandomEnchant.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/tabcompleters/TabCompleterRandomEnchant.java index 3f7a4a3f..4f32c00b 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/tabcompleters/TabCompleterRandomEnchant.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/command/tabcompleters/TabCompleterRandomEnchant.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.command.tabcompleters; -import com.willfp.eco.util.command.AbstractCommand; -import com.willfp.eco.util.command.AbstractTabCompleter; +import com.willfp.eco.core.command.AbstractCommand; +import com.willfp.eco.core.command.AbstractTabCompleter; import org.bukkit.Bukkit; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/EcoEnchantsConfigs.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/EcoEnchantsConfigs.java index bed3f484..c965f246 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/EcoEnchantsConfigs.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/EcoEnchantsConfigs.java @@ -1,9 +1,7 @@ package com.willfp.ecoenchants.config; -import com.willfp.eco.util.config.updating.annotations.ConfigUpdater; +import com.willfp.eco.core.config.ConfigUpdater; import com.willfp.ecoenchants.config.configs.EnchantmentConfig; -import com.willfp.ecoenchants.config.configs.Rarity; -import com.willfp.ecoenchants.config.configs.Target; import lombok.Getter; import lombok.experimental.UtilityClass; import org.jetbrains.annotations.NotNull; @@ -13,16 +11,6 @@ import java.util.Set; @UtilityClass public class EcoEnchantsConfigs { - /** - * target.yml. - */ - public static final Target TARGET = new Target(); - - /** - * rarity.yml. - */ - public static final Rarity RARITY = new Rarity(); - /** * All enchantment-specific configs. */ @@ -34,8 +22,6 @@ public class EcoEnchantsConfigs { */ @ConfigUpdater public void updateConfigs() { - TARGET.update(); - RARITY.update(); enchantmentConfigs.forEach(EnchantmentConfig::update); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/configs/EnchantmentConfig.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/configs/EnchantmentConfig.java index 6c74e44f..8246705a 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/configs/EnchantmentConfig.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/configs/EnchantmentConfig.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.config.configs; -import com.willfp.eco.util.config.ExtendableConfig; +import com.willfp.eco.core.config.ExtendableConfig; import com.willfp.ecoenchants.EcoEnchantsPlugin; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentRarity; @@ -92,10 +92,10 @@ public class EnchantmentConfig extends ExtendableConfig { return; } - this.config.set("name", this.getPlugin().getLangYml().getString("enchantments." + this.getName() + ".name")); - this.config.set("description", this.getPlugin().getLangYml().getString("enchantments." + this.getName() + ".description")); + this.set("name", this.getPlugin().getLangYml().getString("enchantments." + this.getName() + ".name")); + this.set("description", this.getPlugin().getLangYml().getString("enchantments." + this.getName() + ".description")); try { - this.config.save(this.getConfigFile()); + this.save(); } catch (IOException e) { e.printStackTrace(); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/configs/Rarity.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/configs/RarityYml.java similarity index 50% rename from eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/configs/Rarity.java rename to eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/configs/RarityYml.java index fa9f47ad..34d9cf5a 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/configs/Rarity.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/configs/RarityYml.java @@ -1,16 +1,19 @@ package com.willfp.ecoenchants.config.configs; -import com.willfp.eco.util.config.BaseConfig; -import com.willfp.ecoenchants.EcoEnchantsPlugin; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.config.BaseConfig; +import org.jetbrains.annotations.NotNull; import java.util.List; -public class Rarity extends BaseConfig { +public class RarityYml extends BaseConfig { /** * Instantiate rarity.yml. + * + * @param plugin Instance of EcoEnchants. */ - public Rarity() { - super("rarity", false, EcoEnchantsPlugin.getInstance()); + public RarityYml(@NotNull final EcoPlugin plugin) { + super("rarity", false, plugin); } /** diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/configs/Target.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/configs/TargetYml.java similarity index 76% rename from eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/configs/Target.java rename to eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/configs/TargetYml.java index a7ea1076..ec111488 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/configs/Target.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/config/configs/TargetYml.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.config.configs; -import com.willfp.eco.util.config.BaseConfig; -import com.willfp.ecoenchants.EcoEnchantsPlugin; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.config.BaseConfig; import org.bukkit.Material; import org.jetbrains.annotations.NotNull; @@ -9,12 +9,14 @@ import java.util.HashSet; import java.util.List; import java.util.Set; -public class Target extends BaseConfig { +public class TargetYml extends BaseConfig { /** * Instantiate target.yml. + * + * @param plugin Instance of EcoEnchants. */ - public Target() { - super("target", false, EcoEnchantsPlugin.getInstance()); + public TargetYml(@NotNull final EcoPlugin plugin) { + super("target", false, plugin); } /** diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/EnchantDisplay.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/EnchantDisplay.java index a9f6fd9c..7041160a 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/EnchantDisplay.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/EnchantDisplay.java @@ -1,11 +1,11 @@ package com.willfp.ecoenchants.display; import com.google.common.collect.Lists; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.display.Display; +import com.willfp.eco.core.display.DisplayModule; +import com.willfp.eco.core.display.DisplayPriority; import com.willfp.eco.util.NumberUtils; -import com.willfp.eco.util.display.Display; -import com.willfp.eco.util.display.DisplayModule; -import com.willfp.eco.util.display.DisplayPriority; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; import com.willfp.ecoenchants.display.options.DisplayOptions; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; @@ -60,7 +60,7 @@ public class EnchantDisplay extends DisplayModule { * * @param plugin Instance of EcoEnchants. */ - public EnchantDisplay(@NotNull final AbstractEcoPlugin plugin) { + public EnchantDisplay(@NotNull final EcoPlugin plugin) { super(plugin, DisplayPriority.HIGH); keySkip = this.getPlugin().getNamespacedKeyFactory().create("ecoenchantlore-skip"); legacyV = this.getPlugin().getNamespacedKeyFactory().create("ecoenchantlore-v"); diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/EnchantmentCache.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/EnchantmentCache.java index 4a646843..3e863bcd 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/EnchantmentCache.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/EnchantmentCache.java @@ -1,9 +1,8 @@ package com.willfp.ecoenchants.display; import com.google.common.collect.ImmutableMap; -import com.willfp.eco.util.config.updating.annotations.ConfigUpdater; -import com.willfp.eco.util.display.Display; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; +import com.willfp.eco.core.config.ConfigUpdater; +import com.willfp.eco.core.display.Display; import com.willfp.ecoenchants.EcoEnchantsPlugin; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; @@ -31,7 +30,7 @@ public class EnchantmentCache { /** * Instance of EcoEnchants. */ - public static final AbstractEcoPlugin PLUGIN = EcoEnchantsPlugin.getInstance(); + public static final EcoEnchantsPlugin PLUGIN = EcoEnchantsPlugin.getInstance(); /** * The physical cache. @@ -92,7 +91,7 @@ public class EnchantmentCache { Collections.singletonList(Display.PREFIX + "INVALID ENCHANTMENT: " + enchantment.getClass().getName()), EnchantmentType.NORMAL, EnchantmentRarity.getByName(PLUGIN.getConfigYml().getString("rarity.vanilla-rarity")) - )); + )); return; } @@ -185,11 +184,11 @@ public class EnchantmentCache { private final EnchantmentRarity rarity; private CacheEntry(@NotNull final Enchantment enchantment, - @NotNull final String name, - @NotNull final String rawName, - @NotNull final List description, - @NotNull final EnchantmentType type, - @NotNull final EnchantmentRarity rarity) { + @NotNull final String name, + @NotNull final String rawName, + @NotNull final List description, + @NotNull final EnchantmentType type, + @NotNull final EnchantmentRarity rarity) { this.enchantment = enchantment; this.name = name; this.rawName = rawName; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/DescriptionOptions.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/DescriptionOptions.java index f53b843c..48d20cfd 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/DescriptionOptions.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/DescriptionOptions.java @@ -1,8 +1,8 @@ package com.willfp.ecoenchants.display.options; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; import com.willfp.eco.util.StringUtils; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; import lombok.Getter; import org.jetbrains.annotations.NotNull; @@ -30,7 +30,7 @@ public class DescriptionOptions extends PluginDependent { * * @param plugin EcoEnchants. */ - public DescriptionOptions(@NotNull final AbstractEcoPlugin plugin) { + public DescriptionOptions(@NotNull final EcoPlugin plugin) { super(plugin); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/DisplayOptions.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/DisplayOptions.java index 576f1ebb..7574a820 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/DisplayOptions.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/DisplayOptions.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.display.options; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; import com.willfp.ecoenchants.display.options.sorting.EnchantmentSorter; import com.willfp.ecoenchants.display.options.sorting.SortParameters; import com.willfp.ecoenchants.display.options.sorting.SorterManager; @@ -19,42 +19,36 @@ import java.util.Set; import java.util.stream.Collectors; public class DisplayOptions extends PluginDependent { - /** - * The enchantment sorter being used. - */ - @Getter - private EnchantmentSorter sorter; - /** * The description options being used. */ @Getter private final DescriptionOptions descriptionOptions = new DescriptionOptions(this.getPlugin()); - /** * The enchantment level options being used. */ @Getter private final NumbersOptions numbersOptions = new NumbersOptions(this.getPlugin()); - /** * The shrink options being used. */ @Getter private final ShrinkOptions shrinkOptions = new ShrinkOptions(this.getPlugin()); - /** * The enchantment types, sorted according to config. */ @Getter private final List sortedTypes = new ArrayList<>(); - /** * The enchantment rarities, sorted according to config. */ @Getter private final List sortedRarities = new ArrayList<>(); - + /** + * The enchantment sorter being used. + */ + @Getter + private EnchantmentSorter sorter; /** * Allow reading enchantments from lore-based plugins. */ @@ -97,7 +91,7 @@ public class DisplayOptions extends PluginDependent { * @param plugin EcoEnchants. */ @ApiStatus.Internal - public DisplayOptions(@NotNull final AbstractEcoPlugin plugin) { + public DisplayOptions(@NotNull final EcoPlugin plugin) { super(plugin); update(); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/NumbersOptions.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/NumbersOptions.java index 0661faf9..227681f1 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/NumbersOptions.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/NumbersOptions.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.display.options; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; import lombok.Getter; import org.jetbrains.annotations.NotNull; @@ -25,7 +25,7 @@ public class NumbersOptions extends PluginDependent { * * @param plugin EcoEnchants. */ - public NumbersOptions(@NotNull final AbstractEcoPlugin plugin) { + public NumbersOptions(@NotNull final EcoPlugin plugin) { super(plugin); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/ShrinkOptions.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/ShrinkOptions.java index 4611e534..879b9e83 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/ShrinkOptions.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/ShrinkOptions.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.display.options; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; import lombok.Getter; import org.jetbrains.annotations.NotNull; @@ -29,7 +29,7 @@ public class ShrinkOptions extends PluginDependent { * * @param plugin EcoEnchants. */ - public ShrinkOptions(@NotNull final AbstractEcoPlugin plugin) { + public ShrinkOptions(@NotNull final EcoPlugin plugin) { super(plugin); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/SorterManager.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/SorterManager.java index ac08e750..6b2478a3 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/SorterManager.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/SorterManager.java @@ -23,6 +23,18 @@ public class SorterManager { */ private static final Set REGISTERED = new HashSet<>(); + static { + EcoEnchantsPlugin instance = EcoEnchantsPlugin.getInstance(); // Really dirty and janky. + REGISTERED.add(new AlphabeticSorter(instance)); + REGISTERED.add(new LengthSorter(instance)); + REGISTERED.add(new TypeAlphabeticSorter(instance)); + REGISTERED.add(new TypeLengthSorter(instance)); + REGISTERED.add(new RarityAlphabeticSorter(instance)); + REGISTERED.add(new RarityLengthSorter(instance)); + REGISTERED.add(new RarityTypeAlphabeticSorter(instance)); + REGISTERED.add(new RarityTypeLengthSorter(instance)); + } + /** * Get a sorter based off of parameters. *

@@ -37,16 +49,4 @@ public class SorterManager { .findFirst() .orElse(new AlphabeticSorter(EcoEnchantsPlugin.getInstance())); } - - static { - EcoEnchantsPlugin instance = EcoEnchantsPlugin.getInstance(); // Really dirty and janky. - REGISTERED.add(new AlphabeticSorter(instance)); - REGISTERED.add(new LengthSorter(instance)); - REGISTERED.add(new TypeAlphabeticSorter(instance)); - REGISTERED.add(new TypeLengthSorter(instance)); - REGISTERED.add(new RarityAlphabeticSorter(instance)); - REGISTERED.add(new RarityLengthSorter(instance)); - REGISTERED.add(new RarityTypeAlphabeticSorter(instance)); - REGISTERED.add(new RarityTypeLengthSorter(instance)); - } } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/AlphabeticSorter.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/AlphabeticSorter.java index 9c1ed69a..7e912849 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/AlphabeticSorter.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/AlphabeticSorter.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.display.options.sorting.implementations; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; import com.willfp.ecoenchants.display.EnchantmentCache; import com.willfp.ecoenchants.display.options.sorting.EnchantmentSorter; import com.willfp.ecoenchants.display.options.sorting.SortParameters; @@ -16,7 +16,7 @@ public class AlphabeticSorter extends PluginDependent implements EnchantmentSort * * @param plugin Instance of EcoEnchants. */ - public AlphabeticSorter(@NotNull final AbstractEcoPlugin plugin) { + public AlphabeticSorter(@NotNull final EcoPlugin plugin) { super(plugin); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/LengthSorter.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/LengthSorter.java index 6fc6f0bb..16578b3d 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/LengthSorter.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/LengthSorter.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.display.options.sorting.implementations; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; import com.willfp.ecoenchants.display.EnchantmentCache; import com.willfp.ecoenchants.display.options.sorting.EnchantmentSorter; import com.willfp.ecoenchants.display.options.sorting.SortParameters; @@ -17,7 +17,7 @@ public class LengthSorter extends PluginDependent implements EnchantmentSorter { * * @param plugin Instance of EcoEnchants. */ - public LengthSorter(@NotNull final AbstractEcoPlugin plugin) { + public LengthSorter(@NotNull final EcoPlugin plugin) { super(plugin); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/RarityAlphabeticSorter.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/RarityAlphabeticSorter.java index e61a9355..2d42e66a 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/RarityAlphabeticSorter.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/RarityAlphabeticSorter.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.display.options.sorting.implementations; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; import com.willfp.ecoenchants.display.EnchantDisplay; import com.willfp.ecoenchants.display.EnchantmentCache; import com.willfp.ecoenchants.display.options.sorting.EnchantmentSorter; @@ -18,7 +18,7 @@ public class RarityAlphabeticSorter extends PluginDependent implements Enchantme * * @param plugin Instance of EcoEnchants. */ - public RarityAlphabeticSorter(@NotNull final AbstractEcoPlugin plugin) { + public RarityAlphabeticSorter(@NotNull final EcoPlugin plugin) { super(plugin); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/RarityLengthSorter.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/RarityLengthSorter.java index e1225222..91d411fd 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/RarityLengthSorter.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/RarityLengthSorter.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.display.options.sorting.implementations; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; import com.willfp.ecoenchants.display.EnchantDisplay; import com.willfp.ecoenchants.display.EnchantmentCache; import com.willfp.ecoenchants.display.options.sorting.EnchantmentSorter; @@ -19,7 +19,7 @@ public class RarityLengthSorter extends PluginDependent implements EnchantmentSo * * @param plugin Instance of EcoEnchants. */ - public RarityLengthSorter(@NotNull final AbstractEcoPlugin plugin) { + public RarityLengthSorter(@NotNull final EcoPlugin plugin) { super(plugin); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/RarityTypeAlphabeticSorter.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/RarityTypeAlphabeticSorter.java index 7502ef1f..0fcd6f98 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/RarityTypeAlphabeticSorter.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/RarityTypeAlphabeticSorter.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.display.options.sorting.implementations; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; import com.willfp.ecoenchants.display.EnchantDisplay; import com.willfp.ecoenchants.display.EnchantmentCache; import com.willfp.ecoenchants.display.options.sorting.EnchantmentSorter; @@ -18,7 +18,7 @@ public class RarityTypeAlphabeticSorter extends PluginDependent implements Encha * * @param plugin Instance of EcoEnchants. */ - public RarityTypeAlphabeticSorter(@NotNull final AbstractEcoPlugin plugin) { + public RarityTypeAlphabeticSorter(@NotNull final EcoPlugin plugin) { super(plugin); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/RarityTypeLengthSorter.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/RarityTypeLengthSorter.java index 1632e889..256e1562 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/RarityTypeLengthSorter.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/RarityTypeLengthSorter.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.display.options.sorting.implementations; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; import com.willfp.ecoenchants.display.EnchantDisplay; import com.willfp.ecoenchants.display.EnchantmentCache; import com.willfp.ecoenchants.display.options.sorting.EnchantmentSorter; @@ -19,7 +19,7 @@ public class RarityTypeLengthSorter extends PluginDependent implements Enchantme * * @param plugin Instance of EcoEnchants. */ - public RarityTypeLengthSorter(@NotNull final AbstractEcoPlugin plugin) { + public RarityTypeLengthSorter(@NotNull final EcoPlugin plugin) { super(plugin); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/TypeAlphabeticSorter.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/TypeAlphabeticSorter.java index 357c4f95..08d9ba21 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/TypeAlphabeticSorter.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/TypeAlphabeticSorter.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.display.options.sorting.implementations; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; import com.willfp.ecoenchants.display.EnchantDisplay; import com.willfp.ecoenchants.display.EnchantmentCache; import com.willfp.ecoenchants.display.options.sorting.EnchantmentSorter; @@ -18,7 +18,7 @@ public class TypeAlphabeticSorter extends PluginDependent implements Enchantment * * @param plugin Instance of EcoEnchants. */ - public TypeAlphabeticSorter(@NotNull final AbstractEcoPlugin plugin) { + public TypeAlphabeticSorter(@NotNull final EcoPlugin plugin) { super(plugin); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/TypeLengthSorter.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/TypeLengthSorter.java index 2b94bca9..126c87e2 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/TypeLengthSorter.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/display/options/sorting/implementations/TypeLengthSorter.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.display.options.sorting.implementations; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; import com.willfp.ecoenchants.display.EnchantDisplay; import com.willfp.ecoenchants.display.EnchantmentCache; import com.willfp.ecoenchants.display.options.sorting.EnchantmentSorter; @@ -18,7 +18,7 @@ public class TypeLengthSorter extends PluginDependent implements EnchantmentSort * * @param plugin Instance of EcoEnchants. */ - public TypeLengthSorter(@NotNull final AbstractEcoPlugin plugin) { + public TypeLengthSorter(@NotNull final EcoPlugin plugin) { super(plugin); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/EcoEnchant.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/EcoEnchant.java index e15ad9e1..4ed159d0 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/EcoEnchant.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/EcoEnchant.java @@ -1,9 +1,7 @@ package com.willfp.ecoenchants.enchantments; - +import com.willfp.eco.core.Prerequisite; import com.willfp.eco.util.StringUtils; -import com.willfp.eco.util.optional.Prerequisite; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; import com.willfp.ecoenchants.EcoEnchantsPlugin; import com.willfp.ecoenchants.config.EcoEnchantsConfigs; import com.willfp.ecoenchants.config.configs.EnchantmentConfig; @@ -45,102 +43,85 @@ public abstract class EcoEnchant extends Enchantment implements Listener, Watche * Instance of EcoEnchants for enchantments to be able to access. */ @Getter(AccessLevel.PROTECTED) - private final AbstractEcoPlugin plugin = EcoEnchantsPlugin.getInstance(); - - /** - * The display name of the enchantment. - */ - private String name; - - /** - * The description of the enchantment. - */ - @Getter - private String description; - + private final EcoEnchantsPlugin plugin = EcoEnchantsPlugin.getInstance(); /** * The permission/config name of the enchantment. */ @Getter private final String permissionName; - /** * The type of the enchantment. */ @Getter private final EnchantmentType type; - /** * The enchantment's config. */ @Getter private final EnchantmentConfig config; - - /** - * If the enchantment can be removed in a grindstone. - */ - @Getter - private boolean grindstoneable; - - /** - * If the enchantment can be obtained from an enchanting table. - */ - @Getter - private boolean availableFromTable; - - /** - * If the enchantment can be obtained from a villager. - */ - @Getter - private boolean availableFromVillager; - - /** - * If the enchantment can be obtained from a loot chest. - */ - @Getter - private boolean availableFromLoot; - - /** - * The maximum level for the enchantment to be obtained naturally. - */ - private int maxLevel; - - /** - * The enchantments that conflict with this enchantment. - */ - @Getter - private Set conflicts; - - /** - * The rarity of the enchantment. - */ - @Getter - private EnchantmentRarity rarity; - /** * The targets of the enchantment. */ @Getter private final Set targets = new HashSet<>(); - /** * The materials of the targets. */ @Getter private final Set targetMaterials = new HashSet<>(); - /** * The names of the worlds that this enchantment is disabled in. */ @Getter private final Set disabledWorldNames = new HashSet<>(); - /** * The worlds that this enchantment is disabled in. */ @Getter private final List disabledWorlds = new ArrayList<>(); - + /** + * The display name of the enchantment. + */ + private String name; + /** + * The description of the enchantment. + */ + @Getter + private String description; + /** + * If the enchantment can be removed in a grindstone. + */ + @Getter + private boolean grindstoneable; + /** + * If the enchantment can be obtained from an enchanting table. + */ + @Getter + private boolean availableFromTable; + /** + * If the enchantment can be obtained from a villager. + */ + @Getter + private boolean availableFromVillager; + /** + * If the enchantment can be obtained from a loot chest. + */ + @Getter + private boolean availableFromLoot; + /** + * The maximum level for the enchantment to be obtained naturally. + */ + private int maxLevel; + /** + * The enchantments that conflict with this enchantment. + */ + @Getter + private Set conflicts; + /** + * The rarity of the enchantment. + */ + @Getter + private EnchantmentRarity rarity; /** * If the enchantment is enabled. */ diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/EcoEnchants.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/EcoEnchants.java index 9f7cd227..6f4b1541 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/EcoEnchants.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/EcoEnchants.java @@ -1,10 +1,9 @@ package com.willfp.ecoenchants.enchantments; - import com.google.common.collect.BiMap; import com.google.common.collect.HashBiMap; import com.google.common.collect.ImmutableList; -import com.willfp.eco.util.config.updating.annotations.ConfigUpdater; +import com.willfp.eco.core.config.ConfigUpdater; import com.willfp.ecoenchants.enchantments.ecoenchants.artifact.AngerArtifact; import com.willfp.ecoenchants.enchantments.ecoenchants.artifact.AshArtifact; import com.willfp.ecoenchants.enchantments.ecoenchants.artifact.BarrierArtifact; @@ -161,6 +160,7 @@ import com.willfp.ecoenchants.enchantments.ecoenchants.normal.Quadrilateralism; import com.willfp.ecoenchants.enchantments.ecoenchants.normal.Radiance; import com.willfp.ecoenchants.enchantments.ecoenchants.normal.Rage; import com.willfp.ecoenchants.enchantments.ecoenchants.normal.Rapid; +import com.willfp.ecoenchants.enchantments.ecoenchants.normal.Reaper; import com.willfp.ecoenchants.enchantments.ecoenchants.normal.Reel; import com.willfp.ecoenchants.enchantments.ecoenchants.normal.Reinforcement; import com.willfp.ecoenchants.enchantments.ecoenchants.normal.Rejuvenation; @@ -224,7 +224,6 @@ import com.willfp.ecoenchants.enchantments.ecoenchants.special.Pentashot; import com.willfp.ecoenchants.enchantments.ecoenchants.special.Preservation; import com.willfp.ecoenchants.enchantments.ecoenchants.special.Prosperity; import com.willfp.ecoenchants.enchantments.ecoenchants.special.Razor; -import com.willfp.ecoenchants.enchantments.ecoenchants.normal.Reaper; import com.willfp.ecoenchants.enchantments.ecoenchants.special.Repairing; import com.willfp.ecoenchants.enchantments.ecoenchants.special.Soulbound; import com.willfp.ecoenchants.enchantments.ecoenchants.special.Spring; @@ -255,10 +254,6 @@ public class EcoEnchants { public static final String CONFIG_LOCATION = "config."; public static final String OBTAINING_LOCATION = "obtaining."; public static final String GENERAL_LOCATION = "general-config."; - - private static final BiMap BY_KEY = HashBiMap.create(); - private static final BiMap BY_NAME = HashBiMap.create(); - public static final EcoEnchant TELEKINESIS = new Telekinesis(); public static final EcoEnchant MARKSMAN = new Marksman(); public static final EcoEnchant INFERNAL_TOUCH = new InfernalTouch(); @@ -490,6 +485,8 @@ public class EcoEnchants { public static final EcoEnchant SWEEP_ARTIFACT = new SweepArtifact(); public static final EcoEnchant REAPER = new Reaper(); public static final EcoEnchant WOOD_SWITCHER = new WoodSwitcher(); + private static final BiMap BY_KEY = HashBiMap.create(); + private static final BiMap BY_NAME = HashBiMap.create(); /** * Get all registered {@link EcoEnchant}s. diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/AshArtifact.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/AshArtifact.java index cd4f37cb..40dfa27a 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/AshArtifact.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/AshArtifact.java @@ -1,6 +1,5 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.artifact; -import com.willfp.eco.util.optional.Prerequisite; import com.willfp.ecoenchants.enchantments.itemtypes.Artifact; import org.bukkit.Particle; import org.jetbrains.annotations.NotNull; @@ -8,8 +7,7 @@ import org.jetbrains.annotations.NotNull; public class AshArtifact extends Artifact { public AshArtifact() { super( - "ash_artifact", - Prerequisite.MINIMUM_1_16 + "ash_artifact" ); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/CrimsonArtifact.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/CrimsonArtifact.java index e954a8e2..269a528a 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/CrimsonArtifact.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/CrimsonArtifact.java @@ -1,6 +1,5 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.artifact; -import com.willfp.eco.util.optional.Prerequisite; import com.willfp.ecoenchants.enchantments.itemtypes.Artifact; import org.bukkit.Particle; import org.jetbrains.annotations.NotNull; @@ -8,8 +7,7 @@ import org.jetbrains.annotations.NotNull; public class CrimsonArtifact extends Artifact { public CrimsonArtifact() { super( - "crimson_artifact", - Prerequisite.MINIMUM_1_16 + "crimson_artifact" ); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/SoulArtifact.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/SoulArtifact.java index c0739d5e..df2f4bae 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/SoulArtifact.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/SoulArtifact.java @@ -1,6 +1,5 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.artifact; -import com.willfp.eco.util.optional.Prerequisite; import com.willfp.ecoenchants.enchantments.itemtypes.Artifact; import org.bukkit.Particle; import org.jetbrains.annotations.NotNull; @@ -8,8 +7,7 @@ import org.jetbrains.annotations.NotNull; public class SoulArtifact extends Artifact { public SoulArtifact() { super( - "soul_artifact", - Prerequisite.MINIMUM_1_16 + "soul_artifact" ); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/SoulFireArtifact.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/SoulFireArtifact.java index 25d92765..4604a6ec 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/SoulFireArtifact.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/SoulFireArtifact.java @@ -1,6 +1,5 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.artifact; -import com.willfp.eco.util.optional.Prerequisite; import com.willfp.ecoenchants.enchantments.itemtypes.Artifact; import org.bukkit.Particle; import org.jetbrains.annotations.NotNull; @@ -8,8 +7,7 @@ import org.jetbrains.annotations.NotNull; public class SoulFireArtifact extends Artifact { public SoulFireArtifact() { super( - "soul_fire_artifact", - Prerequisite.MINIMUM_1_16 + "soul_fire_artifact" ); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/WarpedArtifact.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/WarpedArtifact.java index 8f0f369f..2a746ca5 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/WarpedArtifact.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/artifact/WarpedArtifact.java @@ -1,6 +1,5 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.artifact; -import com.willfp.eco.util.optional.Prerequisite; import com.willfp.ecoenchants.enchantments.itemtypes.Artifact; import org.bukkit.Particle; import org.jetbrains.annotations.NotNull; @@ -8,8 +7,7 @@ import org.jetbrains.annotations.NotNull; public class WarpedArtifact extends Artifact { public WarpedArtifact() { super( - "warped_artifact", - Prerequisite.MINIMUM_1_16 + "warped_artifact" ); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/curse/CallingCurse.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/curse/CallingCurse.java index 5716a86c..dc0843e0 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/curse/CallingCurse.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/curse/CallingCurse.java @@ -1,12 +1,12 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.curse; +import com.willfp.eco.core.events.ArmorEquipEvent; import com.willfp.eco.util.VectorUtils; -import com.willfp.eco.util.bukkit.scheduling.TimedRunnable; -import com.willfp.eco.util.events.armorequip.ArmorEquipEvent; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantChecks; +import com.willfp.ecoenchants.enchantments.util.TimedRunnable; import org.bukkit.entity.Entity; import org.bukkit.entity.Monster; import org.bukkit.entity.PigZombie; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/curse/DecayCurse.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/curse/DecayCurse.java index b4ea16bb..c3669ff5 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/curse/DecayCurse.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/curse/DecayCurse.java @@ -1,11 +1,11 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.curse; import com.willfp.eco.util.DurabilityUtils; -import com.willfp.eco.util.bukkit.scheduling.TimedRunnable; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantChecks; +import com.willfp.ecoenchants.enchantments.util.TimedRunnable; import org.bukkit.entity.Player; import org.bukkit.event.EventHandler; import org.bukkit.event.entity.EntityDropItemEvent; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/curse/FragilityCurse.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/curse/FragilityCurse.java index f3a496e5..b3d71b37 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/curse/FragilityCurse.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/curse/FragilityCurse.java @@ -16,6 +16,7 @@ public class FragilityCurse extends EcoEnchant { "fragility_curse", EnchantmentType.CURSE ); } + @EventHandler public void onItemDamage(@NotNull final PlayerItemDamageEvent event) { ItemStack item = event.getItem(); diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/curse/HungerCurse.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/curse/HungerCurse.java index 1caaef0f..afeba0de 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/curse/HungerCurse.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/curse/HungerCurse.java @@ -15,6 +15,7 @@ public class HungerCurse extends EcoEnchant { "hunger_curse", EnchantmentType.CURSE ); } + @EventHandler public void onHunger(@NotNull final FoodLevelChangeEvent event) { if (!(event.getEntity() instanceof Player)) { diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Abrasion.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Abrasion.java index c1040f51..a579c0e5 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Abrasion.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Abrasion.java @@ -12,6 +12,7 @@ import org.jetbrains.annotations.NotNull; import java.util.ArrayList; import java.util.Arrays; + public class Abrasion extends EcoEnchant { public Abrasion() { super( diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Arborist.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Arborist.java index 50cfa72a..3cb557f8 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Arborist.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Arborist.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.drops.DropQueue; +import com.willfp.eco.core.drops.DropQueue; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Arcanic.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Arcanic.java index 3c90e0bb..3d60c3f1 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Arcanic.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Arcanic.java @@ -13,6 +13,7 @@ public class Arcanic extends EcoEnchant { "arcanic", EnchantmentType.NORMAL ); } + @Override public void onDamageWearingArmor(@NotNull final LivingEntity victim, final int level, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Beheading.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Beheading.java index 58eec0c0..73cf67e4 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Beheading.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Beheading.java @@ -1,6 +1,5 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.drops.DropQueue; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantChecks; @@ -20,7 +19,9 @@ public class Beheading extends EcoEnchant { super( "beheading", EnchantmentType.NORMAL ); - } @EventHandler + } + + @EventHandler public void onDeath(@NotNull final EntityDeathEvent event) { if (event.getEntity().getKiller() == null) { return; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/BlastMining.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/BlastMining.java index 4b5adc94..7390693f 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/BlastMining.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/BlastMining.java @@ -1,8 +1,8 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; +import com.willfp.eco.core.integrations.anticheat.AnticheatManager; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.eco.util.BlockUtils; -import com.willfp.eco.util.integrations.anticheat.AnticheatManager; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Bleed.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Bleed.java index 50967077..5360adcf 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Bleed.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Bleed.java @@ -1,12 +1,10 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.PlayerUtils; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantmentUtils; import org.bukkit.entity.LivingEntity; -import org.bukkit.entity.Player; import org.bukkit.event.entity.EntityDamageByEntityEvent; import org.jetbrains.annotations.NotNull; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Buckshot.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Buckshot.java index 4bcce0bb..50bd8a96 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Buckshot.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Buckshot.java @@ -22,6 +22,7 @@ public class Buckshot extends EcoEnchant { "buckshot", EnchantmentType.NORMAL ); } + @Override public void onBowShoot(@NotNull final LivingEntity shooter, @NotNull final Arrow arrow, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Cleave.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Cleave.java index 2ba08bf8..b9f5471f 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Cleave.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Cleave.java @@ -14,6 +14,7 @@ public class Cleave extends EcoEnchant { "cleave", EnchantmentType.NORMAL ); } + @Override public void onMeleeAttack(@NotNull final LivingEntity attacker, @NotNull final LivingEntity victim, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Corrosive.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Corrosive.java index e4491465..98ec9a7c 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Corrosive.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Corrosive.java @@ -19,6 +19,7 @@ public class Corrosive extends EcoEnchant { "corrosive", EnchantmentType.NORMAL ); } + @Override public void onArrowDamage(@NotNull final LivingEntity attacker, @NotNull final LivingEntity uncastVictim, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Cubism.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Cubism.java index 3b66098a..7b1c8bdf 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Cubism.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Cubism.java @@ -14,6 +14,7 @@ public class Cubism extends EcoEnchant { "cubism", EnchantmentType.NORMAL ); } + @Override public void onMeleeAttack(@NotNull final LivingEntity attacker, @NotNull final LivingEntity victim, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Disable.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Disable.java index 2fa37fc3..7bd38647 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Disable.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Disable.java @@ -1,12 +1,9 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.PlayerUtils; import com.willfp.ecoenchants.enchantments.EcoEnchant; -import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantmentUtils; import org.bukkit.entity.LivingEntity; -import org.bukkit.entity.Player; import org.bukkit.event.entity.EntityDamageByEntityEvent; import org.bukkit.potion.PotionEffect; import org.bukkit.potion.PotionEffectType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Disappear.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Disappear.java index 71da0f92..b7538ee6 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Disappear.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Disappear.java @@ -15,6 +15,7 @@ public class Disappear extends EcoEnchant { "disappear", EnchantmentType.NORMAL ); } + @Override public void onDamageWearingArmor(@NotNull final LivingEntity victim, final int level, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Diurnal.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Diurnal.java index a1836cca..14cf3c6a 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Diurnal.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Diurnal.java @@ -14,6 +14,7 @@ public class Diurnal extends EcoEnchant { "diurnal", EnchantmentType.NORMAL ); } + @Override public void onMeleeAttack(@NotNull final LivingEntity attacker, @NotNull final LivingEntity victim, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Drill.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Drill.java index 203470e8..66d4cff4 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Drill.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Drill.java @@ -1,9 +1,9 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; +import com.willfp.eco.core.integrations.anticheat.AnticheatManager; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.eco.util.BlockUtils; import com.willfp.eco.util.VectorUtils; -import com.willfp.eco.util.integrations.anticheat.AnticheatManager; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; @@ -19,6 +19,7 @@ public class Drill extends EcoEnchant { "drill", EnchantmentType.NORMAL ); } + @Override public void onBlockBreak(@NotNull final Player player, @NotNull final Block block, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Dullness.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Dullness.java index 1157353d..664ebdca 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Dullness.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Dullness.java @@ -16,6 +16,7 @@ public class Dullness extends EcoEnchant { "dullness", EnchantmentType.NORMAL ); } + @Override public void onMeleeAttack(@NotNull final LivingEntity attacker, @NotNull final LivingEntity victim, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Dweller.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Dweller.java index 3bb1dfb0..94e01f1f 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Dweller.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Dweller.java @@ -14,6 +14,7 @@ public class Dweller extends EcoEnchant { "dweller", EnchantmentType.NORMAL ); } + @Override public void onMeleeAttack(@NotNull final LivingEntity attacker, @NotNull final LivingEntity victim, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Economical.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Economical.java index be2f3716..b6ca77a6 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Economical.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Economical.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; import com.destroystokyo.paper.event.player.PlayerElytraBoostEvent; -import com.willfp.eco.util.optional.Prerequisite; +import com.willfp.eco.core.Prerequisite; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantChecks; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Electroshock.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Electroshock.java index e378493a..77521e8e 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Electroshock.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Electroshock.java @@ -16,6 +16,7 @@ public class Electroshock extends EcoEnchant { "electroshock", EnchantmentType.NORMAL ); } + @Override public void onDeflect(@NotNull final Player blocker, @NotNull final LivingEntity attacker, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/EnderSlayer.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/EnderSlayer.java index 2685b601..b414eff4 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/EnderSlayer.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/EnderSlayer.java @@ -10,12 +10,8 @@ import org.bukkit.event.entity.EntityDamageByEntityEvent; import org.jetbrains.annotations.NotNull; import java.util.Set; + public class EnderSlayer extends EcoEnchant { - public EnderSlayer() { - super( - "ender_slayer", EnchantmentType.NORMAL - ); - } private static final Set END_MOBS = new ImmutableSet.Builder() .add(EntityType.ENDERMITE) .add(EntityType.ENDERMAN) @@ -23,6 +19,11 @@ public class EnderSlayer extends EcoEnchant { .add(EntityType.SHULKER) .build(); + public EnderSlayer() { + super( + "ender_slayer", EnchantmentType.NORMAL + ); + } @Override public void onMeleeAttack(@NotNull final LivingEntity attacker, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Extinguishing.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Extinguishing.java index ed5252b6..5546f11a 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Extinguishing.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Extinguishing.java @@ -13,6 +13,7 @@ public class Extinguishing extends EcoEnchant { "extinguishing", EnchantmentType.NORMAL ); } + @Override public void onDamageWearingArmor(@NotNull final LivingEntity victim, final int level, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Farmhand.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Farmhand.java index e973cbee..a73755d6 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Farmhand.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Farmhand.java @@ -1,8 +1,8 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.eco.util.DurabilityUtils; import com.willfp.eco.util.VectorUtils; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; @@ -24,6 +24,7 @@ public class Farmhand extends EcoEnchant { "farmhand", EnchantmentType.NORMAL ); } + @EventHandler public void onTill(@NotNull final PlayerInteractEvent event) { Player player = event.getPlayer(); diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Fetching.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Fetching.java index fa2d134a..911988e5 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Fetching.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Fetching.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.drops.DropQueue; -import com.willfp.eco.util.events.entitydeathbyentity.EntityDeathByEntityEvent; +import com.willfp.eco.core.drops.DropQueue; +import com.willfp.eco.core.events.EntityDeathByEntityEvent; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; @@ -22,6 +22,7 @@ public class Fetching extends EcoEnchant { "fetching", EnchantmentType.NORMAL ); } + @EventHandler(priority = EventPriority.HIGH) public void onWolfKill(@NotNull final EntityDeathByEntityEvent event) { LivingEntity entity = event.getVictim(); diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/FirstStrike.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/FirstStrike.java index 660456a9..8f2d1671 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/FirstStrike.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/FirstStrike.java @@ -14,6 +14,7 @@ public class FirstStrike extends EcoEnchant { "first_strike", EnchantmentType.NORMAL ); } + @Override public void onMeleeAttack(@NotNull final LivingEntity attacker, @NotNull final LivingEntity victim, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Forcefield.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Forcefield.java index 62a2535e..c016b8e1 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Forcefield.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Forcefield.java @@ -1,12 +1,12 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; +import com.willfp.eco.core.events.ArmorEquipEvent; import com.willfp.eco.util.NumberUtils; -import com.willfp.eco.util.events.armorequip.ArmorEquipEvent; -import com.willfp.eco.util.bukkit.scheduling.TimedRunnable; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantChecks; +import com.willfp.ecoenchants.enchantments.util.TimedRunnable; import org.bukkit.entity.Entity; import org.bukkit.entity.Monster; import org.bukkit.entity.Player; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Frozen.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Frozen.java index 19c9e8ce..990a17d6 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Frozen.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Frozen.java @@ -19,6 +19,7 @@ public class Frozen extends EcoEnchant { "frozen", EnchantmentType.NORMAL ); } + @EventHandler public void onHurt(@NotNull final EntityDamageByEntityEvent event) { if (!(event.getEntity() instanceof Player)) { diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Fury.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Fury.java index 838c7b8e..08123a21 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Fury.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Fury.java @@ -1,6 +1,5 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.PlayerUtils; import com.willfp.eco.util.VectorUtils; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; @@ -10,7 +9,6 @@ import org.bukkit.entity.Entity; import org.bukkit.entity.LivingEntity; import org.bukkit.entity.Monster; import org.bukkit.entity.PigZombie; -import org.bukkit.entity.Player; import org.bukkit.event.entity.EntityDamageByEntityEvent; import org.bukkit.util.Vector; import org.jetbrains.annotations.NotNull; @@ -21,6 +19,7 @@ public class Fury extends EcoEnchant { "fury", EnchantmentType.NORMAL ); } + @Override public void onMeleeAttack(@NotNull final LivingEntity attacker, @NotNull final LivingEntity victim, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Graceful.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Graceful.java index 0bde912b..c724bee7 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Graceful.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Graceful.java @@ -19,6 +19,7 @@ public class Graceful extends EcoEnchant { "graceful", EnchantmentType.NORMAL ); } + @EventHandler public void onFall(@NotNull final PlayerMoveEvent event) { Player player = event.getPlayer(); diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/GreenThumb.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/GreenThumb.java index 43bb6780..e1f1008a 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/GreenThumb.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/GreenThumb.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.eco.util.DurabilityUtils; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; @@ -19,6 +19,7 @@ public class GreenThumb extends EcoEnchant { "green_thumb", EnchantmentType.NORMAL ); } + @EventHandler public void onInteract(@NotNull final PlayerInteractEvent event) { Player player = event.getPlayer(); diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Grit.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Grit.java index bf35118a..247205a9 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Grit.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Grit.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.eco.util.DurabilityUtils; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Ignite.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Ignite.java index ddc67d7d..3ea0194e 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Ignite.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Ignite.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantmentUtils; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/IllusionAspect.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/IllusionAspect.java index 946fcdca..ead91aa4 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/IllusionAspect.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/IllusionAspect.java @@ -1,12 +1,9 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.PlayerUtils; import com.willfp.ecoenchants.enchantments.EcoEnchant; -import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantmentUtils; import org.bukkit.entity.LivingEntity; -import org.bukkit.entity.Player; import org.bukkit.event.entity.EntityDamageByEntityEvent; import org.bukkit.potion.PotionEffect; import org.bukkit.potion.PotionEffectType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Incandescence.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Incandescence.java index 2cfaf54e..3a1c64f1 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Incandescence.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Incandescence.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; @@ -18,6 +18,7 @@ public class Incandescence extends EcoEnchant { "incandescence", EnchantmentType.NORMAL ); } + @EventHandler public void onIncandescenceHurt(@NotNull final EntityDamageByEntityEvent event) { if (event.getCause() == EntityDamageEvent.DamageCause.THORNS) { @@ -50,8 +51,8 @@ public class Incandescence extends EcoEnchant { } this.getPlugin().getScheduler().runLater(() -> victim.setFireTicks(totalIncandescencePoints - * this.getConfig().getInt(EcoEnchants.CONFIG_LOCATION + "ticks-per-point") - + this.getConfig().getInt(EcoEnchants.CONFIG_LOCATION + "initial-ticks")), + * this.getConfig().getInt(EcoEnchants.CONFIG_LOCATION + "ticks-per-point") + + this.getConfig().getInt(EcoEnchants.CONFIG_LOCATION + "initial-ticks")), 1); } } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/InfernalTouch.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/InfernalTouch.java index fc86b07f..1a3e135e 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/InfernalTouch.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/InfernalTouch.java @@ -1,8 +1,8 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.drops.DropQueue; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; -import com.willfp.eco.util.tuples.Pair; +import com.willfp.eco.core.drops.DropQueue; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; +import com.willfp.eco.core.tuples.Pair; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; @@ -39,12 +39,6 @@ public class InfernalTouch extends EcoEnchant { ) ); - public InfernalTouch() { - super( - "infernal_touch", EnchantmentType.NORMAL - ); - } - static { Iterator iterator = Bukkit.recipeIterator(); while (iterator.hasNext()) { @@ -58,6 +52,12 @@ public class InfernalTouch extends EcoEnchant { } } + public InfernalTouch() { + super( + "infernal_touch", EnchantmentType.NORMAL + ); + } + @NotNull private static Pair getOutput(@NotNull final Material input) { Pair toReturn = RECIPES.get(input); diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Instantaneous.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Instantaneous.java index 90428a43..c509bc4c 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Instantaneous.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Instantaneous.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.integrations.anticheat.AnticheatManager; +import com.willfp.eco.core.integrations.anticheat.AnticheatManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantmentUtils; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Invigoration.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Invigoration.java index 54c1cbc4..6c7c72f0 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Invigoration.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Invigoration.java @@ -16,6 +16,7 @@ public class Invigoration extends EcoEnchant { "invigoration", EnchantmentType.NORMAL ); } + @EventHandler public void onInvigorationHurt(@NotNull final EntityDamageEvent event) { if (!(event.getEntity() instanceof Player)) { diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Lumberjack.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Lumberjack.java index e86b4c36..e5991c36 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Lumberjack.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Lumberjack.java @@ -1,8 +1,8 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; +import com.willfp.eco.core.integrations.anticheat.AnticheatManager; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.eco.util.BlockUtils; -import com.willfp.eco.util.integrations.anticheat.AnticheatManager; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/MagmaWalker.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/MagmaWalker.java index 0d715c4b..de7965c8 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/MagmaWalker.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/MagmaWalker.java @@ -1,8 +1,8 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; +import com.willfp.eco.core.integrations.anticheat.AnticheatManager; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.eco.util.VectorUtils; -import com.willfp.eco.util.integrations.anticheat.AnticheatManager; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; @@ -24,6 +24,7 @@ public class MagmaWalker extends EcoEnchant { "magma_walker", EnchantmentType.NORMAL ); } + @EventHandler public void onLavaWalk(@NotNull final PlayerMoveEvent event) { Player player = event.getPlayer(); diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Magnetic.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Magnetic.java index b3595d1e..33f16750 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Magnetic.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Magnetic.java @@ -1,12 +1,12 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; +import com.willfp.eco.core.events.ArmorEquipEvent; import com.willfp.eco.util.VectorUtils; -import com.willfp.eco.util.bukkit.scheduling.TimedRunnable; -import com.willfp.eco.util.events.armorequip.ArmorEquipEvent; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantChecks; +import com.willfp.ecoenchants.enchantments.util.TimedRunnable; import org.bukkit.entity.Entity; import org.bukkit.entity.ExperienceOrb; import org.bukkit.entity.Item; @@ -20,9 +20,9 @@ import org.jetbrains.annotations.NotNull; import java.util.HashMap; public class Magnetic extends EcoEnchant implements TimedRunnable { + private final HashMap players = new HashMap<>(); private double initialDistance = 1; private double bonus = 1; - private final HashMap players = new HashMap<>(); public Magnetic() { super( diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Marksman.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Marksman.java index 131827a0..619506a9 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Marksman.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Marksman.java @@ -4,8 +4,6 @@ import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantChecks; -import org.bukkit.entity.Arrow; -import org.bukkit.entity.EntityType; import org.bukkit.entity.Player; import org.bukkit.entity.Projectile; import org.bukkit.event.EventHandler; @@ -18,6 +16,7 @@ public class Marksman extends EcoEnchant { "marksman", EnchantmentType.NORMAL ); } + @EventHandler public void onMarksmanShoot(@NotNull final ProjectileLaunchEvent event) { diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Necrotic.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Necrotic.java index 7f797a0c..57d26ce0 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Necrotic.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Necrotic.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.drops.DropQueue; +import com.willfp.eco.core.drops.DropQueue; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantChecks; @@ -19,6 +19,7 @@ public class Necrotic extends EcoEnchant { "necrotic", EnchantmentType.NORMAL ); } + @EventHandler public void necroticKill(@NotNull final EntityDeathEvent event) { if (event.getEntity().getKiller() == null) { diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Parry.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Parry.java index 95e5352a..cece6cd3 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Parry.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Parry.java @@ -15,6 +15,7 @@ public class Parry extends EcoEnchant { "parry", EnchantmentType.NORMAL ); } + @EventHandler public void parryHit(@NotNull final EntityDamageByEntityEvent event) { if (!(event.getEntity() instanceof Player)) { diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Plasmic.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Plasmic.java index eca28906..707cfc8a 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Plasmic.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Plasmic.java @@ -1,6 +1,5 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.optional.Prerequisite; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; @@ -14,35 +13,27 @@ import org.jetbrains.annotations.NotNull; import java.util.Arrays; public class Plasmic extends EcoEnchant { + private static final Material[] ITEMS; + + static { + ITEMS = new Material[]{ + Material.DIAMOND_HELMET, + Material.DIAMOND_CHESTPLATE, + Material.DIAMOND_LEGGINGS, + Material.DIAMOND_BOOTS, + + Material.NETHERITE_HELMET, + Material.NETHERITE_CHESTPLATE, + Material.NETHERITE_LEGGINGS, + Material.NETHERITE_BOOTS + }; + } + public Plasmic() { super( "plasmic", EnchantmentType.NORMAL ); } - private static final Material[] ITEMS; - - static { - if (Prerequisite.MINIMUM_1_16.isMet()) { - ITEMS = new Material[]{ - Material.DIAMOND_HELMET, - Material.DIAMOND_CHESTPLATE, - Material.DIAMOND_LEGGINGS, - Material.DIAMOND_BOOTS, - - Material.NETHERITE_HELMET, - Material.NETHERITE_CHESTPLATE, - Material.NETHERITE_LEGGINGS, - Material.NETHERITE_BOOTS - }; - } else { - ITEMS = new Material[]{ - Material.DIAMOND_HELMET, - Material.DIAMOND_CHESTPLATE, - Material.DIAMOND_LEGGINGS, - Material.DIAMOND_BOOTS - }; - } - } @Override public void onMeleeAttack(@NotNull final LivingEntity attacker, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Protector.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Protector.java index ec804d8b..df067057 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Protector.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Protector.java @@ -13,6 +13,7 @@ public class Protector extends EcoEnchant { "protector", EnchantmentType.NORMAL ); } + @Override public void onMeleeAttack(@NotNull final LivingEntity attacker, @NotNull final LivingEntity uncastVictim, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Reel.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Reel.java index ba5d0602..dff5d409 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Reel.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Reel.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.eco.util.VectorUtils; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; @@ -19,6 +19,7 @@ public class Reel extends EcoEnchant { "reel", EnchantmentType.NORMAL ); } + @EventHandler public void onFish(@NotNull final PlayerFishEvent event) { if (!event.getState().equals(PlayerFishEvent.State.CAUGHT_ENTITY)) { diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Rejuvenation.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Rejuvenation.java index ba406da7..8b679236 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Rejuvenation.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Rejuvenation.java @@ -15,6 +15,7 @@ public class Rejuvenation extends EcoEnchant { "rejuvenation", EnchantmentType.NORMAL ); } + @EventHandler public void onRejuvenationHeal(@NotNull final EntityRegainHealthEvent event) { if (!(event.getEntity() instanceof Player)) { diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Sating.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Sating.java index 49507936..61b0cb7f 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Sating.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Sating.java @@ -15,6 +15,7 @@ public class Sating extends EcoEnchant { "sating", EnchantmentType.NORMAL ); } + @EventHandler public void onSatingHunger(@NotNull final FoodLevelChangeEvent event) { if (!(event.getEntity() instanceof Player)) { diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Shockwave.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Shockwave.java index ef656254..425f0b71 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Shockwave.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Shockwave.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.eco.util.TridentUtils; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; @@ -21,6 +21,7 @@ public class Shockwave extends EcoEnchant { "shockwave", EnchantmentType.NORMAL ); } + @EventHandler public void onShoot(@NotNull final ProjectileLaunchEvent event) { if (!(event.getEntity() instanceof AbstractArrow)) { diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Slicing.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Slicing.java index b824bbfc..eac25ea6 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Slicing.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Slicing.java @@ -14,13 +14,15 @@ import org.bukkit.event.player.PlayerMoveEvent; import org.jetbrains.annotations.NotNull; import java.util.ArrayList; + public class Slicing extends EcoEnchant { + private final ArrayList entities = new ArrayList<>(); + public Slicing() { super( "slicing", EnchantmentType.NORMAL ); } - private final ArrayList entities = new ArrayList<>(); @EventHandler public void onPlayerCollide(@NotNull final PlayerMoveEvent event) { diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Spearfishing.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Spearfishing.java index 43b0046d..3c5d6b71 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Spearfishing.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Spearfishing.java @@ -1,8 +1,8 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; +import com.willfp.eco.core.drops.DropQueue; import com.willfp.eco.util.NumberUtils; import com.willfp.eco.util.TridentUtils; -import com.willfp.eco.util.drops.DropQueue; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Spiked.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Spiked.java index 3b6cee74..ea56b70f 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Spiked.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Spiked.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; @@ -17,6 +17,7 @@ public class Spiked extends EcoEnchant { "spiked", EnchantmentType.NORMAL ); } + @EventHandler public void onFish(@NotNull final PlayerFishEvent event) { if (!event.getState().equals(PlayerFishEvent.State.CAUGHT_ENTITY)) { diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Splash.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Splash.java index 5d2794fc..b49e63b4 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Splash.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Splash.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.eco.util.TridentUtils; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Stamina.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Stamina.java index 38bf285b..082669b5 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Stamina.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Stamina.java @@ -15,6 +15,7 @@ public class Stamina extends EcoEnchant { "stamina", EnchantmentType.NORMAL ); } + @EventHandler public void onStaminaHunger(@NotNull final FoodLevelChangeEvent event) { if (!(event.getEntity() instanceof Player)) { diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/StoneSwitcher.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/StoneSwitcher.java index d64c2ed0..4e94d0e6 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/StoneSwitcher.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/StoneSwitcher.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; +import com.willfp.eco.core.drops.DropQueue; import com.willfp.eco.util.NumberUtils; -import com.willfp.eco.util.drops.DropQueue; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/StrayAspect.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/StrayAspect.java index 66e6bebb..a064e3fc 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/StrayAspect.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/StrayAspect.java @@ -1,12 +1,10 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.PlayerUtils; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantmentUtils; import org.bukkit.entity.LivingEntity; -import org.bukkit.entity.Player; import org.bukkit.event.entity.EntityDamageByEntityEvent; import org.bukkit.potion.PotionEffect; import org.bukkit.potion.PotionEffectType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Supercritical.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Supercritical.java index 8ff84b39..e6911baf 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Supercritical.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Supercritical.java @@ -1,12 +1,10 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.PlayerUtils; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantmentUtils; import org.bukkit.entity.LivingEntity; -import org.bukkit.entity.Player; import org.bukkit.event.entity.EntityDamageByEntityEvent; import org.jetbrains.annotations.NotNull; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Tectonic.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Tectonic.java index be4d121b..25968078 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Tectonic.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Tectonic.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; @@ -11,6 +11,7 @@ import org.bukkit.event.entity.EntityDamageEvent; import org.jetbrains.annotations.NotNull; import java.util.Collection; + public class Tectonic extends EcoEnchant { public Tectonic() { super( diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Telekinesis.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Telekinesis.java index a44bfd90..7aa3f641 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Telekinesis.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Telekinesis.java @@ -1,10 +1,10 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; +import com.willfp.eco.core.drops.DropQueue; +import com.willfp.eco.core.events.EntityDeathByEntityEvent; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; +import com.willfp.eco.core.integrations.mcmmo.McmmoManager; import com.willfp.eco.util.TridentUtils; -import com.willfp.eco.util.drops.DropQueue; -import com.willfp.eco.util.events.entitydeathbyentity.EntityDeathByEntityEvent; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; -import com.willfp.eco.util.integrations.mcmmo.McmmoManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Thor.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Thor.java index c459f33a..beb37eaa 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Thor.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Thor.java @@ -1,13 +1,11 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; import com.willfp.eco.util.LightningUtils; -import com.willfp.eco.util.PlayerUtils; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantmentUtils; import org.bukkit.entity.LivingEntity; -import org.bukkit.entity.Player; import org.bukkit.event.entity.EntityDamageByEntityEvent; import org.jetbrains.annotations.NotNull; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Thrive.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Thrive.java index 4257189d..b264003d 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Thrive.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Thrive.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.events.armorequip.ArmorEquipEvent; +import com.willfp.eco.core.events.ArmorEquipEvent; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Toxic.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Toxic.java index 9fe7ae44..cb57fcc3 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Toxic.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Toxic.java @@ -1,12 +1,9 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.PlayerUtils; import com.willfp.ecoenchants.enchantments.EcoEnchant; -import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantmentUtils; import org.bukkit.entity.LivingEntity; -import org.bukkit.entity.Player; import org.bukkit.event.entity.EntityDamageByEntityEvent; import org.bukkit.potion.PotionEffect; import org.bukkit.potion.PotionEffectType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Transfuse.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Transfuse.java index 72f82dda..d95e8e59 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Transfuse.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Transfuse.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; +import com.willfp.eco.core.drops.DropQueue; import com.willfp.eco.util.NumberUtils; -import com.willfp.eco.util.drops.DropQueue; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Vein.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Vein.java index 2ccd5026..5c0f2295 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Vein.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Vein.java @@ -1,8 +1,8 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; +import com.willfp.eco.core.integrations.anticheat.AnticheatManager; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.eco.util.BlockUtils; -import com.willfp.eco.util.integrations.anticheat.AnticheatManager; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Voltage.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Voltage.java index 801836cb..5d3d9465 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Voltage.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Voltage.java @@ -13,11 +13,6 @@ import org.jetbrains.annotations.NotNull; import java.util.Arrays; public class Voltage extends EcoEnchant { - public Voltage() { - super( - "voltage", EnchantmentType.NORMAL - ); - } private static final Material[] ITEMS = { Material.IRON_HELMET, Material.IRON_CHESTPLATE, @@ -35,6 +30,12 @@ public class Voltage extends EcoEnchant { Material.CHAINMAIL_BOOTS, }; + public Voltage() { + super( + "voltage", EnchantmentType.NORMAL + ); + } + @Override public void onMeleeAttack(@NotNull final LivingEntity attacker, @NotNull final LivingEntity victim, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Wisdom.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Wisdom.java index 717dcf04..b41a0ed0 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Wisdom.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/Wisdom.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; -import com.willfp.eco.util.events.naturalexpgainevent.NaturalExpGainEvent; +import com.willfp.eco.core.events.NaturalExpGainEvent; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; @@ -15,6 +15,7 @@ public class Wisdom extends EcoEnchant { "wisdom", EnchantmentType.NORMAL ); } + @EventHandler public void onExpChange(@NotNull final NaturalExpGainEvent event) { Player player = event.getExpChangeEvent().getPlayer(); diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/WoodSwitcher.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/WoodSwitcher.java index e2f9716b..34c3f6f1 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/WoodSwitcher.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/normal/WoodSwitcher.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.normal; +import com.willfp.eco.core.drops.DropQueue; import com.willfp.eco.util.NumberUtils; -import com.willfp.eco.util.drops.DropQueue; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Aiming.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Aiming.java index 508bd44c..8be82e82 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Aiming.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Aiming.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.special; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.eco.util.NumberUtils; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Bolt.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Bolt.java index 6ee226b9..7ca827f2 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Bolt.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Bolt.java @@ -1,13 +1,11 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.special; import com.willfp.eco.util.LightningUtils; -import com.willfp.eco.util.PlayerUtils; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantmentUtils; import org.bukkit.entity.LivingEntity; -import org.bukkit.entity.Player; import org.bukkit.event.entity.EntityDamageByEntityEvent; import org.jetbrains.annotations.NotNull; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Confusion.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Confusion.java index 08e1d289..3db9d3f9 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Confusion.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Confusion.java @@ -1,8 +1,6 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.special; -import com.willfp.eco.util.PlayerUtils; import com.willfp.ecoenchants.enchantments.EcoEnchant; -import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantmentUtils; import org.bukkit.entity.LivingEntity; @@ -14,6 +12,7 @@ import org.jetbrains.annotations.NotNull; import java.util.ArrayList; import java.util.Collections; import java.util.List; + public class Confusion extends EcoEnchant { public Confusion() { super( diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Energizing.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Energizing.java index 5f09c0cd..37d1aacc 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Energizing.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Energizing.java @@ -16,6 +16,7 @@ public class Energizing extends EcoEnchant { "energizing", EnchantmentType.SPECIAL ); } + @Override public void onBlockBreak(@NotNull final Player player, @NotNull final Block block, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Frenzy.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Frenzy.java index e8d4ade6..a00af005 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Frenzy.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Frenzy.java @@ -16,7 +16,9 @@ public class Frenzy extends EcoEnchant { super( "frenzy", EnchantmentType.SPECIAL ); - } @EventHandler + } + + @EventHandler public void onFrenzyKill(@NotNull final EntityDeathEvent event) { if (event.getEntity().getKiller() == null) { return; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Harpoon.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Harpoon.java index 72fc21ae..c463bef6 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Harpoon.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Harpoon.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.special; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; @@ -17,6 +17,7 @@ public class Harpoon extends EcoEnchant { "harpoon", EnchantmentType.SPECIAL ); } + @EventHandler public void onFish(@NotNull final PlayerFishEvent event) { if (!event.getState().equals(PlayerFishEvent.State.CAUGHT_ENTITY)) { diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Indestructibility.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Indestructibility.java index 92dc3c27..30615882 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Indestructibility.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Indestructibility.java @@ -16,6 +16,7 @@ public class Indestructibility extends EcoEnchant { "indestructibility", EnchantmentType.SPECIAL ); } + @EventHandler public void onItemDamage(@NotNull final PlayerItemDamageEvent event) { ItemStack item = event.getItem(); diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Instability.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Instability.java index e55e1f70..d5dd3465 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Instability.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Instability.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.special; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; @@ -18,6 +18,7 @@ public class Instability extends EcoEnchant { "instability", EnchantmentType.SPECIAL ); } + @EventHandler public void onInstabilityLand(@NotNull final ProjectileHitEvent event) { if (event.getEntityType() != EntityType.ARROW) { diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Intellect.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Intellect.java index b3f9571e..4e1d8855 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Intellect.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Intellect.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.special; -import com.willfp.eco.util.events.naturalexpgainevent.NaturalExpGainEvent; +import com.willfp.eco.core.events.NaturalExpGainEvent; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; @@ -15,6 +15,7 @@ public class Intellect extends EcoEnchant { "intellect", EnchantmentType.SPECIAL ); } + @EventHandler public void onExpChange(@NotNull final NaturalExpGainEvent event) { Player player = event.getExpChangeEvent().getPlayer(); diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Prosperity.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Prosperity.java index f3a7385e..9a6fc25d 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Prosperity.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Prosperity.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.special; -import com.willfp.eco.util.events.armorequip.ArmorEquipEvent; +import com.willfp.eco.core.events.ArmorEquipEvent; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Razor.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Razor.java index 1d1aeaff..bef73e33 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Razor.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Razor.java @@ -1,6 +1,5 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.special; -import com.willfp.eco.util.PlayerUtils; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; @@ -25,7 +24,7 @@ public class Razor extends EcoEnchant { double baseDamage = this.getConfig().getDouble(EcoEnchants.CONFIG_LOCATION + "base-damage"); double extra = (level * perLevelMultiplier) + baseDamage; if (this.getConfig().getBool((EcoEnchants.CONFIG_LOCATION) + "decrease-if-cooldown") && attacker instanceof Player) { - extra *= PlayerUtils.getAttackCooldown((Player) attacker); + extra *= ((Player) attacker).getAttackCooldown(); } event.setDamage(event.getDamage() + extra); diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Repairing.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Repairing.java index c74944f4..edbbd7b9 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Repairing.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Repairing.java @@ -1,11 +1,11 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.special; import com.willfp.eco.util.DurabilityUtils; -import com.willfp.eco.util.bukkit.scheduling.TimedRunnable; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantChecks; +import com.willfp.ecoenchants.enchantments.util.TimedRunnable; import org.bukkit.entity.Player; import org.bukkit.event.EventHandler; import org.bukkit.event.entity.EntityDropItemEvent; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Streamlining.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Streamlining.java index 552748d2..2e2c92da 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Streamlining.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Streamlining.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.special; -import com.willfp.eco.util.events.armorequip.ArmorEquipEvent; +import com.willfp.eco.core.events.ArmorEquipEvent; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Volatile.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Volatile.java index fe57179e..69afafde 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Volatile.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/special/Volatile.java @@ -1,6 +1,5 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.special; - -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Ascend.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Ascend.java index c327c6de..680d7a7f 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Ascend.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Ascend.java @@ -18,13 +18,15 @@ public class Ascend extends Spell { } @Override - public void onUse(@NotNull final Player player, - final int level, - @NotNull final PlayerInteractEvent event) { + public boolean onUse(@NotNull final Player player, + final int level, + @NotNull final PlayerInteractEvent event) { int ticks = this.getConfig().getInt(EcoEnchants.CONFIG_LOCATION + "ticks-per-level") * level; player.addPotionEffect(new PotionEffect(PotionEffectType.LEVITATION, ticks, this.getConfig().getInt(EcoEnchants.CONFIG_LOCATION + "power") - 1, false, false)); player.setMetadata(IGNORE_FALL_KEY, this.getPlugin().getMetadataValueFactory().create(true)); this.getPlugin().getScheduler().runLater(() -> player.removeMetadata(IGNORE_FALL_KEY, this.getPlugin()), ticks * 4L); + + return true; } @EventHandler diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Charge.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Charge.java index 83f7af4d..334ebeda 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Charge.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Charge.java @@ -13,13 +13,15 @@ public class Charge extends Spell { } @Override - public void onUse(@NotNull final Player player, - final int level, - @NotNull final PlayerInteractEvent event) { + public boolean onUse(@NotNull final Player player, + final int level, + @NotNull final PlayerInteractEvent event) { Vector velocity = player.getEyeLocation().getDirection().clone(); velocity.normalize(); velocity.multiply(level * this.getConfig().getDouble(EcoEnchants.CONFIG_LOCATION + "velocity-per-level")); velocity.setY(player.getEyeLocation().getDirection().clone().getY() + 0.2); player.setVelocity(velocity); + + return true; } } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Dynamite.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Dynamite.java index 0e3d7df9..2732a851 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Dynamite.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Dynamite.java @@ -1,8 +1,8 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.spell; +import com.willfp.eco.core.integrations.anticheat.AnticheatManager; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.eco.util.BlockUtils; -import com.willfp.eco.util.integrations.anticheat.AnticheatManager; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.itemtypes.Spell; import org.bukkit.Particle; @@ -21,21 +21,21 @@ public class Dynamite extends Spell { } @Override - public void onUse(@NotNull final Player player, - final int level, - @NotNull final PlayerInteractEvent event) { + public boolean onUse(@NotNull final Player player, + final int level, + @NotNull final PlayerInteractEvent event) { Block block = event.getClickedBlock(); if (!event.getAction().equals(Action.RIGHT_CLICK_BLOCK)) { - return; + return false; } if (block == null) { - return; + return false; } if (block.hasMetadata("block-ignore")) { - return; + return false; } AnticheatManager.exemptPlayer(player); @@ -79,6 +79,8 @@ public class Dynamite extends Spell { })); AnticheatManager.unexemptPlayer(player); + + return true; } @Override diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Missile.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Missile.java index e46b926b..7a5aa3d9 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Missile.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Missile.java @@ -17,15 +17,17 @@ public class Missile extends Spell { } @Override - public void onUse(@NotNull final Player player, - final int level, - @NotNull final PlayerInteractEvent event) { + public boolean onUse(@NotNull final Player player, + final int level, + @NotNull final PlayerInteractEvent event) { WitherSkull skull = player.launchProjectile(WitherSkull.class, player.getEyeLocation().getDirection().multiply(this.getConfig().getDouble(EcoEnchants.CONFIG_LOCATION + "velocity"))); skull.setCharged(true); skull.setIsIncendiary(false); skull.setMetadata("eco-damage", this.getPlugin().getMetadataValueFactory().create(this.getConfig().getDouble(EcoEnchants.CONFIG_LOCATION + "damage-per-level") * level)); skull.setMetadata("nobreak", this.getPlugin().getMetadataValueFactory().create(true)); skull.setShooter(player); + + return true; } @EventHandler(priority = EventPriority.LOW) diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Quake.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Quake.java index 8db1650f..382f3d2d 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Quake.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Quake.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.enchantments.ecoenchants.spell; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.itemtypes.Spell; import org.bukkit.entity.Entity; @@ -17,9 +17,9 @@ public class Quake extends Spell { } @Override - public void onUse(@NotNull final Player player, - final int level, - @NotNull final PlayerInteractEvent event) { + public boolean onUse(@NotNull final Player player, + final int level, + @NotNull final PlayerInteractEvent event) { int radius = this.getConfig().getInt(EcoEnchants.CONFIG_LOCATION + "radius-per-level") * level; int damage = this.getConfig().getInt(EcoEnchants.CONFIG_LOCATION + "damage-per-level") * level; @@ -39,5 +39,7 @@ public class Quake extends Spell { ((LivingEntity) entity).damage(damage); } + + return true; } } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Vitalize.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Vitalize.java index 59174b7d..ef9754a2 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Vitalize.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/ecoenchants/spell/Vitalize.java @@ -12,9 +12,11 @@ public class Vitalize extends Spell { } @Override - public void onUse(@NotNull final Player player, - final int level, - @NotNull final PlayerInteractEvent event) { + public boolean onUse(@NotNull final Player player, + final int level, + @NotNull final PlayerInteractEvent event) { player.setHealth(player.getAttribute(Attribute.GENERIC_MAX_HEALTH).getValue()); + + return true; } } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/itemtypes/Artifact.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/itemtypes/Artifact.java index 9ea8f149..9da5ea63 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/itemtypes/Artifact.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/itemtypes/Artifact.java @@ -1,13 +1,12 @@ package com.willfp.ecoenchants.enchantments.itemtypes; import com.google.common.util.concurrent.AtomicDouble; +import com.willfp.eco.core.Prerequisite; import com.willfp.eco.util.NumberUtils; -import com.willfp.eco.util.optional.Prerequisite; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantChecks; -import com.willfp.ecoenchants.enchantments.util.FastTrig; import org.bukkit.Location; import org.bukkit.Particle; import org.bukkit.block.Block; @@ -141,8 +140,8 @@ public abstract class Artifact extends EcoEnchant { } yAtomic.addAndGet(yDelta); double y = yAtomic.get(); - double x = radius * FastTrig.cos((y + offset) * radiusMultiplier); - double z = radius * FastTrig.sin((y + offset) * radiusMultiplier); + double x = radius * NumberUtils.fastCos((y + offset) * radiusMultiplier); + double z = radius * NumberUtils.fastSin((y + offset) * radiusMultiplier); Location particleLocation = victim.getLocation(); particleLocation.add(x, y, z); victim.getWorld().spawnParticle(particle, particleLocation, 1, 0, 0, 0, 0, extra, false); diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/itemtypes/Spell.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/itemtypes/Spell.java index 7b52c5c0..39489bd2 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/itemtypes/Spell.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/itemtypes/Spell.java @@ -1,16 +1,15 @@ package com.willfp.ecoenchants.enchantments.itemtypes; +import com.willfp.eco.core.Prerequisite; +import com.willfp.eco.core.integrations.placeholder.PlaceholderEntry; +import com.willfp.eco.core.integrations.placeholder.PlaceholderManager; import com.willfp.eco.util.StringUtils; -import com.willfp.eco.util.integrations.placeholder.PlaceholderEntry; -import com.willfp.eco.util.integrations.placeholder.PlaceholderManager; -import com.willfp.eco.util.optional.Prerequisite; import com.willfp.ecoenchants.display.EnchantmentCache; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; import com.willfp.ecoenchants.enchantments.util.EnchantChecks; import com.willfp.ecoenchants.enchantments.util.SpellActivateEvent; -import com.willfp.ecoenchants.enchantments.util.SpellCancellationInterrupt; import org.bukkit.Bukkit; import org.bukkit.Material; import org.bukkit.Sound; @@ -33,16 +32,6 @@ import java.util.Set; import java.util.UUID; public abstract class Spell extends EcoEnchant { - /** - * The cooldown end times linked to players. - */ - private final Map tracker = new HashMap<>(); - - /** - * Players currently running spells - prevents listener firing twice. - */ - private final Set preventDuplicateList = new HashSet<>(); - /** * Items that must be left-clicked to activate spells for. */ @@ -50,6 +39,14 @@ public abstract class Spell extends EcoEnchant { Material.FISHING_ROD, Material.BOW ); + /** + * The cooldown end times linked to players. + */ + private final Map tracker = new HashMap<>(); + /** + * Players currently running spells - prevents listener firing twice. + */ + private final Set preventDuplicateList = new HashSet<>(); /** * Create a new spell enchantment. @@ -69,6 +66,54 @@ public abstract class Spell extends EcoEnchant { ); } + /** + * Utility method to get a player's cooldown time of a specific spell. + * + * @param spell The spell to query. + * @param player The player to query. + * @return The time left in seconds before next use. + */ + public static int getCooldown(@NotNull final Spell spell, + @NotNull final Player player) { + if (!spell.tracker.containsKey(player.getUniqueId())) { + return 0; + } + + long msLeft = spell.tracker.get(player.getUniqueId()) - System.currentTimeMillis(); + + long secondsLeft = (long) Math.ceil((double) msLeft / 1000); + + return NumberConversions.toInt(secondsLeft); + } + + /** + * Get a multiplier for a spell cooldown. + *

+ * Used for perks - this should be reworked as it has hardcoded permission references. + * + * @param player The player to query. + * @return The multipiler. + */ + public static double getCooldownMultiplier(@NotNull final Player player) { + if (player.hasPermission("ecoenchants.cooldowntime.quarter")) { + return 0.25; + } + + if (player.hasPermission("ecoenchants.cooldowntime.third")) { + return 0.33; + } + + if (player.hasPermission("ecoenchants.cooldowntime.half")) { + return 0.5; + } + + if (player.hasPermission("ecoenchants.cooldowntime.75")) { + return 0.75; + } + + return 1; + } + /** * Get the cooldown time of the spell (in seconds). * @@ -136,15 +181,10 @@ public abstract class Spell extends EcoEnchant { || event.getClickedBlock().getType() == Material.GRINDSTONE || event.getClickedBlock().getType() == Material.ENCHANTING_TABLE || event.getClickedBlock().getType() == Material.ANVIL - || event.getClickedBlock().getType() == Material.FURNACE) { + || event.getClickedBlock().getType() == Material.FURNACE + || event.getClickedBlock().getType() == Material.SMITHING_TABLE) { return; } - - if (Prerequisite.MINIMUM_1_16.isMet()) { - if (event.getClickedBlock().getType() == Material.SMITHING_TABLE) { - return; - } - } } if (cooldown > 0) { @@ -152,22 +192,18 @@ public abstract class Spell extends EcoEnchant { player.sendMessage(message); player.playSound(player.getLocation(), Sound.BLOCK_NOTE_BLOCK_BASS, 1, 0.5f); } else { - tracker.remove(player.getUniqueId()); - tracker.put(player.getUniqueId(), System.currentTimeMillis() + (long) ((this.getCooldownTime() * 1000L) * Spell.getCooldownMultiplier(player))); - SpellActivateEvent spellActivateEvent = new SpellActivateEvent(player, this); Bukkit.getPluginManager().callEvent(spellActivateEvent); if (!spellActivateEvent.isCancelled()) { - try { - onUse(player, level, event); - } catch (SpellCancellationInterrupt ignored) { - return; - } + if (onUse(player, level, event)) { + String message = this.getPlugin().getLangYml().getMessage("used-spell").replace("%name%", EnchantmentCache.getEntry(this).getRawName()); + player.sendMessage(message); + player.playSound(player.getLocation(), this.getActivationSound(), SoundCategory.PLAYERS, 1, 1); - String message = this.getPlugin().getLangYml().getMessage("used-spell").replace("%name%", EnchantmentCache.getEntry(this).getRawName()); - player.sendMessage(message); - player.playSound(player.getLocation(), this.getActivationSound(), SoundCategory.PLAYERS, 1, 1); + tracker.remove(player.getUniqueId()); + tracker.put(player.getUniqueId(), System.currentTimeMillis() + (long) ((this.getCooldownTime() * 1000L) * Spell.getCooldownMultiplier(player))); + } } } } @@ -188,55 +224,7 @@ public abstract class Spell extends EcoEnchant { * @param level The level of the spell on the item. * @param event The event that activated the spell. */ - public abstract void onUse(@NotNull Player player, - int level, - @NotNull PlayerInteractEvent event) throws SpellCancellationInterrupt; - - /** - * Utility method to get a player's cooldown time of a specific spell. - * - * @param spell The spell to query. - * @param player The player to query. - * @return The time left in seconds before next use. - */ - public static int getCooldown(@NotNull final Spell spell, - @NotNull final Player player) { - if (!spell.tracker.containsKey(player.getUniqueId())) { - return 0; - } - - long msLeft = spell.tracker.get(player.getUniqueId()) - System.currentTimeMillis(); - - long secondsLeft = (long) Math.ceil((double) msLeft / 1000); - - return NumberConversions.toInt(secondsLeft); - } - - /** - * Get a multiplier for a spell cooldown. - *

- * Used for perks - this should be reworked as it has hardcoded permission references. - * - * @param player The player to query. - * @return The multipiler. - */ - public static double getCooldownMultiplier(@NotNull final Player player) { - if (player.hasPermission("ecoenchants.cooldowntime.quarter")) { - return 0.25; - } - - if (player.hasPermission("ecoenchants.cooldowntime.third")) { - return 0.33; - } - - if (player.hasPermission("ecoenchants.cooldowntime.half")) { - return 0.5; - } - - if (player.hasPermission("ecoenchants.cooldowntime.75")) { - return 0.75; - } - - return 1; - } + public abstract boolean onUse(@NotNull Player player, + int level, + @NotNull PlayerInteractEvent event); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/meta/EnchantmentRarity.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/meta/EnchantmentRarity.java index d8eaabd5..a94be7c6 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/meta/EnchantmentRarity.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/meta/EnchantmentRarity.java @@ -1,8 +1,9 @@ package com.willfp.ecoenchants.enchantments.meta; +import com.willfp.eco.core.config.ConfigUpdater; import com.willfp.eco.util.StringUtils; -import com.willfp.eco.util.config.updating.annotations.ConfigUpdater; -import com.willfp.ecoenchants.config.EcoEnchantsConfigs; +import com.willfp.ecoenchants.EcoEnchantsPlugin; +import com.willfp.ecoenchants.config.configs.RarityYml; import lombok.Getter; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; @@ -19,36 +20,35 @@ public class EnchantmentRarity { */ private static final Set REGISTERED = new HashSet<>(); + static { + update(); + } + /** * The name of the rarity. */ @Getter private final String name; - /** * The probability of getting an enchantment with this rarity from an enchanting table. */ @Getter private final double tableProbability; - /** * The minimum xp level to get an enchantment of this rarity from an enchanting table. */ @Getter private final int minimumLevel; - /** * The probability of a villager obtaining an enchantment with this rarity. */ @Getter private final double villagerProbability; - /** * The probability of an item in a loot chest having an enchantment with this rarity. */ @Getter private final double lootProbability; - /** * The custom display color, or null if not enabled. */ @@ -79,6 +79,47 @@ public class EnchantmentRarity { this.customColor = customColor; } + /** + * Get EnchantmentRarity matching name. + * + * @param name The name to search for. + * @return The matching EnchantmentRarity, or null if not found. + */ + public static EnchantmentRarity getByName(@NotNull final String name) { + Optional matching = REGISTERED.stream().filter(rarity -> rarity.getName().equalsIgnoreCase(name)).findFirst(); + return matching.orElse(null); + } + + /** + * Update all rarities. + */ + @ConfigUpdater + public static void update() { + RarityYml rarityYml = EcoEnchantsPlugin.getInstance().getRarityYml(); + List raritiesNames = rarityYml.getRarities(); + raritiesNames.forEach(rarity -> { + double probability = rarityYml.getDouble("rarities." + rarity + ".table-probability"); + int minimumLevel = rarityYml.getInt("rarities." + rarity + ".minimum-level"); + double villagerProbability = rarityYml.getDouble("rarities." + rarity + ".villager-probability"); + double lootProbability = rarityYml.getDouble("rarities." + rarity + ".loot-probability"); + String customColor = null; + if (rarityYml.getBool("rarities." + rarity + ".custom-color.enabled")) { + customColor = StringUtils.translate(rarityYml.getString("rarities." + rarity + ".custom-color.color")); + } + + new EnchantmentRarity(rarity, probability, minimumLevel, villagerProbability, lootProbability, customColor).register(); + }); + } + + /** + * Get all rarities. + * + * @return A set of all rarities. + */ + public static Set values() { + return REGISTERED; + } + /** * Register rarity. */ @@ -114,48 +155,4 @@ public class EnchantmentRarity { public int hashCode() { return Objects.hash(getName()); } - - /** - * Get EnchantmentRarity matching name. - * - * @param name The name to search for. - * @return The matching EnchantmentRarity, or null if not found. - */ - public static EnchantmentRarity getByName(@NotNull final String name) { - Optional matching = REGISTERED.stream().filter(rarity -> rarity.getName().equalsIgnoreCase(name)).findFirst(); - return matching.orElse(null); - } - - /** - * Update all rarities. - */ - @ConfigUpdater - public static void update() { - List raritiesNames = EcoEnchantsConfigs.RARITY.getRarities(); - raritiesNames.forEach(rarity -> { - double probability = EcoEnchantsConfigs.RARITY.getDouble("rarities." + rarity + ".table-probability"); - int minimumLevel = EcoEnchantsConfigs.RARITY.getInt("rarities." + rarity + ".minimum-level"); - double villagerProbability = EcoEnchantsConfigs.RARITY.getDouble("rarities." + rarity + ".villager-probability"); - double lootProbability = EcoEnchantsConfigs.RARITY.getDouble("rarities." + rarity + ".loot-probability"); - String customColor = null; - if (EcoEnchantsConfigs.RARITY.getBool("rarities." + rarity + ".custom-color.enabled")) { - customColor = StringUtils.translate(EcoEnchantsConfigs.RARITY.getString("rarities." + rarity + ".custom-color.color")); - } - - new EnchantmentRarity(rarity, probability, minimumLevel, villagerProbability, lootProbability, customColor).register(); - }); - } - - /** - * Get all rarities. - * - * @return A set of all rarities. - */ - public static Set values() { - return REGISTERED; - } - - static { - update(); - } } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/meta/EnchantmentTarget.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/meta/EnchantmentTarget.java index d9a405bc..92280e0c 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/meta/EnchantmentTarget.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/meta/EnchantmentTarget.java @@ -1,8 +1,8 @@ package com.willfp.ecoenchants.enchantments.meta; import com.google.common.collect.ImmutableSet; -import com.willfp.eco.util.config.updating.annotations.ConfigUpdater; -import com.willfp.ecoenchants.config.EcoEnchantsConfigs; +import com.willfp.eco.core.config.ConfigUpdater; +import com.willfp.ecoenchants.EcoEnchantsPlugin; import lombok.Getter; import org.bukkit.Material; import org.jetbrains.annotations.NotNull; @@ -14,22 +14,25 @@ import java.util.Optional; import java.util.Set; public class EnchantmentTarget { + /** + * Target containing the materials from all other targets. + */ + public static final EnchantmentTarget ALL = new EnchantmentTarget("all", new HashSet<>()); /** * All registered targets. */ private static final Set REGISTERED = new HashSet<>(); - /** - * Target containing the materials from all other targets. - */ - public static final EnchantmentTarget ALL = new EnchantmentTarget("all", new HashSet<>()); + static { + REGISTERED.add(ALL); + update(); + } /** * The name of the target. */ @Getter private final String name; - /** * The materials of the target. */ @@ -49,14 +52,6 @@ public class EnchantmentTarget { this.materials = materials; } - public void register() { - Optional matching = REGISTERED.stream().filter(rarity -> rarity.getName().equalsIgnoreCase(name)).findFirst(); - matching.ifPresent(REGISTERED::remove); - matching.ifPresent(enchantmentTarget -> ALL.getMaterials().removeAll(enchantmentTarget.getMaterials())); - REGISTERED.add(this); - ALL.getMaterials().addAll(this.getMaterials()); - } - /** * Get EnchantmentTarget matching name. * @@ -73,10 +68,10 @@ public class EnchantmentTarget { */ @ConfigUpdater public static void update() { - List targetNames = EcoEnchantsConfigs.TARGET.getTargets(); + List targetNames = EcoEnchantsPlugin.getInstance().getTargetYml().getTargets(); ALL.materials.clear(); targetNames.forEach(name -> { - Set materials = EcoEnchantsConfigs.TARGET.getTargetMaterials(name); + Set materials = EcoEnchantsPlugin.getInstance().getTargetYml().getTargetMaterials(name); new EnchantmentTarget(name, materials).register(); }); } @@ -90,8 +85,11 @@ public class EnchantmentTarget { return ImmutableSet.copyOf(REGISTERED); } - static { - REGISTERED.add(ALL); - update(); + private void register() { + Optional matching = REGISTERED.stream().filter(rarity -> rarity.getName().equalsIgnoreCase(name)).findFirst(); + matching.ifPresent(REGISTERED::remove); + matching.ifPresent(enchantmentTarget -> ALL.getMaterials().removeAll(enchantmentTarget.getMaterials())); + REGISTERED.add(this); + ALL.getMaterials().addAll(this.getMaterials()); } } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/meta/EnchantmentType.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/meta/EnchantmentType.java index e26e56b2..b311626e 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/meta/EnchantmentType.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/meta/EnchantmentType.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.enchantments.meta; import com.google.common.collect.ImmutableList; -import com.willfp.eco.util.config.updating.annotations.ConfigUpdater; +import com.willfp.eco.core.config.ConfigUpdater; import com.willfp.ecoenchants.EcoEnchantsPlugin; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.itemtypes.Artifact; @@ -20,12 +20,6 @@ public class EnchantmentType { * Instance of EcoEnchants. */ private static final EcoEnchantsPlugin PLUGIN = EcoEnchantsPlugin.getInstance(); - - /** - * All registered types. - */ - private static final List REGISTERED = new ArrayList<>(); - /** * Most enchantments are like this. *

@@ -36,7 +30,6 @@ public class EnchantmentType { false, () -> PLUGIN.getLangYml().getString("not-curse-color") ); - /** * Negative enchantments. *

@@ -47,7 +40,6 @@ public class EnchantmentType { false, () -> PLUGIN.getLangYml().getString("curse-color") ); - /** * Extremely powerful enchantments. *

@@ -58,7 +50,6 @@ public class EnchantmentType { () -> !PLUGIN.getConfigYml().getBool("types.special.allow-multiple"), () -> PLUGIN.getLangYml().getString("special-color") ); - /** * Cosmetic enchantments. *

@@ -70,7 +61,6 @@ public class EnchantmentType { () -> PLUGIN.getLangYml().getString("artifact-color"), Artifact.class ); - /** * Ability enchantments. *

@@ -82,7 +72,10 @@ public class EnchantmentType { () -> PLUGIN.getLangYml().getString("spell-color"), Spell.class ); - + /** + * All registered types. + */ + private static final List REGISTERED = new ArrayList<>(); /** * Lambda to fetch the color of the type. */ @@ -92,25 +85,11 @@ public class EnchantmentType { * Lambda to fetch the singularity of the type. */ private final Supplier singularSupplier; - - /** - * If only one enchantment of this type is allowed on an item. - */ - @Getter - private boolean singular; - - /** - * The color of enchantments of this type to have in lore. - */ - @Getter - private String color; - /** * The name of the type. */ @Getter private final String name; - /** * The class that all enchantments of this type must extend. *

@@ -119,6 +98,16 @@ public class EnchantmentType { @Getter @Nullable private final Class requiredToExtend; + /** + * If only one enchantment of this type is allowed on an item. + */ + @Getter + private boolean singular; + /** + * The color of enchantments of this type to have in lore. + */ + @Getter + private String color; /** * Create simple EnchantmentType. @@ -201,6 +190,23 @@ public class EnchantmentType { REGISTERED.add(this); } + /** + * Update suppliers of all types. + */ + @ConfigUpdater + public static void update() { + REGISTERED.forEach(EnchantmentType::refresh); + } + + /** + * All registered enchantment types. + * + * @return All registered types. + */ + public static List values() { + return ImmutableList.copyOf(REGISTERED); + } + private void refresh() { this.color = colorSupplier.get(); this.singular = singularSupplier.get(); @@ -222,21 +228,4 @@ public class EnchantmentType { public int hashCode() { return Objects.hash(getName()); } - - /** - * Update suppliers of all types. - */ - @ConfigUpdater - public static void update() { - REGISTERED.forEach(EnchantmentType::refresh); - } - - /** - * All registered enchantment types. - * - * @return All registered types. - */ - public static List values() { - return ImmutableList.copyOf(REGISTERED); - } } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/merging/anvil/AnvilListeners.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/merging/anvil/AnvilListeners.java index 82d26eb0..4e6afb0e 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/merging/anvil/AnvilListeners.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/merging/anvil/AnvilListeners.java @@ -1,10 +1,10 @@ package com.willfp.ecoenchants.enchantments.support.merging.anvil; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; +import com.willfp.eco.core.proxy.ProxyConstants; +import com.willfp.eco.core.tuples.Pair; import com.willfp.eco.util.NumberUtils; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; -import com.willfp.eco.util.proxy.ProxyConstants; -import com.willfp.eco.util.tuples.Pair; import com.willfp.ecoenchants.proxy.proxies.OpenInventoryProxy; import com.willfp.ecoenchants.proxy.proxies.RepairCostProxy; import com.willfp.ecoenchants.util.ProxyUtils; @@ -37,7 +37,7 @@ public class AnvilListeners extends PluginDependent implements Listener { * * @param plugin The plugin to link to. */ - public AnvilListeners(@NotNull final AbstractEcoPlugin plugin) { + public AnvilListeners(@NotNull final EcoPlugin plugin) { super(plugin); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/merging/anvil/AnvilMerge.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/merging/anvil/AnvilMerge.java index 141d8b3f..f8f2be83 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/merging/anvil/AnvilMerge.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/merging/anvil/AnvilMerge.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.enchantments.support.merging.anvil; +import com.willfp.eco.core.tuples.Pair; import com.willfp.eco.util.StringUtils; -import com.willfp.eco.util.tuples.Pair; import com.willfp.ecoenchants.EcoEnchantsPlugin; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; @@ -37,11 +37,11 @@ public class AnvilMerge { /** * Merge items in anvil. * - * @param left The {@link ItemStack} on the left of the anvil. - * @param right The {@link ItemStack} in the middle of the anvil. - * @param old The previous {@link ItemStack} result. - * @param itemName The anvil display name. - * @param player The player merging (for permissions). + * @param left The {@link ItemStack} on the left of the anvil. + * @param right The {@link ItemStack} in the middle of the anvil. + * @param old The previous {@link ItemStack} result. + * @param itemName The anvil display name. + * @param player The player merging (for permissions). * @return The result, stored as a {@link Pair} of {@link ItemStack} and {@link Integer}. */ public Pair doMerge(@Nullable final ItemStack left, diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/merging/grindstone/GrindstoneListeners.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/merging/grindstone/GrindstoneListeners.java index 74167f63..a05fb91a 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/merging/grindstone/GrindstoneListeners.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/merging/grindstone/GrindstoneListeners.java @@ -1,7 +1,7 @@ package com.willfp.ecoenchants.enchantments.support.merging.grindstone; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; import org.bukkit.enchantments.Enchantment; import org.bukkit.entity.Player; import org.bukkit.event.EventHandler; @@ -22,7 +22,7 @@ public class GrindstoneListeners extends PluginDependent implements Listener { * * @param plugin The plugin to link to. */ - public GrindstoneListeners(@NotNull final AbstractEcoPlugin plugin) { + public GrindstoneListeners(@NotNull final EcoPlugin plugin) { super(plugin); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/obtaining/EnchantingListeners.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/obtaining/EnchantingListeners.java index 6c439ba0..6df726c7 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/obtaining/EnchantingListeners.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/obtaining/EnchantingListeners.java @@ -1,9 +1,9 @@ package com.willfp.ecoenchants.enchantments.support.obtaining; import com.google.common.collect.ImmutableSet; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; import com.willfp.eco.util.NumberUtils; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentType; @@ -29,6 +29,10 @@ import java.util.Set; import java.util.concurrent.atomic.AtomicBoolean; public class EnchantingListeners extends PluginDependent implements Listener { + /** + * All players currently enchanting a secondary item. + */ + public static final Map CURRENTLY_ENCHANTING_SECONDARY = new HashMap<>(); /** * All enchantments that by default cannot be enchanted in a table but are in EcoEnchants. */ @@ -39,17 +43,12 @@ public class EnchantingListeners extends PluginDependent implements Listener { .add(Material.SHEARS) .add(Material.CARROT_ON_A_STICK).build(); - /** - * All players currently enchanting a secondary item. - */ - public static final Map CURRENTLY_ENCHANTING_SECONDARY = new HashMap<>(); - /** * Instantiate enchanting listeners and link them to a specific plugin. * * @param plugin The plugin to link to. */ - public EnchantingListeners(@NotNull final AbstractEcoPlugin plugin) { + public EnchantingListeners(@NotNull final EcoPlugin plugin) { super(plugin); } @@ -230,7 +229,8 @@ public class EnchantingListeners extends PluginDependent implements Listener { try { event.getOffers()[2].setCost(NumberUtils.equalIfOver(event.getOffers()[2].getCost(), maxLevel)); - } catch (ArrayIndexOutOfBoundsException | NullPointerException ignored) { } + } catch (ArrayIndexOutOfBoundsException | NullPointerException ignored) { + } if (!SECONDARY_ENCHANTABLE.contains(event.getItem().getType())) { return; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/obtaining/VillagerListeners.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/obtaining/VillagerListeners.java index e60d71ab..001d433a 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/obtaining/VillagerListeners.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/support/obtaining/VillagerListeners.java @@ -1,9 +1,8 @@ package com.willfp.ecoenchants.enchantments.support.obtaining; - +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; import com.willfp.eco.util.NumberUtils; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import com.willfp.ecoenchants.enchantments.meta.EnchantmentTarget; @@ -31,7 +30,7 @@ public class VillagerListeners extends PluginDependent implements Listener { * * @param plugin The plugin. */ - public VillagerListeners(@NotNull final AbstractEcoPlugin plugin) { + public VillagerListeners(@NotNull final EcoPlugin plugin) { super(plugin); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/EnchantmentUtils.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/EnchantmentUtils.java index 72703d8d..43100c3d 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/EnchantmentUtils.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/EnchantmentUtils.java @@ -1,11 +1,9 @@ package com.willfp.ecoenchants.enchantments.util; - +import com.willfp.eco.core.integrations.placeholder.PlaceholderEntry; +import com.willfp.eco.core.integrations.placeholder.PlaceholderManager; import com.willfp.eco.util.NumberUtils; -import com.willfp.eco.util.PlayerUtils; import com.willfp.eco.util.StringUtils; -import com.willfp.eco.util.integrations.placeholder.PlaceholderEntry; -import com.willfp.eco.util.integrations.placeholder.PlaceholderManager; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; import lombok.experimental.UtilityClass; @@ -37,7 +35,7 @@ public class EnchantmentUtils { public static boolean isFullyChargeIfRequired(@NotNull final EcoEnchant enchantment, @NotNull final LivingEntity entity) { if (entity instanceof Player) { - if (PlayerUtils.getAttackCooldown((Player) entity) != 1.0f) { + if (((Player) entity).getAttackCooldown() != 1.0f) { return enchantment.getConfig().getBool(EcoEnchants.CONFIG_LOCATION + "allow-not-fully-charged"); } } @@ -60,7 +58,7 @@ public class EnchantmentUtils { enchantment.getConfig().getKeys(true).forEach(string -> { String key = string.replace("\\.", "_").replace("-", "_"); - Object object = enchantment.getConfig().getRaw(string); + Object object = enchantment.getConfig().get(string); PlaceholderManager.registerPlaceholder( new PlaceholderEntry( diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/FastTrig.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/FastTrig.java deleted file mode 100644 index 7a03d2fc..00000000 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/FastTrig.java +++ /dev/null @@ -1,52 +0,0 @@ -package com.willfp.ecoenchants.enchantments.util; - -import lombok.experimental.UtilityClass; - -@UtilityClass -public class FastTrig { - /** - * Precision. - */ - private static final int PRECISION = 100; - - /** - * Modulus. - */ - private static final int MODULUS = 360 * PRECISION; - - /** - * Sin lookup table. - */ - private static final double[] SIN_LOOKUP = new double[MODULUS]; - - private static double sinLookup(final int a) { - return a >= 0 ? SIN_LOOKUP[a % MODULUS] : -SIN_LOOKUP[-a % MODULUS]; - } - - /** - * Get the sin of a number. - * - * @param a The number. - * @return The sin. - */ - public static double sin(final double a) { - return sinLookup((int) (a * PRECISION + 0.5f)); - } - - /** - * Get the cosine of a number. - * - * @param a The number. - * @return The cosine. - */ - public static double cos(final double a) { - return sinLookup((int) ((a + 90f) * PRECISION + 0.5f)); - } - - - static { - for (int i = 0; i < SIN_LOOKUP.length; i++) { - SIN_LOOKUP[i] = Math.sin((i * Math.PI) / (PRECISION * 180)); - } - } -} diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/ItemConversions.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/ItemConversions.java index af991ed3..78d779fa 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/ItemConversions.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/ItemConversions.java @@ -1,8 +1,8 @@ package com.willfp.ecoenchants.enchantments.util; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; import com.willfp.eco.util.NumberUtils; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; import com.willfp.ecoenchants.display.EnchantDisplay; import com.willfp.ecoenchants.enchantments.EcoEnchant; import com.willfp.ecoenchants.enchantments.EcoEnchants; @@ -35,7 +35,7 @@ public class ItemConversions extends PluginDependent implements Listener { * * @param plugin Instance of EcoEnchants. */ - public ItemConversions(@NotNull final AbstractEcoPlugin plugin) { + public ItemConversions(@NotNull final EcoPlugin plugin) { super(plugin); } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/SpellActivateEvent.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/SpellActivateEvent.java index 6b115d7f..d67a4d6a 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/SpellActivateEvent.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/SpellActivateEvent.java @@ -39,6 +39,14 @@ public class SpellActivateEvent extends PlayerEvent implements Cancellable { this.cancelled = false; } + /** + * Bukkit parity. + * + * @return The handler list. + */ + public static HandlerList getHandlerList() { + return HANDLERS; + } @Override public boolean isCancelled() { @@ -55,13 +63,4 @@ public class SpellActivateEvent extends PlayerEvent implements Cancellable { public HandlerList getHandlers() { return HANDLERS; } - - /** - * Bukkit parity. - * - * @return The handler list. - */ - public static HandlerList getHandlerList() { - return HANDLERS; - } } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/SpellCancellationInterrupt.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/SpellCancellationInterrupt.java deleted file mode 100644 index ef6866f5..00000000 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/SpellCancellationInterrupt.java +++ /dev/null @@ -1,8 +0,0 @@ -package com.willfp.ecoenchants.enchantments.util; - -/** - * Exception to cancel spells (janky). - */ -public class SpellCancellationInterrupt extends Exception { - -} diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/TimedRunnable.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/TimedRunnable.java new file mode 100644 index 00000000..e6f399f3 --- /dev/null +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/TimedRunnable.java @@ -0,0 +1,10 @@ +package com.willfp.ecoenchants.enchantments.util; + +public interface TimedRunnable extends Runnable { + /** + * Get the time between repetitions. + * + * @return The time. + */ + long getTime(); +} diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/Watcher.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/Watcher.java index 3b9fadca..6abf2869 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/Watcher.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/Watcher.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.enchantments.util; -import com.willfp.eco.util.events.armorequip.ArmorEquipEvent; +import com.willfp.eco.core.events.ArmorEquipEvent; import org.bukkit.block.Block; import org.bukkit.entity.Arrow; import org.bukkit.entity.LivingEntity; diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/WatcherTriggers.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/WatcherTriggers.java index 09587f2a..8ce429c8 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/WatcherTriggers.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/enchantments/util/WatcherTriggers.java @@ -1,13 +1,13 @@ package com.willfp.ecoenchants.enchantments.util; import com.google.common.collect.Sets; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; +import com.willfp.eco.core.config.ConfigUpdater; +import com.willfp.eco.core.events.ArmorEquipEvent; +import com.willfp.eco.core.integrations.antigrief.AntigriefManager; +import com.willfp.eco.core.integrations.mcmmo.McmmoManager; import com.willfp.eco.util.TridentUtils; -import com.willfp.eco.util.config.updating.annotations.ConfigUpdater; -import com.willfp.eco.util.events.armorequip.ArmorEquipEvent; -import com.willfp.eco.util.integrations.antigrief.AntigriefManager; -import com.willfp.eco.util.integrations.mcmmo.McmmoManager; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; import com.willfp.ecoenchants.EcoEnchantsPlugin; import com.willfp.ecoenchants.enchantments.EcoEnchants; import org.bukkit.Material; @@ -59,10 +59,18 @@ public class WatcherTriggers extends PluginDependent implements Listener { * * @param plugin The plugin to link the events to. */ - public WatcherTriggers(@NotNull final AbstractEcoPlugin plugin) { + public WatcherTriggers(@NotNull final EcoPlugin plugin) { super(plugin); } + /** + * Update if allowed on npc. + */ + @ConfigUpdater + public static void update() { + allowOnNPC = EcoEnchantsPlugin.getInstance().getConfig().getBoolean("allow-on-npc"); + } + /** * Called when an entity shoots another entity with an arrow. * @@ -581,10 +589,6 @@ public class WatcherTriggers extends PluginDependent implements Listener { Player player = event.getPlayer(); this.getPlugin().getScheduler().runLater(() -> EcoEnchants.values().forEach(enchant -> { - if (event.isCancelled()) { - return; - } - if (!enchant.isEnabled()) { return; } @@ -731,12 +735,4 @@ public class WatcherTriggers extends PluginDependent implements Listener { enchant.onDeflect(blocker, attacker, level, event); }); } - - /** - * Update if allowed on npc. - */ - @ConfigUpdater - public static void update() { - allowOnNPC = EcoEnchantsPlugin.getInstance().getConfig().getBoolean("allow-on-npc"); - } } diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/integrations/essentials/EssentialsWrapper.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/integrations/essentials/EssentialsWrapper.java index efde3792..408f416f 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/integrations/essentials/EssentialsWrapper.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/integrations/essentials/EssentialsWrapper.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.integrations.essentials; -import com.willfp.eco.util.integrations.Integration; +import com.willfp.eco.core.integrations.Integration; public interface EssentialsWrapper extends Integration { /** diff --git a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/util/ProxyUtils.java b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/util/ProxyUtils.java index bd016bc1..9a75d687 100644 --- a/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/util/ProxyUtils.java +++ b/eco-core/core-plugin/src/main/java/com/willfp/ecoenchants/util/ProxyUtils.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.util; -import com.willfp.eco.util.proxy.AbstractProxy; +import com.willfp.eco.core.proxy.AbstractProxy; import com.willfp.ecoenchants.EcoEnchantsPlugin; import com.willfp.ecoenchants.proxy.util.ProxyFactory; import lombok.experimental.UtilityClass; diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/angerartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/angerartifact.yml index 4eb50523..f68c0f30 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/angerartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/angerartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/ashartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/ashartifact.yml index bc66537c..d3251e3c 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/ashartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/ashartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/barrierartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/barrierartifact.yml index 8e15ec22..da4458d8 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/barrierartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/barrierartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/cloudsartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/cloudsartifact.yml index 872575b1..332d2ed9 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/cloudsartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/cloudsartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/crimsonartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/crimsonartifact.yml index ecdeacc9..cac281d0 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/crimsonartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/crimsonartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/damageartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/damageartifact.yml index a87fa0a9..c5d40bcc 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/damageartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/damageartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/dragonartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/dragonartifact.yml index ce038cf7..e31eb21d 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/dragonartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/dragonartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/dustartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/dustartifact.yml index b3c54d3c..b2360be4 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/dustartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/dustartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/emeraldartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/emeraldartifact.yml index 6d0666b6..1697c0da 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/emeraldartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/emeraldartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/enchantmentartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/enchantmentartifact.yml index 86aaa882..471ccc38 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/enchantmentartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/enchantmentartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/endartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/endartifact.yml index 630c80fd..c90841cb 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/endartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/endartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/fireartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/fireartifact.yml index 6137df67..d3abef5e 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/fireartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/fireartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/heartartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/heartartifact.yml index 656ec97a..90c7c890 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/heartartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/heartartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/honeyartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/honeyartifact.yml index 1078a20d..553ae409 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/honeyartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/honeyartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/inkartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/inkartifact.yml index b1fc681d..db710d00 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/inkartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/inkartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/lavaartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/lavaartifact.yml index 63913341..fcc191ab 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/lavaartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/lavaartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/limeartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/limeartifact.yml index b630d252..f89bba07 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/limeartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/limeartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/magicartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/magicartifact.yml index f9a78371..a485d8ad 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/magicartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/magicartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/magmaartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/magmaartifact.yml index 23debddc..271f3f10 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/magmaartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/magmaartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/musicartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/musicartifact.yml index 0af0b688..0a40c4a3 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/musicartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/musicartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/nautilusartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/nautilusartifact.yml index 6a930bdd..fff37780 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/nautilusartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/nautilusartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/netherartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/netherartifact.yml index b362f43f..1fd83497 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/netherartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/netherartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/redstoneartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/redstoneartifact.yml index f9b8f295..b291f23d 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/redstoneartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/redstoneartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/smokeartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/smokeartifact.yml index b341c70d..72311870 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/smokeartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/smokeartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/snowartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/snowartifact.yml index 78512ccb..80ea3749 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/snowartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/snowartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/soulartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/soulartifact.yml index 7ff2b1f5..59c0249a 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/soulartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/soulartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/soulfireartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/soulfireartifact.yml index b7bc267f..686548ef 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/soulfireartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/soulfireartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/sparkleartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/sparkleartifact.yml index 404308c9..714331cc 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/sparkleartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/sparkleartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/sweepartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/sweepartifact.yml index 47a7e60e..83bb4377 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/sweepartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/sweepartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/tearartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/tearartifact.yml index cf04fa57..f3e768eb 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/tearartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/tearartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/totemartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/totemartifact.yml index cb9cd3bf..5c345b5b 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/totemartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/totemartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/villagerartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/villagerartifact.yml index d6d0ffb3..1acbbaee 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/villagerartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/villagerartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/warpedartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/warpedartifact.yml index 76a956a2..5e0ccc02 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/warpedartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/warpedartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/waterartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/waterartifact.yml index d7f24625..5189ac95 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/waterartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/waterartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/witchartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/witchartifact.yml index d25c86bd..281075d2 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/witchartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/witchartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/artifact/zapartifact.yml b/eco-core/core-plugin/src/main/resources/enchants/artifact/zapartifact.yml index faaf2b59..0d615399 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/artifact/zapartifact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/artifact/zapartifact.yml @@ -22,8 +22,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: # For Attack diff --git a/eco-core/core-plugin/src/main/resources/enchants/curse/breaklessnesscurse.yml b/eco-core/core-plugin/src/main/resources/enchants/curse/breaklessnesscurse.yml index 574f6048..6c4d1e25 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/curse/breaklessnesscurse.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/curse/breaklessnesscurse.yml @@ -19,8 +19,8 @@ general-config: - hoe - shovel grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: chance-per-level: 15 \ No newline at end of file diff --git a/eco-core/core-plugin/src/main/resources/enchants/curse/callingcurse.yml b/eco-core/core-plugin/src/main/resources/enchants/curse/callingcurse.yml index 892d5f47..7fe81ebe 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/curse/callingcurse.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/curse/callingcurse.yml @@ -19,7 +19,7 @@ general-config: - leggings - boots grindstoneable: false - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - mending diff --git a/eco-core/core-plugin/src/main/resources/enchants/curse/decaycurse.yml b/eco-core/core-plugin/src/main/resources/enchants/curse/decaycurse.yml index 7b0cf141..5104268f 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/curse/decaycurse.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/curse/decaycurse.yml @@ -16,7 +16,7 @@ general-config: targets: - all grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - mending - repairing diff --git a/eco-core/core-plugin/src/main/resources/enchants/curse/fragilitycurse.yml b/eco-core/core-plugin/src/main/resources/enchants/curse/fragilitycurse.yml index 868860e2..e0620d42 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/curse/fragilitycurse.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/curse/fragilitycurse.yml @@ -16,7 +16,7 @@ general-config: targets: - all grindstoneable: false - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - unbreaking diff --git a/eco-core/core-plugin/src/main/resources/enchants/curse/harmlessnesscurse.yml b/eco-core/core-plugin/src/main/resources/enchants/curse/harmlessnesscurse.yml index 049e2832..a36ba689 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/curse/harmlessnesscurse.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/curse/harmlessnesscurse.yml @@ -17,8 +17,8 @@ general-config: - sword - axe grindstoneable: false - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: chance-per-level: 15 \ No newline at end of file diff --git a/eco-core/core-plugin/src/main/resources/enchants/curse/hungercurse.yml b/eco-core/core-plugin/src/main/resources/enchants/curse/hungercurse.yml index ace9721d..29367678 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/curse/hungercurse.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/curse/hungercurse.yml @@ -16,9 +16,9 @@ general-config: targets: - helmet grindstoneable: false - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - sating config: - # No config is available for this enchantment \ No newline at end of file +# No config is available for this enchantment \ No newline at end of file diff --git a/eco-core/core-plugin/src/main/resources/enchants/curse/inaccuracycurse.yml b/eco-core/core-plugin/src/main/resources/enchants/curse/inaccuracycurse.yml index 85579089..83970eef 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/curse/inaccuracycurse.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/curse/inaccuracycurse.yml @@ -16,8 +16,8 @@ general-config: targets: - bow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: spread: 0.2 \ No newline at end of file diff --git a/eco-core/core-plugin/src/main/resources/enchants/curse/misfortunecurse.yml b/eco-core/core-plugin/src/main/resources/enchants/curse/misfortunecurse.yml index abca3c69..bb318b5b 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/curse/misfortunecurse.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/curse/misfortunecurse.yml @@ -19,7 +19,7 @@ general-config: - hoe - shovel grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - fortune diff --git a/eco-core/core-plugin/src/main/resources/enchants/curse/permanencecurse.yml b/eco-core/core-plugin/src/main/resources/enchants/curse/permanencecurse.yml index 8cfb2b5a..7037820c 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/curse/permanencecurse.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/curse/permanencecurse.yml @@ -16,9 +16,9 @@ general-config: targets: - all grindstoneable: false - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - mending config: - # No config is available for this enchantment \ No newline at end of file +# No config is available for this enchantment \ No newline at end of file diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/abattoir.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/abattoir.yml index 393bde6d..27731089 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/abattoir.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/abattoir.yml @@ -24,7 +24,7 @@ general-config: - arachnid - impaling maximum-level: 5 - disabled-in-worlds: [] + disabled-in-worlds: [ ] config: multiplier: 0.4 # Formula is (multiplier * (level + 1) + 1)*damage | Power is 0.25 \ No newline at end of file diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/abrasion.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/abrasion.yml index faed0a8b..0c365c9b 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/abrasion.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/abrasion.yml @@ -17,8 +17,8 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/aerial.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/aerial.yml index 80dbebf3..8f41807a 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/aerial.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/aerial.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/aquatic.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/aquatic.yml index e0087853..3a150662 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/aquatic.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/aquatic.yml @@ -16,8 +16,8 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 8 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/arachnid.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/arachnid.yml index b377a120..53abe9b5 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/arachnid.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/arachnid.yml @@ -16,7 +16,7 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - serrated - bladed diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/arborist.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/arborist.yml index a764c172..abfb1806 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/arborist.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/arborist.yml @@ -17,7 +17,7 @@ general-config: - axe - shears grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - silk_touch maximum-level: 4 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/arcanic.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/arcanic.yml index 8dcce376..1d017ffa 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/arcanic.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/arcanic.yml @@ -19,8 +19,8 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/atmospheric.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/atmospheric.yml index 193f73ac..9d510829 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/atmospheric.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/atmospheric.yml @@ -16,8 +16,8 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/aversion.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/aversion.yml index 12130f11..8e27083d 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/aversion.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/aversion.yml @@ -16,8 +16,8 @@ general-config: targets: - helmet grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: - # No config is available for this enchantment. +# No config is available for this enchantment. diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/backstab.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/backstab.yml index 54f3b528..582fad9c 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/backstab.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/backstab.yml @@ -17,8 +17,8 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/beheading.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/beheading.yml index 3a6a285a..e23250fb 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/beheading.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/beheading.yml @@ -17,8 +17,8 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/blastmining.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/blastmining.yml index 227e7f40..088efcad 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/blastmining.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/blastmining.yml @@ -16,7 +16,7 @@ general-config: targets: - pickaxe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - drill - vein diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/bleed.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/bleed.yml index 79a1a979..e0172999 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/bleed.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/bleed.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 7 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/blind.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/blind.yml index d3cb525c..9bdf47ea 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/blind.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/blind.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/blockbreather.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/blockbreather.yml index 3d2d3b45..8b2b023f 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/blockbreather.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/blockbreather.yml @@ -16,8 +16,8 @@ general-config: targets: - helmet grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/bosshunter.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/bosshunter.yml index d977ca59..59c7fa31 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/bosshunter.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/bosshunter.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 8 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/buckshot.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/buckshot.yml index 82238f8b..0047b9e3 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/buckshot.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/buckshot.yml @@ -16,7 +16,7 @@ general-config: targets: - bow grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - succession - pentashot diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/butchering.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/butchering.yml index 3626ba5b..65a5e780 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/butchering.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/butchering.yml @@ -17,7 +17,7 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - sharpness - bane_of_arthropods diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/cerebral.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/cerebral.yml index 65d0ea35..283646d3 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/cerebral.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/cerebral.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 8 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/chopless.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/chopless.yml index 2b124b5e..39201c2c 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/chopless.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/chopless.yml @@ -19,8 +19,8 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/cleave.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/cleave.yml index 58d3fa3f..a32ab524 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/cleave.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/cleave.yml @@ -16,7 +16,7 @@ general-config: targets: - axe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - carve maximum-level: 8 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/collateral.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/collateral.yml index 8874c829..15a6639e 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/collateral.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/collateral.yml @@ -16,9 +16,9 @@ general-config: targets: - bow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 4 config: - # No config is available for this enchantment +# No config is available for this enchantment diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/conclude.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/conclude.yml index 365d6152..0c5a2908 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/conclude.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/conclude.yml @@ -16,8 +16,8 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 5 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/corrosive.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/corrosive.yml index 0c946e7c..b1dedb0c 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/corrosive.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/corrosive.yml @@ -17,9 +17,9 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: - # No config is available for this enchantment \ No newline at end of file +# No config is available for this enchantment \ No newline at end of file diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/cranial.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/cranial.yml index 9e456d5c..a5c346a1 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/cranial.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/cranial.yml @@ -16,8 +16,8 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 8 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/criticals.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/criticals.yml index fe7390f9..02285036 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/criticals.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/criticals.yml @@ -17,8 +17,8 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/cubism.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/cubism.yml index c1364304..44b8b6a7 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/cubism.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/cubism.yml @@ -17,8 +17,8 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 7 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/defender.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/defender.yml index aed2c950..301d549e 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/defender.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/defender.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: - # No config available for this enchantment \ No newline at end of file +# No config available for this enchantment \ No newline at end of file diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/deflection.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/deflection.yml index 8a323645..3e8b0be7 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/deflection.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/deflection.yml @@ -16,8 +16,8 @@ general-config: targets: - shield grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/defusion.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/defusion.yml index 8656bb7b..84b83730 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/defusion.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/defusion.yml @@ -17,7 +17,7 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - sharpness - bane_of_arthropods diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/dexterous.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/dexterous.yml index 9b0d9f10..866c951c 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/dexterous.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/dexterous.yml @@ -17,8 +17,8 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/disable.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/disable.yml index 4de4dc1a..46ddaee6 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/disable.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/disable.yml @@ -16,8 +16,8 @@ general-config: targets: - axe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/disappear.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/disappear.yml index abf7a32e..a4132b2f 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/disappear.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/disappear.yml @@ -19,8 +19,8 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/diurnal.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/diurnal.yml index 2b7565fa..a0e1bf37 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/diurnal.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/diurnal.yml @@ -16,7 +16,7 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - nocturnal maximum-level: 6 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/diverse.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/diverse.yml index 77858deb..90daec21 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/diverse.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/diverse.yml @@ -16,8 +16,8 @@ general-config: targets: - axe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/drill.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/drill.yml index 033044fa..ac97562d 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/drill.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/drill.yml @@ -18,7 +18,7 @@ general-config: - axe - shovel grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - lumberjack - blast_mining diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/dullness.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/dullness.yml index d8fdab06..f2161e5a 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/dullness.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/dullness.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/dweller.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/dweller.yml index a40e6538..9919b3ed 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/dweller.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/dweller.yml @@ -17,8 +17,8 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/economical.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/economical.yml index ec120121..37639633 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/economical.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/economical.yml @@ -16,8 +16,8 @@ general-config: targets: - elytra grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 4 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/electroshock.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/electroshock.yml index 1ad4ba96..d8db781a 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/electroshock.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/electroshock.yml @@ -17,7 +17,7 @@ general-config: - shield grindstoneable: true - conflicts: [] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/enderism.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/enderism.yml index 5d927479..4ff452cb 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/enderism.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/enderism.yml @@ -17,7 +17,7 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - netheric maximum-level: 6 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/enderslayer.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/enderslayer.yml index 57a14953..250b15b7 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/enderslayer.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/enderslayer.yml @@ -17,7 +17,7 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - sharpness - bane_of_arthropods diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/endinfusion.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/endinfusion.yml index 3865d5fb..bb1ef03f 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/endinfusion.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/endinfusion.yml @@ -16,7 +16,7 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - nether_infusion maximum-level: 6 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/evasion.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/evasion.yml index f2abb05b..7c63fba8 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/evasion.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/evasion.yml @@ -19,8 +19,8 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/extinguishing.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/extinguishing.yml index 5681b046..2593d280 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/extinguishing.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/extinguishing.yml @@ -19,8 +19,8 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/extract.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/extract.yml index 4a913fc0..c66464dc 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/extract.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/extract.yml @@ -16,8 +16,8 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/famine.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/famine.yml index 5ec4d632..3a182d9e 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/famine.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/famine.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 8 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/farmhand.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/farmhand.yml index 1d2f92c7..2f33f1ce 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/farmhand.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/farmhand.yml @@ -16,8 +16,8 @@ general-config: targets: - hoe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/fetching.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/fetching.yml index 216840d2..1dd24189 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/fetching.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/fetching.yml @@ -16,8 +16,8 @@ general-config: targets: - helmet grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: not-on-players: false \ No newline at end of file diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/finality.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/finality.yml index cd30d88b..5963d31a 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/finality.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/finality.yml @@ -16,8 +16,8 @@ general-config: targets: - bow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 5 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/finishing.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/finishing.yml index 9694129e..822ec502 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/finishing.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/finishing.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 5 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/fireaffinity.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/fireaffinity.yml index 0ad4fe64..b809bcc8 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/fireaffinity.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/fireaffinity.yml @@ -16,7 +16,7 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - water_affinity maximum-level: 7 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/firststrike.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/firststrike.yml index eb6523e7..363709a3 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/firststrike.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/firststrike.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 5 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/flinch.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/flinch.yml index e5e6e658..d85a5f3f 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/flinch.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/flinch.yml @@ -16,8 +16,8 @@ general-config: targets: - shield grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/forcefield.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/forcefield.yml index b3d47b82..fc6b7e91 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/forcefield.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/forcefield.yml @@ -19,8 +19,8 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/freerunner.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/freerunner.yml index 21144f2a..d5c6d3ba 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/freerunner.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/freerunner.yml @@ -16,8 +16,8 @@ general-config: targets: - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/frozen.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/frozen.yml index ddd6fe90..2f68a5b6 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/frozen.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/frozen.yml @@ -19,8 +19,8 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/fury.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/fury.yml index c60cd4e1..25e2ba66 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/fury.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/fury.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 7 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/goliath.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/goliath.yml index 69443a59..6383cdc0 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/goliath.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/goliath.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 8 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/graceful.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/graceful.yml index 268640b3..1073de8d 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/graceful.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/graceful.yml @@ -16,8 +16,8 @@ general-config: targets: - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/grapple.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/grapple.yml index ac6e7244..24f5d02d 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/grapple.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/grapple.yml @@ -17,7 +17,7 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - knockback - tornado diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/greenthumb.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/greenthumb.yml index 5f93cc2a..2724bd4e 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/greenthumb.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/greenthumb.yml @@ -16,8 +16,8 @@ general-config: targets: - hoe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: damage: true # Damage hoe on use \ No newline at end of file diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/grit.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/grit.yml index 027e59b3..76cbedb3 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/grit.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/grit.yml @@ -19,8 +19,8 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/hellish.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/hellish.yml index f2998355..e9ee63d7 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/hellish.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/hellish.yml @@ -16,7 +16,7 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - void_affinity maximum-level: 6 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/hook.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/hook.yml index 3e82ba78..34b4af18 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/hook.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/hook.yml @@ -16,7 +16,7 @@ general-config: targets: - bow grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - punch maximum-level: 2 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/horde.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/horde.yml index 2710f07e..f314e356 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/horde.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/horde.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 4 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/iceshot.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/iceshot.yml index b9750842..d9ad852b 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/iceshot.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/iceshot.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/identify.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/identify.yml index 844869e9..f534a6d8 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/identify.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/identify.yml @@ -16,8 +16,8 @@ general-config: targets: - shield grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/ignite.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/ignite.yml index 4085049e..c436bdef 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/ignite.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/ignite.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 8 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/illusionaspect.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/illusionaspect.yml index bf7067ef..9fd40969 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/illusionaspect.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/illusionaspect.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/impact.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/impact.yml index 4a1b8a17..9dfbfab8 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/impact.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/impact.yml @@ -16,8 +16,8 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/incandescence.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/incandescence.yml index 2554562e..faeac893 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/incandescence.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/incandescence.yml @@ -19,8 +19,8 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/infernaltouch.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/infernaltouch.yml index e5346a4a..180b023f 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/infernaltouch.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/infernaltouch.yml @@ -16,7 +16,7 @@ general-config: targets: - pickaxe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - silk_touch - stone_switcher diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/inferno.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/inferno.yml index ae79053f..4954e079 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/inferno.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/inferno.yml @@ -16,8 +16,8 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: - # No config available for this enchantment \ No newline at end of file +# No config available for this enchantment \ No newline at end of file diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/infuriate.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/infuriate.yml index a282446b..82cab5f8 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/infuriate.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/infuriate.yml @@ -16,8 +16,8 @@ general-config: targets: - shield grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 7 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/insecticide.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/insecticide.yml index ac6ad319..508fa4a5 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/insecticide.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/insecticide.yml @@ -16,7 +16,7 @@ general-config: targets: - bow grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - power - force diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/instantaneous.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/instantaneous.yml index 042f8dfd..a93d2af7 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/instantaneous.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/instantaneous.yml @@ -19,8 +19,8 @@ general-config: - shovel - hoe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 7 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/introversion.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/introversion.yml index ae2cfc01..d278438c 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/introversion.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/introversion.yml @@ -17,7 +17,7 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - sharpness - bane_of_arthropods diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/invigoration.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/invigoration.yml index 52e3c564..a3c0fef5 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/invigoration.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/invigoration.yml @@ -19,8 +19,8 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/kinetic.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/kinetic.yml index e32ac55a..781f42ec 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/kinetic.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/kinetic.yml @@ -16,8 +16,8 @@ general-config: targets: - elytra grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/launch.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/launch.yml index b26c2618..db2cc3ef 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/launch.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/launch.yml @@ -16,8 +16,8 @@ general-config: targets: - elytra grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 8 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/leeching.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/leeching.yml index abbd0c64..e18a25c9 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/leeching.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/leeching.yml @@ -17,7 +17,7 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - life_steal maximum-level: 3 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/lesion.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/lesion.yml index f9a41711..269eeabd 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/lesion.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/lesion.yml @@ -16,8 +16,8 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 7 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/levitate.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/levitate.yml index 50713908..44c48b6e 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/levitate.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/levitate.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/liquidshot.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/liquidshot.yml index afa4a11a..424a1d3e 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/liquidshot.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/liquidshot.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 5 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/luckycatch.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/luckycatch.yml index 8dda35af..042dd946 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/luckycatch.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/luckycatch.yml @@ -16,8 +16,8 @@ general-config: targets: - rod grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/lumberjack.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/lumberjack.yml index 9042d142..6b8e2157 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/lumberjack.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/lumberjack.yml @@ -16,7 +16,7 @@ general-config: targets: - axe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] maximum-level: 6 conflicts: - drill diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/magmawalker.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/magmawalker.yml index 098ed1fc..f2bdc598 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/magmawalker.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/magmawalker.yml @@ -16,8 +16,8 @@ general-config: targets: - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/magnetic.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/magnetic.yml index dfd7f63f..c20c0638 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/magnetic.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/magnetic.yml @@ -16,8 +16,8 @@ general-config: targets: - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 4 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/marking.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/marking.yml index 52fb70f1..f9ebb3b9 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/marking.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/marking.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 4 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/marksman.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/marksman.yml index 6c0c30d5..19da870a 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/marksman.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/marksman.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: remove-arrow-after-ticks: 120 #to prevent server lag, as arrows shot into the sky will not land. there are 20 ticks in a second. diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/necrotic.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/necrotic.yml index 51813d2b..81370321 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/necrotic.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/necrotic.yml @@ -16,7 +16,7 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - looting maximum-level: 4 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/netheric.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/netheric.yml index 8a5faae4..8938537a 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/netheric.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/netheric.yml @@ -17,7 +17,7 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - enderism maximum-level: 6 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/netherinfusion.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/netherinfusion.yml index eeef2341..666bd0a6 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/netherinfusion.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/netherinfusion.yml @@ -16,7 +16,7 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - end_infusion maximum-level: 6 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/nocturnal.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/nocturnal.yml index a9447dd0..2ed50518 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/nocturnal.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/nocturnal.yml @@ -16,7 +16,7 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - diurnal maximum-level: 6 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/optics.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/optics.yml index 33457e75..5681be55 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/optics.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/optics.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 5 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/oxygenate.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/oxygenate.yml index a41494a8..9384b040 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/oxygenate.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/oxygenate.yml @@ -19,8 +19,8 @@ general-config: - shovel - hoe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 8 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/pacify.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/pacify.yml index d4067145..290702f4 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/pacify.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/pacify.yml @@ -16,7 +16,7 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - serrated - bladed diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/paladin.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/paladin.yml index e5abab99..78ff703f 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/paladin.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/paladin.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/paralyze.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/paralyze.yml index c12a2c45..283493fe 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/paralyze.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/paralyze.yml @@ -16,8 +16,8 @@ general-config: targets: - shield grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/parasitic.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/parasitic.yml index 6f97a760..bb2fc8ff 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/parasitic.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/parasitic.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/parry.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/parry.yml index c9f92049..0a437834 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/parry.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/parry.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 4 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/phantasm.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/phantasm.yml index 628d2f34..8f44722f 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/phantasm.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/phantasm.yml @@ -16,7 +16,7 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - serrated - bladed diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/plasmic.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/plasmic.yml index ff8eade0..86f6c51f 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/plasmic.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/plasmic.yml @@ -16,7 +16,7 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - voltage maximum-level: 5 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/protector.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/protector.yml index fe2653b6..c2937c8f 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/protector.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/protector.yml @@ -17,8 +17,8 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: - # No config available for this enchantment \ No newline at end of file +# No config available for this enchantment \ No newline at end of file diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/proximity.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/proximity.yml index 42032da0..8e7cc0aa 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/proximity.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/proximity.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 5 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/puncture.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/puncture.yml index 461dc9ef..442b4229 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/puncture.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/puncture.yml @@ -16,8 +16,8 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/quadrilateralism.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/quadrilateralism.yml index c6aad7ea..eca4f2d6 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/quadrilateralism.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/quadrilateralism.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 7 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/radiance.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/radiance.yml index 90bdcf40..e609f533 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/radiance.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/radiance.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 4 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/rage.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/rage.yml index 1d27726d..906720fa 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/rage.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/rage.yml @@ -16,8 +16,8 @@ general-config: targets: - bow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 5 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/rapid.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/rapid.yml index 323e21a4..28510c29 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/rapid.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/rapid.yml @@ -16,8 +16,8 @@ general-config: targets: - bow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/reaper.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/reaper.yml index 085a0511..9689ea62 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/reaper.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/reaper.yml @@ -17,8 +17,8 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/reel.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/reel.yml index 65cf4acb..90569893 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/reel.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/reel.yml @@ -16,8 +16,8 @@ general-config: targets: - rod grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/reinforcement.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/reinforcement.yml index d10bdb38..9263626b 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/reinforcement.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/reinforcement.yml @@ -16,8 +16,8 @@ general-config: targets: - elytra grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 4 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/rejuvenation.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/rejuvenation.yml index 5985f2b5..82813e54 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/rejuvenation.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/rejuvenation.yml @@ -19,8 +19,8 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/replenish.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/replenish.yml index 3ec98d2e..758d5ede 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/replenish.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/replenish.yml @@ -16,8 +16,8 @@ general-config: targets: - hoe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: - # No config is available for this enchantment \ No newline at end of file +# No config is available for this enchantment \ No newline at end of file diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/respirator.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/respirator.yml index 46dc68ef..7124274c 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/respirator.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/respirator.yml @@ -16,8 +16,8 @@ general-config: targets: - helmet grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/revenant.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/revenant.yml index 96e61dc8..135247f4 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/revenant.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/revenant.yml @@ -16,7 +16,7 @@ general-config: targets: - bow grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - power - force diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/sating.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/sating.yml index 5974c86c..4991ef01 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/sating.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/sating.yml @@ -16,8 +16,8 @@ general-config: targets: - helmet grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/serrated.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/serrated.yml index 5054f7f2..3d7481fd 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/serrated.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/serrated.yml @@ -16,7 +16,7 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - bladed - phantasm diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/settle.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/settle.yml index d6d3184e..fea790f1 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/settle.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/settle.yml @@ -16,7 +16,7 @@ general-config: targets: - bow grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - power - force diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/shockwave.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/shockwave.yml index e9a6e8fa..0009a2c9 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/shockwave.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/shockwave.yml @@ -16,8 +16,8 @@ general-config: targets: - bow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/shotassist.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/shotassist.yml index 40d70321..335fe17c 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/shotassist.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/shotassist.yml @@ -19,8 +19,8 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/sickening.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/sickening.yml index e4a586bb..f7222d4d 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/sickening.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/sickening.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/slaughter.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/slaughter.yml index a34231ad..bd75ed54 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/slaughter.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/slaughter.yml @@ -16,7 +16,7 @@ general-config: targets: - bow grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - power - force diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/slicing.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/slicing.yml index 56a65a33..f4b9f5b3 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/slicing.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/slicing.yml @@ -16,8 +16,8 @@ general-config: targets: - elytra grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 8 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/spearfishing.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/spearfishing.yml index c402ec7e..812aee46 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/spearfishing.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/spearfishing.yml @@ -16,8 +16,8 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/spiked.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/spiked.yml index ed50a986..c015ae3d 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/spiked.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/spiked.yml @@ -16,7 +16,7 @@ general-config: targets: - rod grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - harpoon maximum-level: 3 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/splash.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/splash.yml index 21e40689..5aa3a372 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/splash.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/splash.yml @@ -16,7 +16,7 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - wisdom maximum-level: 4 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/stab.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/stab.yml index df8f87ac..4fec62f6 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/stab.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/stab.yml @@ -16,8 +16,8 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 5 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/stalwart.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/stalwart.yml index 67ea6569..1fc7c68a 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/stalwart.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/stalwart.yml @@ -19,8 +19,8 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/stamina.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/stamina.yml index 63ca97ba..e7adf594 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/stamina.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/stamina.yml @@ -16,8 +16,8 @@ general-config: targets: - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 4 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/stoneswitcher.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/stoneswitcher.yml index dc7ffa7c..0f567330 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/stoneswitcher.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/stoneswitcher.yml @@ -16,7 +16,7 @@ general-config: targets: - pickaxe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - transfuse - silk_touch diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/strayaspect.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/strayaspect.yml index 4517e684..aed7db37 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/strayaspect.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/strayaspect.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/succession.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/succession.yml index 0f0179b3..c57cd0e1 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/succession.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/succession.yml @@ -16,7 +16,7 @@ general-config: targets: - bow grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - tripleshot - pentashot diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/supercritical.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/supercritical.yml index 0552873f..144a5f04 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/supercritical.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/supercritical.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/sycophant.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/sycophant.yml index 3d151778..8daaa16a 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/sycophant.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/sycophant.yml @@ -16,8 +16,8 @@ general-config: targets: - shield grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/tectonic.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/tectonic.yml index ceef7532..36fc8433 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/tectonic.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/tectonic.yml @@ -16,7 +16,7 @@ general-config: targets: - boots grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - feather_falling maximum-level: 2 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/telekinesis.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/telekinesis.yml index 503b0b1b..332c4cc7 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/telekinesis.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/telekinesis.yml @@ -23,8 +23,8 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: use-orb: true # Use experience orb above player to give xp. Use if you need mending interaction. diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/thor.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/thor.yml index 0aa16cc4..00e03c21 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/thor.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/thor.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/thrive.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/thrive.yml index af294f68..81112a1d 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/thrive.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/thrive.yml @@ -19,7 +19,7 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - prosperity maximum-level: 2 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/tornado.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/tornado.yml index e7ce86a1..3dc695bd 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/tornado.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/tornado.yml @@ -17,7 +17,7 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - knockback - grapple diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/toxic.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/toxic.yml index 2514dc8b..94757c9d 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/toxic.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/toxic.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/transfuse.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/transfuse.yml index c7de3555..8ada646b 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/transfuse.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/transfuse.yml @@ -16,7 +16,7 @@ general-config: targets: - pickaxe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - stone_switcher - silk_touch diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/tripleshot.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/tripleshot.yml index 79ee7536..1b4a5e7c 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/tripleshot.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/tripleshot.yml @@ -16,7 +16,7 @@ general-config: targets: - bow grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - succession - pentashot diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/vampireaspect.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/vampireaspect.yml index 1ed40208..6d9b3ba3 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/vampireaspect.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/vampireaspect.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/vein.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/vein.yml index 551d4f8e..3323ba2b 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/vein.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/vein.yml @@ -16,7 +16,7 @@ general-config: targets: - pickaxe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] maximum-level: 5 conflicts: - drill diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/venom.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/venom.yml index 664a6e6e..4bfe4dcd 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/venom.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/venom.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/voidaffinity.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/voidaffinity.yml index 71dc49a5..7fa75229 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/voidaffinity.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/voidaffinity.yml @@ -16,7 +16,7 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - netheric maximum-level: 5 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/voltage.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/voltage.yml index 4103e3bd..b32ed621 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/voltage.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/voltage.yml @@ -16,7 +16,7 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - plasmic maximum-level: 5 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/wateraffinity.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/wateraffinity.yml index 9c4c3b6c..93a65fb5 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/wateraffinity.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/wateraffinity.yml @@ -16,7 +16,7 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - fire_affinity maximum-level: 7 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/wateraspect.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/wateraspect.yml index c9ea411b..228c7e2e 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/wateraspect.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/wateraspect.yml @@ -17,7 +17,7 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - fire_aspect maximum-level: 2 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/weakening.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/weakening.yml index c1fa91b0..a96b9220 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/weakening.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/weakening.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 4 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/wisdom.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/wisdom.yml index 4cb5e1f7..e2b8b49a 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/wisdom.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/wisdom.yml @@ -23,7 +23,7 @@ general-config: - crossbow - trident grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - splash - intellect diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/woodswitcher.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/woodswitcher.yml index e9d9751d..d6e5fc72 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/woodswitcher.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/woodswitcher.yml @@ -16,7 +16,7 @@ general-config: targets: - axe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - silk_touch maximum-level: 6 diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/wound.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/wound.yml index 795cfe30..2c45c977 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/wound.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/wound.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 7 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/normal/zeus.yml b/eco-core/core-plugin/src/main/resources/enchants/normal/zeus.yml index 9fe898ea..6f161795 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/normal/zeus.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/normal/zeus.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/aiming.yml b/eco-core/core-plugin/src/main/resources/enchants/special/aiming.yml index ff0b92ae..6eac30c0 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/aiming.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/aiming.yml @@ -16,8 +16,8 @@ general-config: targets: - bow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 5 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/annihilate.yml b/eco-core/core-plugin/src/main/resources/enchants/special/annihilate.yml index a2ac16ba..0f726b99 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/annihilate.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/annihilate.yml @@ -17,7 +17,7 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - knockback - tornado diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/bladed.yml b/eco-core/core-plugin/src/main/resources/enchants/special/bladed.yml index c2afa7f9..fcb3c75e 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/bladed.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/bladed.yml @@ -16,7 +16,7 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - impaling - serrated diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/bolt.yml b/eco-core/core-plugin/src/main/resources/enchants/special/bolt.yml index f3154b21..aa10c171 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/bolt.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/bolt.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 4 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/carve.yml b/eco-core/core-plugin/src/main/resources/enchants/special/carve.yml index d2c574db..34b5e398 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/carve.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/carve.yml @@ -16,7 +16,7 @@ general-config: targets: - axe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - cleave maximum-level: 8 diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/confusion.yml b/eco-core/core-plugin/src/main/resources/enchants/special/confusion.yml index 82a5bfbb..e3b4452a 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/confusion.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/confusion.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 4 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/energizing.yml b/eco-core/core-plugin/src/main/resources/enchants/special/energizing.yml index d0fbd41f..770d505a 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/energizing.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/energizing.yml @@ -19,8 +19,8 @@ general-config: - shovel - hoe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/force.yml b/eco-core/core-plugin/src/main/resources/enchants/special/force.yml index 5081311c..60e83d98 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/force.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/force.yml @@ -16,7 +16,7 @@ general-config: targets: - bow grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - power - revenant diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/frenzy.yml b/eco-core/core-plugin/src/main/resources/enchants/special/frenzy.yml index 4783cd80..f5909ba2 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/frenzy.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/frenzy.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/harpoon.yml b/eco-core/core-plugin/src/main/resources/enchants/special/harpoon.yml index 19cfde43..65951316 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/harpoon.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/harpoon.yml @@ -16,7 +16,7 @@ general-config: targets: - rod grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - spiked maximum-level: 3 diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/indestructibility.yml b/eco-core/core-plugin/src/main/resources/enchants/special/indestructibility.yml index 37d6a1ca..982c4545 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/indestructibility.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/indestructibility.yml @@ -16,7 +16,7 @@ general-config: targets: - all grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - unbreaking maximum-level: 3 diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/instability.yml b/eco-core/core-plugin/src/main/resources/enchants/special/instability.yml index 08caa76e..ca53fac5 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/instability.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/instability.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/intellect.yml b/eco-core/core-plugin/src/main/resources/enchants/special/intellect.yml index 5c5c3697..2d316fdc 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/intellect.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/intellect.yml @@ -23,7 +23,7 @@ general-config: - hoe - sword grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - splash - wisdom diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/lifesteal.yml b/eco-core/core-plugin/src/main/resources/enchants/special/lifesteal.yml index 2c44b250..cb757ad3 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/lifesteal.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/lifesteal.yml @@ -17,7 +17,7 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - leeching maximum-level: 3 diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/pentashot.yml b/eco-core/core-plugin/src/main/resources/enchants/special/pentashot.yml index 9b6abde4..3982b1e1 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/pentashot.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/pentashot.yml @@ -16,7 +16,7 @@ general-config: targets: - bow grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - succession - tripleshot diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/preservation.yml b/eco-core/core-plugin/src/main/resources/enchants/special/preservation.yml index 7dcd09c7..f6f9e640 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/preservation.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/preservation.yml @@ -19,7 +19,7 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - protection - fire_protection diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/prosperity.yml b/eco-core/core-plugin/src/main/resources/enchants/special/prosperity.yml index 735d4608..ff8080c2 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/prosperity.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/prosperity.yml @@ -19,7 +19,7 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - thrive maximum-level: 3 diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/razor.yml b/eco-core/core-plugin/src/main/resources/enchants/special/razor.yml index 65e537ee..5106a7bc 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/razor.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/razor.yml @@ -16,7 +16,7 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - sharpness - smite diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/repairing.yml b/eco-core/core-plugin/src/main/resources/enchants/special/repairing.yml index 3714fd09..338a6356 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/repairing.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/repairing.yml @@ -16,7 +16,7 @@ general-config: targets: - all grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - mending - decay_curse diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/soulbound.yml b/eco-core/core-plugin/src/main/resources/enchants/special/soulbound.yml index 9335c0cf..bf38f4c2 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/soulbound.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/soulbound.yml @@ -16,8 +16,8 @@ general-config: targets: - all grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] config: remove-after: false # If soulbound should be 1-time use \ No newline at end of file diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/spring.yml b/eco-core/core-plugin/src/main/resources/enchants/special/spring.yml index 280bf856..9058f5d6 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/spring.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/spring.yml @@ -16,9 +16,9 @@ general-config: targets: - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: - # No config is available for this enchantment \ No newline at end of file +# No config is available for this enchantment \ No newline at end of file diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/streamlining.yml b/eco-core/core-plugin/src/main/resources/enchants/special/streamlining.yml index c0b96639..8041ee40 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/streamlining.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/streamlining.yml @@ -16,8 +16,8 @@ general-config: targets: - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 8 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/special/volatile.yml b/eco-core/core-plugin/src/main/resources/enchants/special/volatile.yml index 4cb7242c..c2aff0b5 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/special/volatile.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/special/volatile.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/spell/ascend.yml b/eco-core/core-plugin/src/main/resources/enchants/spell/ascend.yml index cc95b9a9..8f48c5b5 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/spell/ascend.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/spell/ascend.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/spell/charge.yml b/eco-core/core-plugin/src/main/resources/enchants/spell/charge.yml index 262d6557..4d348186 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/spell/charge.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/spell/charge.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/spell/dynamite.yml b/eco-core/core-plugin/src/main/resources/enchants/spell/dynamite.yml index bddc6686..cfcdea22 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/spell/dynamite.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/spell/dynamite.yml @@ -16,8 +16,8 @@ general-config: targets: - pickaxe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/spell/missile.yml b/eco-core/core-plugin/src/main/resources/enchants/spell/missile.yml index 952ce6d4..c1a2d630 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/spell/missile.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/spell/missile.yml @@ -17,8 +17,8 @@ general-config: - sword - axe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/spell/quake.yml b/eco-core/core-plugin/src/main/resources/enchants/spell/quake.yml index 39d88963..50182bb1 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/spell/quake.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/spell/quake.yml @@ -16,8 +16,8 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-core/core-plugin/src/main/resources/enchants/spell/vitalize.yml b/eco-core/core-plugin/src/main/resources/enchants/spell/vitalize.yml index 96e22b1c..b779035f 100644 --- a/eco-core/core-plugin/src/main/resources/enchants/spell/vitalize.yml +++ b/eco-core/core-plugin/src/main/resources/enchants/spell/vitalize.yml @@ -19,8 +19,8 @@ general-config: - pickaxe - shovel grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 1 config: diff --git a/eco-core/core-plugin/src/main/resources/plugin.yml b/eco-core/core-plugin/src/main/resources/plugin.yml index a0007306..b8107d4f 100644 --- a/eco-core/core-plugin/src/main/resources/plugin.yml +++ b/eco-core/core-plugin/src/main/resources/plugin.yml @@ -1,8 +1,8 @@ name: EcoEnchants version: ${projectVersion} main: com.willfp.ecoenchants.EcoEnchantsPlugin -api-version: 1.15 -authors: [Auxilor] +api-version: 1.16 +authors: [ Auxilor ] website: willfp.com load: STARTUP depend: diff --git a/eco-core/core-proxy/src/main/java/com/willfp/ecoenchants/proxy/proxies/FastGetEnchantsProxy.java b/eco-core/core-proxy/src/main/java/com/willfp/ecoenchants/proxy/proxies/FastGetEnchantsProxy.java index fc14a33d..2963cb10 100644 --- a/eco-core/core-proxy/src/main/java/com/willfp/ecoenchants/proxy/proxies/FastGetEnchantsProxy.java +++ b/eco-core/core-proxy/src/main/java/com/willfp/ecoenchants/proxy/proxies/FastGetEnchantsProxy.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.proxy.proxies; -import com.willfp.eco.util.proxy.AbstractProxy; +import com.willfp.eco.core.proxy.AbstractProxy; import org.bukkit.enchantments.Enchantment; import org.bukkit.inventory.ItemStack; import org.jetbrains.annotations.NotNull; @@ -18,7 +18,8 @@ public interface FastGetEnchantsProxy extends AbstractProxy { /** * Get the level of a specified enchantment on an item. - * @param itemStack The item to query. + * + * @param itemStack The item to query. * @param enchantment The enchantment to query. * @return The level found, or 0 if not present. */ diff --git a/eco-core/core-proxy/src/main/java/com/willfp/ecoenchants/proxy/proxies/OpenInventoryProxy.java b/eco-core/core-proxy/src/main/java/com/willfp/ecoenchants/proxy/proxies/OpenInventoryProxy.java index 5b40791f..bfbe404a 100644 --- a/eco-core/core-proxy/src/main/java/com/willfp/ecoenchants/proxy/proxies/OpenInventoryProxy.java +++ b/eco-core/core-proxy/src/main/java/com/willfp/ecoenchants/proxy/proxies/OpenInventoryProxy.java @@ -1,12 +1,13 @@ package com.willfp.ecoenchants.proxy.proxies; -import com.willfp.eco.util.proxy.AbstractProxy; +import com.willfp.eco.core.proxy.AbstractProxy; import org.bukkit.entity.Player; import org.jetbrains.annotations.NotNull; public interface OpenInventoryProxy extends AbstractProxy { /** * Get the NMS inventory container for a player's inventory view. + * * @param player The player to query. * @return The NMS inventory container. */ diff --git a/eco-core/core-proxy/src/main/java/com/willfp/ecoenchants/proxy/proxies/RepairCostProxy.java b/eco-core/core-proxy/src/main/java/com/willfp/ecoenchants/proxy/proxies/RepairCostProxy.java index cf6d5c03..98821b08 100644 --- a/eco-core/core-proxy/src/main/java/com/willfp/ecoenchants/proxy/proxies/RepairCostProxy.java +++ b/eco-core/core-proxy/src/main/java/com/willfp/ecoenchants/proxy/proxies/RepairCostProxy.java @@ -1,6 +1,6 @@ package com.willfp.ecoenchants.proxy.proxies; -import com.willfp.eco.util.proxy.AbstractProxy; +import com.willfp.eco.core.proxy.AbstractProxy; import org.bukkit.inventory.ItemStack; import org.jetbrains.annotations.NotNull; diff --git a/eco-core/core-proxy/src/main/java/com/willfp/ecoenchants/proxy/util/ProxyFactory.java b/eco-core/core-proxy/src/main/java/com/willfp/ecoenchants/proxy/util/ProxyFactory.java index 017baa37..d8434e99 100644 --- a/eco-core/core-proxy/src/main/java/com/willfp/ecoenchants/proxy/util/ProxyFactory.java +++ b/eco-core/core-proxy/src/main/java/com/willfp/ecoenchants/proxy/util/ProxyFactory.java @@ -1,10 +1,10 @@ package com.willfp.ecoenchants.proxy.util; -import com.willfp.eco.util.internal.PluginDependent; -import com.willfp.eco.util.plugin.AbstractEcoPlugin; -import com.willfp.eco.util.proxy.AbstractProxy; -import com.willfp.eco.util.proxy.ProxyConstants; -import com.willfp.eco.util.proxy.UnsupportedVersionException; +import com.willfp.eco.core.EcoPlugin; +import com.willfp.eco.core.PluginDependent; +import com.willfp.eco.core.proxy.AbstractProxy; +import com.willfp.eco.core.proxy.ProxyConstants; +import com.willfp.eco.core.proxy.UnsupportedVersionException; import org.jetbrains.annotations.NotNull; import java.util.IdentityHashMap; @@ -27,7 +27,7 @@ public class ProxyFactory extends PluginDependent { * @param plugin The plugin to create proxies for. * @param proxyClass The class of the proxy interface. */ - public ProxyFactory(@NotNull final AbstractEcoPlugin plugin, + public ProxyFactory(@NotNull final EcoPlugin plugin, @NotNull final Class proxyClass) { super(plugin); this.proxyClass = proxyClass; diff --git a/eco-extensions/alchemy/src/main/java/com/willfp/ecoenchants/alchemy/Alchemy.java b/eco-extensions/alchemy/src/main/java/com/willfp/ecoenchants/alchemy/Alchemy.java index f5134320..814587cc 100644 --- a/eco-extensions/alchemy/src/main/java/com/willfp/ecoenchants/alchemy/Alchemy.java +++ b/eco-extensions/alchemy/src/main/java/com/willfp/ecoenchants/alchemy/Alchemy.java @@ -13,6 +13,11 @@ import org.bukkit.potion.PotionEffect; import org.jetbrains.annotations.NotNull; public class Alchemy extends EcoEnchant { + /** + * true Metadata key. + */ + private final FixedMetadataValue metaKeyTrue = this.getPlugin().getMetadataValueFactory().create(true); + /** * Instantiate Alchemy Enchantment. */ @@ -20,11 +25,6 @@ public class Alchemy extends EcoEnchant { super("alchemy", EnchantmentType.NORMAL); } - /** - * true Metadata key. - */ - private final FixedMetadataValue metaKeyTrue = this.getPlugin().getMetadataValueFactory().create(true); - /** * Enchantment functionality. * diff --git a/eco-extensions/alchemy/src/main/resources/enchants/normal/alchemy.yml b/eco-extensions/alchemy/src/main/resources/enchants/normal/alchemy.yml index 9caea8a2..9897e632 100644 --- a/eco-extensions/alchemy/src/main/resources/enchants/normal/alchemy.yml +++ b/eco-extensions/alchemy/src/main/resources/enchants/normal/alchemy.yml @@ -19,8 +19,8 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 6 config: diff --git a/eco-extensions/biomes/src/main/resources/enchants/normal/altitude.yml b/eco-extensions/biomes/src/main/resources/enchants/normal/altitude.yml index d2c29202..ea38af7c 100644 --- a/eco-extensions/biomes/src/main/resources/enchants/normal/altitude.yml +++ b/eco-extensions/biomes/src/main/resources/enchants/normal/altitude.yml @@ -20,7 +20,7 @@ general-config: - axe - trident grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - aquamarine - dehydration diff --git a/eco-extensions/biomes/src/main/resources/enchants/normal/aquamarine.yml b/eco-extensions/biomes/src/main/resources/enchants/normal/aquamarine.yml index 9a6cea04..1617e71f 100644 --- a/eco-extensions/biomes/src/main/resources/enchants/normal/aquamarine.yml +++ b/eco-extensions/biomes/src/main/resources/enchants/normal/aquamarine.yml @@ -20,7 +20,7 @@ general-config: - axe - trident grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - altitude - dehydration diff --git a/eco-extensions/biomes/src/main/resources/enchants/normal/dehydration.yml b/eco-extensions/biomes/src/main/resources/enchants/normal/dehydration.yml index 5f8dbfc4..1d9ccbbd 100644 --- a/eco-extensions/biomes/src/main/resources/enchants/normal/dehydration.yml +++ b/eco-extensions/biomes/src/main/resources/enchants/normal/dehydration.yml @@ -20,7 +20,7 @@ general-config: - axe - trident grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - altitude - aquamarine diff --git a/eco-extensions/biomes/src/main/resources/enchants/normal/elevation.yml b/eco-extensions/biomes/src/main/resources/enchants/normal/elevation.yml index 5a247ae0..6ec6c030 100644 --- a/eco-extensions/biomes/src/main/resources/enchants/normal/elevation.yml +++ b/eco-extensions/biomes/src/main/resources/enchants/normal/elevation.yml @@ -19,7 +19,7 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - glacial - heat_treated diff --git a/eco-extensions/biomes/src/main/resources/enchants/normal/glacial.yml b/eco-extensions/biomes/src/main/resources/enchants/normal/glacial.yml index 26eda066..b036d84f 100644 --- a/eco-extensions/biomes/src/main/resources/enchants/normal/glacial.yml +++ b/eco-extensions/biomes/src/main/resources/enchants/normal/glacial.yml @@ -19,7 +19,7 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - elevation - heat_treated diff --git a/eco-extensions/biomes/src/main/resources/enchants/normal/heattreated.yml b/eco-extensions/biomes/src/main/resources/enchants/normal/heattreated.yml index 99957d3b..8b0cc4c2 100644 --- a/eco-extensions/biomes/src/main/resources/enchants/normal/heattreated.yml +++ b/eco-extensions/biomes/src/main/resources/enchants/normal/heattreated.yml @@ -19,7 +19,7 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - elevation - glacial diff --git a/eco-extensions/biomes/src/main/resources/enchants/normal/icelord.yml b/eco-extensions/biomes/src/main/resources/enchants/normal/icelord.yml index 43d08bed..669ab4c3 100644 --- a/eco-extensions/biomes/src/main/resources/enchants/normal/icelord.yml +++ b/eco-extensions/biomes/src/main/resources/enchants/normal/icelord.yml @@ -20,7 +20,7 @@ general-config: - axe - trident grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - altitide - aquamarine diff --git a/eco-extensions/biomes/src/main/resources/enchants/normal/oceanic.yml b/eco-extensions/biomes/src/main/resources/enchants/normal/oceanic.yml index f7b77b11..ffba2b9f 100644 --- a/eco-extensions/biomes/src/main/resources/enchants/normal/oceanic.yml +++ b/eco-extensions/biomes/src/main/resources/enchants/normal/oceanic.yml @@ -19,7 +19,7 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - elevation - glacial diff --git a/eco-extensions/biomes/src/main/resources/enchants/normal/rainforest.yml b/eco-extensions/biomes/src/main/resources/enchants/normal/rainforest.yml index bb76f958..8e299bbb 100644 --- a/eco-extensions/biomes/src/main/resources/enchants/normal/rainforest.yml +++ b/eco-extensions/biomes/src/main/resources/enchants/normal/rainforest.yml @@ -20,7 +20,7 @@ general-config: - axe - trident grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - altitude - aquamarine diff --git a/eco-extensions/biomes/src/main/resources/enchants/normal/tropical.yml b/eco-extensions/biomes/src/main/resources/enchants/normal/tropical.yml index bc0a2b39..71431756 100644 --- a/eco-extensions/biomes/src/main/resources/enchants/normal/tropical.yml +++ b/eco-extensions/biomes/src/main/resources/enchants/normal/tropical.yml @@ -19,7 +19,7 @@ general-config: - leggings - boots grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - elevation - glacial diff --git a/eco-extensions/effects/src/main/java/com/willfp/ecoenchants/effects/EffectsEnchantment.java b/eco-extensions/effects/src/main/java/com/willfp/ecoenchants/effects/EffectsEnchantment.java index 715024a0..ed3e7239 100644 --- a/eco-extensions/effects/src/main/java/com/willfp/ecoenchants/effects/EffectsEnchantment.java +++ b/eco-extensions/effects/src/main/java/com/willfp/ecoenchants/effects/EffectsEnchantment.java @@ -27,7 +27,7 @@ public abstract class EffectsEnchantment extends EcoEnchant { this.getPlugin().getScheduler().runLater(() -> { if (player.hasPotionEffect(this.getPotionEffect()) && player.getPotionEffect(this.getPotionEffect()).getDuration() >= 1639) { - player.removePotionEffect(this.getPotionEffect()); + player.removePotionEffect(this.getPotionEffect()); } int level = EnchantChecks.getArmorPoints(player, this); diff --git a/eco-extensions/effects/src/main/resources/enchants/normal/jumpboost.yml b/eco-extensions/effects/src/main/resources/enchants/normal/jumpboost.yml index 694d36fb..abc42f1c 100644 --- a/eco-extensions/effects/src/main/resources/enchants/normal/jumpboost.yml +++ b/eco-extensions/effects/src/main/resources/enchants/normal/jumpboost.yml @@ -16,10 +16,10 @@ general-config: targets: - boots grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - spring maximum-level: 3 config: - # No config is available for this enchantment \ No newline at end of file +# No config is available for this enchantment \ No newline at end of file diff --git a/eco-extensions/effects/src/main/resources/enchants/normal/nightvision.yml b/eco-extensions/effects/src/main/resources/enchants/normal/nightvision.yml index 9f72038d..4fe5cdb5 100644 --- a/eco-extensions/effects/src/main/resources/enchants/normal/nightvision.yml +++ b/eco-extensions/effects/src/main/resources/enchants/normal/nightvision.yml @@ -16,9 +16,9 @@ general-config: targets: - helmet grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 1 config: - # No config is available for this enchantment \ No newline at end of file +# No config is available for this enchantment \ No newline at end of file diff --git a/eco-extensions/effects/src/main/resources/enchants/normal/regeneration.yml b/eco-extensions/effects/src/main/resources/enchants/normal/regeneration.yml index 451f6312..a676e695 100644 --- a/eco-extensions/effects/src/main/resources/enchants/normal/regeneration.yml +++ b/eco-extensions/effects/src/main/resources/enchants/normal/regeneration.yml @@ -16,9 +16,9 @@ general-config: targets: - helmet grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 2 config: - # No config is available for this enchantment \ No newline at end of file +# No config is available for this enchantment \ No newline at end of file diff --git a/eco-extensions/effects/src/main/resources/enchants/normal/speed.yml b/eco-extensions/effects/src/main/resources/enchants/normal/speed.yml index 6c07dbc2..714042ff 100644 --- a/eco-extensions/effects/src/main/resources/enchants/normal/speed.yml +++ b/eco-extensions/effects/src/main/resources/enchants/normal/speed.yml @@ -16,10 +16,10 @@ general-config: targets: - boots grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - streamlining maximum-level: 3 config: - # No config is available for this enchantment \ No newline at end of file +# No config is available for this enchantment \ No newline at end of file diff --git a/eco-extensions/effects/src/main/resources/enchants/normal/waterbreathing.yml b/eco-extensions/effects/src/main/resources/enchants/normal/waterbreathing.yml index fae51bf1..122233e9 100644 --- a/eco-extensions/effects/src/main/resources/enchants/normal/waterbreathing.yml +++ b/eco-extensions/effects/src/main/resources/enchants/normal/waterbreathing.yml @@ -16,9 +16,9 @@ general-config: targets: - helmet grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 1 config: - # No config is available for this enchantment \ No newline at end of file +# No config is available for this enchantment \ No newline at end of file diff --git a/eco-extensions/endershot/src/main/resources/enchants/normal/endershot.yml b/eco-extensions/endershot/src/main/resources/enchants/normal/endershot.yml index df64b360..bf9c02ff 100644 --- a/eco-extensions/endershot/src/main/resources/enchants/normal/endershot.yml +++ b/eco-extensions/endershot/src/main/resources/enchants/normal/endershot.yml @@ -17,8 +17,8 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 1 config: diff --git a/eco-extensions/firewand/src/main/resources/enchants/spell/firewand.yml b/eco-extensions/firewand/src/main/resources/enchants/spell/firewand.yml index fda2a949..028b1a5c 100644 --- a/eco-extensions/firewand/src/main/resources/enchants/spell/firewand.yml +++ b/eco-extensions/firewand/src/main/resources/enchants/spell/firewand.yml @@ -17,8 +17,8 @@ general-config: - rod - carrot_stick grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/MMOPrerequisites.java b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/MMOPrerequisites.java index 119b7b8e..d24abc6b 100644 --- a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/MMOPrerequisites.java +++ b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/MMOPrerequisites.java @@ -21,7 +21,7 @@ public class MMOPrerequisites { ); public static Prerequisite[] append(Prerequisite[] array, Prerequisite newElement) { - Prerequisite[] copy = new Prerequisite[array.length+1]; + Prerequisite[] copy = new Prerequisite[array.length + 1]; System.arraycopy(array, 0, copy, 0, array.length); copy[array.length] = newElement; return copy; diff --git a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/abilities/Discounted.java b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/abilities/Discounted.java index df7b7566..adeedab3 100644 --- a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/abilities/Discounted.java +++ b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/abilities/Discounted.java @@ -18,13 +18,13 @@ public class Discounted extends MMOEnchantment { public void onAbility(AbilityUseEvent event) { Player player = event.getPlayer(); - if(!EnchantChecks.mainhand(player, this)) + if (!EnchantChecks.mainhand(player, this)) return; int level = EnchantChecks.getMainhandLevel(player, this); double cost = event.getAbility().getModifier("mana"); - if(cost == 0.0D) return; + if (cost == 0.0D) return; double multiplier = 1 - (this.getConfig().getDouble(EcoEnchants.CONFIG_LOCATION + "multiplier") * level); cost *= multiplier; diff --git a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/abilities/Recover.java b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/abilities/Recover.java index 19f1327d..40488adf 100644 --- a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/abilities/Recover.java +++ b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/abilities/Recover.java @@ -18,14 +18,14 @@ public class Recover extends MMOEnchantment { public void onAbility(AbilityUseEvent event) { Player player = event.getPlayer(); - if(!EnchantChecks.mainhand(player, this)) + if (!EnchantChecks.mainhand(player, this)) return; int level = EnchantChecks.getMainhandLevel(player, this); double cooldown = event.getAbility().getModifier("cooldown"); - if(cooldown == 0.0D) return; + if (cooldown == 0.0D) return; double multiplier = 1 - (this.getConfig().getDouble(EcoEnchants.CONFIG_LOCATION + "multiplier") * level); cooldown *= multiplier; diff --git a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Augment.java b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Augment.java index 88f53add..a432e884 100644 --- a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Augment.java +++ b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Augment.java @@ -24,7 +24,7 @@ public class Augment extends MMOEnchantment { data.getStatMap().getInstance(SharedStat.MAX_MANA).remove(KEY); - if(level == 0) { + if (level == 0) { MMOLib.plugin.getStats().runUpdates(data.getStatMap()); return; } diff --git a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Drain.java b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Drain.java index 17a2dc0b..90bef687 100644 --- a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Drain.java +++ b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Drain.java @@ -17,7 +17,7 @@ public class Drain extends MMOSpell { double amount = 1 - ((this.getConfig().getDouble(EcoEnchants.CONFIG_LOCATION + "percentage-per-level") / 100) * level); player.getNearbyEntities(radius, radius, radius).forEach(entity -> { - if(!(entity instanceof Player)) + if (!(entity instanceof Player)) return; Player victim = (Player) entity; diff --git a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Elixir.java b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Elixir.java index 724899cc..ff2a1c15 100644 --- a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Elixir.java +++ b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Elixir.java @@ -17,7 +17,7 @@ public class Elixir extends MMOEnchantment { @Override public void onMeleeAttack(@NotNull LivingEntity attacker, @NotNull LivingEntity victim, int level, @NotNull EntityDamageByEntityEvent event) { - if(!(attacker instanceof Player && victim instanceof Player)) + if (!(attacker instanceof Player && victim instanceof Player)) return; Player pAttacker = (Player) attacker; Player pVictim = (Player) victim; diff --git a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Siphon.java b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Siphon.java index 848234a9..2805ebfd 100644 --- a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Siphon.java +++ b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Siphon.java @@ -17,7 +17,7 @@ public class Siphon extends MMOEnchantment { @Override public void onArrowDamage(@NotNull LivingEntity attacker, @NotNull LivingEntity victim, @NotNull Arrow arrow, int level, @NotNull EntityDamageByEntityEvent event) { - if(!(attacker instanceof Player && victim instanceof Player)) + if (!(attacker instanceof Player && victim instanceof Player)) return; Player pAttacker = (Player) attacker; Player pVictim = (Player) victim; diff --git a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Spirituality.java b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Spirituality.java index cfbb1d25..34a99cec 100644 --- a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Spirituality.java +++ b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/mana/Spirituality.java @@ -16,13 +16,13 @@ public class Spirituality extends MMOEnchantment { @EventHandler public void onRegainMana(PlayerRegenResourceEvent event) { - if(!event.getResource().equals(PlayerResource.MANA)) + if (!event.getResource().equals(PlayerResource.MANA)) return; Player player = event.getPlayer(); int levels = EnchantChecks.getArmorPoints(player, this); - if(levels == 0) return; + if (levels == 0) return; double multiplier = this.getConfig().getDouble(EcoEnchants.CONFIG_LOCATION + "multiplier") * levels; event.setAmount(event.getAmount() * (multiplier + 1)); diff --git a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/misc/Strengthening.java b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/misc/Strengthening.java index 1bf1c8c7..035017b4 100644 --- a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/misc/Strengthening.java +++ b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/misc/Strengthening.java @@ -24,7 +24,7 @@ public class Strengthening extends MMOEnchantment { data.getStatMap().getInstance(SharedStat.ATTACK_DAMAGE).remove(KEY); - if(level == 0) { + if (level == 0) { MMOLib.plugin.getStats().runUpdates(data.getStatMap()); return; } diff --git a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/stamina/Athletic.java b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/stamina/Athletic.java index f006a42e..03ee8644 100644 --- a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/stamina/Athletic.java +++ b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/stamina/Athletic.java @@ -24,7 +24,7 @@ public class Athletic extends MMOEnchantment { data.getStatMap().getInstance(SharedStat.MAX_STAMINA).remove(KEY); - if(level == 0) { + if (level == 0) { MMOLib.plugin.getStats().runUpdates(data.getStatMap()); return; } diff --git a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/stamina/Endurance.java b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/stamina/Endurance.java index 45a1c127..bb2dfd06 100644 --- a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/stamina/Endurance.java +++ b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/stamina/Endurance.java @@ -16,13 +16,13 @@ public class Endurance extends MMOEnchantment { @EventHandler public void onRegainMana(PlayerRegenResourceEvent event) { - if(!event.getResource().equals(PlayerResource.STAMINA)) + if (!event.getResource().equals(PlayerResource.STAMINA)) return; Player player = event.getPlayer(); int levels = EnchantChecks.getArmorPoints(player, this); - if(levels == 0) return; + if (levels == 0) return; double multiplier = this.getConfig().getDouble(EcoEnchants.CONFIG_LOCATION + "multiplier") * levels; event.setAmount(event.getAmount() * (multiplier + 1)); diff --git a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/stamina/Fortitude.java b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/stamina/Fortitude.java index a63930ab..bee3bab9 100644 --- a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/stamina/Fortitude.java +++ b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/stamina/Fortitude.java @@ -17,7 +17,7 @@ public class Fortitude extends MMOEnchantment { @Override public void onArrowDamage(@NotNull LivingEntity attacker, @NotNull LivingEntity victim, @NotNull Arrow arrow, int level, @NotNull EntityDamageByEntityEvent event) { - if(!(attacker instanceof Player && victim instanceof Player)) + if (!(attacker instanceof Player && victim instanceof Player)) return; Player pAttacker = (Player) attacker; Player pVictim = (Player) victim; diff --git a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/stamina/Motivate.java b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/stamina/Motivate.java index 2833b5ac..5cad4241 100644 --- a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/stamina/Motivate.java +++ b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/enchants/stamina/Motivate.java @@ -17,7 +17,7 @@ public class Motivate extends MMOEnchantment { @Override public void onMeleeAttack(@NotNull LivingEntity attacker, @NotNull LivingEntity victim, int level, @NotNull EntityDamageByEntityEvent event) { - if(!(attacker instanceof Player && victim instanceof Player)) + if (!(attacker instanceof Player && victim instanceof Player)) return; Player pAttacker = (Player) attacker; Player pVictim = (Player) victim; diff --git a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/integrations/mmo/MMOIntegration.java b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/integrations/mmo/MMOIntegration.java index ccc7d8f9..08a13d1a 100644 --- a/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/integrations/mmo/MMOIntegration.java +++ b/eco-extensions/mmo/src/main/java/com/willfp/ecoenchants/mmo/integrations/mmo/MMOIntegration.java @@ -6,12 +6,18 @@ import org.bukkit.entity.Player; public interface MMOIntegration extends Integration { double getMana(Player player); + void setMana(Player player, double amount); + double getMaxMana(Player player); + void giveMana(Player player, double amount); double getStamina(Player player); + void setStamina(Player player, double amount); + double getMaxStamina(Player player); + void giveStamina(Player player, double amount); } diff --git a/eco-extensions/mmo/src/main/resources/enchants/normal/athletic.yml b/eco-extensions/mmo/src/main/resources/enchants/normal/athletic.yml index 75e4604d..7dff2c01 100644 --- a/eco-extensions/mmo/src/main/resources/enchants/normal/athletic.yml +++ b/eco-extensions/mmo/src/main/resources/enchants/normal/athletic.yml @@ -19,7 +19,7 @@ general-config: - leggings - boots grindstoneable: true - conflicts: [] + conflicts: [ ] maximum-level: 4 config: diff --git a/eco-extensions/mmo/src/main/resources/enchants/normal/augment.yml b/eco-extensions/mmo/src/main/resources/enchants/normal/augment.yml index f9d7f9bc..5bdf6edd 100644 --- a/eco-extensions/mmo/src/main/resources/enchants/normal/augment.yml +++ b/eco-extensions/mmo/src/main/resources/enchants/normal/augment.yml @@ -19,7 +19,7 @@ general-config: - leggings - boots grindstoneable: true - conflicts: [] + conflicts: [ ] maximum-level: 4 config: diff --git a/eco-extensions/mmo/src/main/resources/enchants/normal/discounted.yml b/eco-extensions/mmo/src/main/resources/enchants/normal/discounted.yml index ed3658e4..da15a9f5 100644 --- a/eco-extensions/mmo/src/main/resources/enchants/normal/discounted.yml +++ b/eco-extensions/mmo/src/main/resources/enchants/normal/discounted.yml @@ -18,7 +18,7 @@ general-config: - sword - axe grindstoneable: true - conflicts: [] + conflicts: [ ] maximum-level: 5 config: diff --git a/eco-extensions/mmo/src/main/resources/enchants/normal/elixir.yml b/eco-extensions/mmo/src/main/resources/enchants/normal/elixir.yml index c63be5b1..7bc72c1e 100644 --- a/eco-extensions/mmo/src/main/resources/enchants/normal/elixir.yml +++ b/eco-extensions/mmo/src/main/resources/enchants/normal/elixir.yml @@ -17,7 +17,7 @@ general-config: - sword - axe grindstoneable: true - conflicts: [] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-extensions/mmo/src/main/resources/enchants/normal/endurance.yml b/eco-extensions/mmo/src/main/resources/enchants/normal/endurance.yml index 1e21d217..204efa0b 100644 --- a/eco-extensions/mmo/src/main/resources/enchants/normal/endurance.yml +++ b/eco-extensions/mmo/src/main/resources/enchants/normal/endurance.yml @@ -19,7 +19,7 @@ general-config: - leggings - boots grindstoneable: true - conflicts: [] + conflicts: [ ] maximum-level: 4 config: diff --git a/eco-extensions/mmo/src/main/resources/enchants/normal/fortitude.yml b/eco-extensions/mmo/src/main/resources/enchants/normal/fortitude.yml index 8789a4bc..4b7ea86f 100644 --- a/eco-extensions/mmo/src/main/resources/enchants/normal/fortitude.yml +++ b/eco-extensions/mmo/src/main/resources/enchants/normal/fortitude.yml @@ -17,7 +17,7 @@ general-config: - bow - crossbow grindstoneable: true - conflicts: [] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-extensions/mmo/src/main/resources/enchants/normal/motivate.yml b/eco-extensions/mmo/src/main/resources/enchants/normal/motivate.yml index 6643ed82..c92aeb69 100644 --- a/eco-extensions/mmo/src/main/resources/enchants/normal/motivate.yml +++ b/eco-extensions/mmo/src/main/resources/enchants/normal/motivate.yml @@ -17,7 +17,7 @@ general-config: - sword - axe grindstoneable: true - conflicts: [] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-extensions/mmo/src/main/resources/enchants/normal/recover.yml b/eco-extensions/mmo/src/main/resources/enchants/normal/recover.yml index f0c72bd9..e75468c5 100644 --- a/eco-extensions/mmo/src/main/resources/enchants/normal/recover.yml +++ b/eco-extensions/mmo/src/main/resources/enchants/normal/recover.yml @@ -18,7 +18,7 @@ general-config: - sword - axe grindstoneable: true - conflicts: [] + conflicts: [ ] maximum-level: 5 config: diff --git a/eco-extensions/mmo/src/main/resources/enchants/normal/siphon.yml b/eco-extensions/mmo/src/main/resources/enchants/normal/siphon.yml index af8027a5..1fb9b607 100644 --- a/eco-extensions/mmo/src/main/resources/enchants/normal/siphon.yml +++ b/eco-extensions/mmo/src/main/resources/enchants/normal/siphon.yml @@ -17,7 +17,7 @@ general-config: - bow - crossbow grindstoneable: true - conflicts: [] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-extensions/mmo/src/main/resources/enchants/normal/spirituality.yml b/eco-extensions/mmo/src/main/resources/enchants/normal/spirituality.yml index c6aea5b6..97f85194 100644 --- a/eco-extensions/mmo/src/main/resources/enchants/normal/spirituality.yml +++ b/eco-extensions/mmo/src/main/resources/enchants/normal/spirituality.yml @@ -19,7 +19,7 @@ general-config: - leggings - boots grindstoneable: true - conflicts: [] + conflicts: [ ] maximum-level: 4 config: diff --git a/eco-extensions/mmo/src/main/resources/enchants/normal/strengthening.yml b/eco-extensions/mmo/src/main/resources/enchants/normal/strengthening.yml index 92b6a643..ad725c66 100644 --- a/eco-extensions/mmo/src/main/resources/enchants/normal/strengthening.yml +++ b/eco-extensions/mmo/src/main/resources/enchants/normal/strengthening.yml @@ -19,7 +19,7 @@ general-config: - leggings - boots grindstoneable: true - conflicts: [] + conflicts: [ ] maximum-level: 4 config: diff --git a/eco-extensions/mmo/src/main/resources/enchants/spell/drain.yml b/eco-extensions/mmo/src/main/resources/enchants/spell/drain.yml index 289c9261..d00eec7e 100644 --- a/eco-extensions/mmo/src/main/resources/enchants/spell/drain.yml +++ b/eco-extensions/mmo/src/main/resources/enchants/spell/drain.yml @@ -16,7 +16,7 @@ general-config: targets: - sword grindstoneable: true - conflicts: [] + conflicts: [ ] maximum-level: 3 config: diff --git a/eco-extensions/precision/src/main/java/com/willfp/ecoenchants/precision/Precision.java b/eco-extensions/precision/src/main/java/com/willfp/ecoenchants/precision/Precision.java index e2ec06d6..72ae23b0 100644 --- a/eco-extensions/precision/src/main/java/com/willfp/ecoenchants/precision/Precision.java +++ b/eco-extensions/precision/src/main/java/com/willfp/ecoenchants/precision/Precision.java @@ -28,6 +28,7 @@ public class Precision extends EcoEnchant { "precision", EnchantmentType.SPECIAL ); } + @EventHandler public void aimingLaunch(@NotNull final ProjectileLaunchEvent event) { if (!(event.getEntity().getShooter() instanceof Player)) { diff --git a/eco-extensions/precision/src/main/resources/enchants/special/precision.yml b/eco-extensions/precision/src/main/resources/enchants/special/precision.yml index 4e68daa4..01e1e2a3 100644 --- a/eco-extensions/precision/src/main/resources/enchants/special/precision.yml +++ b/eco-extensions/precision/src/main/resources/enchants/special/precision.yml @@ -16,8 +16,8 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 5 config: diff --git a/eco-extensions/rainbow/src/main/resources/enchants/normal/rainbow.yml b/eco-extensions/rainbow/src/main/resources/enchants/normal/rainbow.yml index 2adfb984..2907f83e 100644 --- a/eco-extensions/rainbow/src/main/resources/enchants/normal/rainbow.yml +++ b/eco-extensions/rainbow/src/main/resources/enchants/normal/rainbow.yml @@ -17,7 +17,7 @@ general-config: - axe - shears grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - silk_touch maximum-level: 4 diff --git a/eco-extensions/summoning/src/main/resources/enchants/normal/crawler.yml b/eco-extensions/summoning/src/main/resources/enchants/normal/crawler.yml index 1a011fed..101ff194 100644 --- a/eco-extensions/summoning/src/main/resources/enchants/normal/crawler.yml +++ b/eco-extensions/summoning/src/main/resources/enchants/normal/crawler.yml @@ -16,7 +16,7 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - sniper maximum-level: 3 diff --git a/eco-extensions/summoning/src/main/resources/enchants/normal/firestorm.yml b/eco-extensions/summoning/src/main/resources/enchants/normal/firestorm.yml index 11db7581..e9a99db0 100644 --- a/eco-extensions/summoning/src/main/resources/enchants/normal/firestorm.yml +++ b/eco-extensions/summoning/src/main/resources/enchants/normal/firestorm.yml @@ -16,7 +16,7 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - metallic maximum-level: 3 diff --git a/eco-extensions/summoning/src/main/resources/enchants/normal/ghoul.yml b/eco-extensions/summoning/src/main/resources/enchants/normal/ghoul.yml index 2f1729e0..5d5e07e3 100644 --- a/eco-extensions/summoning/src/main/resources/enchants/normal/ghoul.yml +++ b/eco-extensions/summoning/src/main/resources/enchants/normal/ghoul.yml @@ -17,7 +17,7 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - mortality maximum-level: 4 diff --git a/eco-extensions/summoning/src/main/resources/enchants/normal/mortality.yml b/eco-extensions/summoning/src/main/resources/enchants/normal/mortality.yml index 736470d4..3f677242 100644 --- a/eco-extensions/summoning/src/main/resources/enchants/normal/mortality.yml +++ b/eco-extensions/summoning/src/main/resources/enchants/normal/mortality.yml @@ -17,7 +17,7 @@ general-config: - bow - crossbow grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - ghoul maximum-level: 4 diff --git a/eco-extensions/summoning/src/main/resources/enchants/normal/sniper.yml b/eco-extensions/summoning/src/main/resources/enchants/normal/sniper.yml index 8d5682c1..3705f26e 100644 --- a/eco-extensions/summoning/src/main/resources/enchants/normal/sniper.yml +++ b/eco-extensions/summoning/src/main/resources/enchants/normal/sniper.yml @@ -16,7 +16,7 @@ general-config: targets: - trident grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - crawler maximum-level: 3 diff --git a/eco-extensions/summoning/src/main/resources/enchants/special/metallic.yml b/eco-extensions/summoning/src/main/resources/enchants/special/metallic.yml index 1916efec..6ebda7bb 100644 --- a/eco-extensions/summoning/src/main/resources/enchants/special/metallic.yml +++ b/eco-extensions/summoning/src/main/resources/enchants/special/metallic.yml @@ -16,7 +16,7 @@ general-config: targets: - sword grindstoneable: true - disabled-in-worlds: [] + disabled-in-worlds: [ ] conflicts: - firestorm maximum-level: 2 diff --git a/eco-extensions/xray/src/main/resources/enchants/spell/xray.yml b/eco-extensions/xray/src/main/resources/enchants/spell/xray.yml index 8331175b..2ebd87ae 100644 --- a/eco-extensions/xray/src/main/resources/enchants/spell/xray.yml +++ b/eco-extensions/xray/src/main/resources/enchants/spell/xray.yml @@ -16,8 +16,8 @@ general-config: targets: - pickaxe grindstoneable: true - disabled-in-worlds: [] - conflicts: [] + disabled-in-worlds: [ ] + conflicts: [ ] maximum-level: 3 config: diff --git a/gradle.properties b/gradle.properties index dec49a19..3d2eff8a 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,2 +1,2 @@ -version = 6.11.0 -plugin-name = EcoEnchants \ No newline at end of file +version=7.0.0 +plugin-name=EcoEnchants \ No newline at end of file