Commit Graph

1090 Commits

Author SHA1 Message Date
tastybento
d7851b923e Fixes reload of locales from addons
This was a bigger job than expected. I moved the addon loading locale
stuff into the LocalesManager class from the AddonsManager and put a jar
file lister in Utils. There could be some more combining of plugin jar
and addon jar file finding there. Finally, I added a sophisticated test
that creates a temporary addon jar with a locale file and checks that it
is saved correctly. Phew!
2018-12-25 23:17:06 -08:00
tastybento
b82f59e948 Fixes bug where schems are not copied from jar.
Major bug. Caused by multi-schem PR. The resource in the jar was being
looked up wrongly because of a double parent folder, e.g.
'/schem/schem/island.schem' instead of '/schem/island.schem' so no
schems were found in the jar.
2018-12-24 20:23:03 -08:00
Florian CUNY
d24d61480b
Merge pull request #409 from BentoBoxWorld/flag-builder-v2
Nesting Flag builder in Flag
2018-12-24 09:32:09 +01:00
tastybento
68d6b008f4 Fixed tests by fixing the default rank value.
Flag was marked as deprecated, which may be okay, but because it caused
a lot of warnings in the tests because they bypass the builder I removed
the deprecation but kept the warning in the JavaDoc.
2018-12-23 22:15:37 -08:00
tastybento
0adc2e3078 Uses current API to enable multiple schems.
This will load all schems in an add-on's schem folder if it exists and
associate them with this world set (overworld, nether and end). Schems
can be named anything, but the partner nether or end worlds must be
pre-fixed with "nether-" or "end-" in the filename.
Additional schems can be added by the admin into the schem folder, or
they can be stored in the jar file of the add-on. Both are supported.

No changes are required to current add-ons. I.e., there is no API
breakage here, but I would like to rename the SchemsManager method
loadIslands(World world) to be loadSchems(World world) in the future.

Related issues/PR:
https://github.com/BentoBoxWorld/BentoBox/issues/104
https://github.com/BentoBoxWorld/BentoBox/issues/207
https://github.com/BentoBoxWorld/BentoBox/issues/378
https://github.com/BentoBoxWorld/BentoBox/pull/408
2018-12-23 19:31:00 -08:00
Florian CUNY
cc15aa1956 Updated Flags to use the new syntax
And made the Flags class final, so it cannot be extended.
2018-12-23 16:40:09 +01:00
Florian CUNY
2e5cdc7453 Fixed Flag.Builder#usePanel(boolean) to be public 2018-12-23 16:39:31 +01:00
Florian CUNY
168f9ae8f1 Added Flag.Builder 2018-12-23 16:33:10 +01:00
Florian CUNY
0101ed86d3 Deprecated FlagBuilder 2018-12-23 16:24:33 +01:00
Florian CUNY
58541831b6 Only enable/disable addons if there is at least one addon loaded 2018-12-22 16:39:20 +01:00
Florian CUNY
bfa19dcec2 Added website to plugin.yml 2018-12-22 16:38:02 +01:00
Florian CUNY
f2bf453a7c Removed deprecated methods from Island 2018-12-22 11:45:11 +01:00
Florian CUNY
407e6bb510 Added database_type and default_language metrics 2018-12-22 11:37:10 +01:00
tastybento
d907506fda Adds ability for the start sign to use a locale file set by the addon
https://github.com/BentoBoxWorld/bentobox/issues/372

Signs must have [start] as their first line to be converted.
2018-12-20 14:01:42 -08:00
tastybento
a7365ef805 Fixes chunk deletion bug and corrects chunk calculations elsewhere.
https://github.com/BentoBoxWorld/bentobox/issues/405

Adds test class for DeleteIslandChunks class.
2018-12-19 22:15:38 -08:00
tastybento
8da55b6e21
Merge pull request #400 from HyKurtis/master
Added addon request system to request data from an addon in spigot plugins
2018-12-19 05:59:50 +09:00
HyKurtis
4dcca3d923 Added addon request system to request data from an addon in spigot plugins 2018-12-16 23:58:15 +00:00
Florian CUNY
2d533ed8ad Splited PORTAL flag to NETHER_PORTAL and END_PORTAL
#388
Remove the "silent" parameter when doing the check for the End portal: the Notifier will do the job to not spam the player.
2018-12-16 10:42:04 +01:00
Florian CUNY
3e18669abc Updated en-US for the new NAME_TAG flag
#390
2018-12-16 10:25:46 +01:00
Florian CUNY
532ae6ffdc Added NAME_TAG flag
Closes #390.
It was previously protected by PLACE_BLOCKS... o_O ???
2018-12-16 10:18:39 +01:00
tastybento
ee4a0d7cfc Added tests for LocalesManager
Covers https://github.com/BentoBoxWorld/bentobox/issues/385
2018-12-16 00:35:25 -08:00
tastybento
b556b7160e Fixes reload bug when locale folder is missing.
https://github.com/BentoBoxWorld/bentobox/issues/385
2018-12-15 23:38:20 -08:00
Florian CUNY
d3be8afb08 Put colors in Settings Panel's categories
Fixes #383
2018-12-15 11:22:41 +01:00
Florian CUNY
d80e690ad0 World Settings with sub-panel now have their name yellow
#383
2018-12-15 11:14:56 +01:00
Florian CUNY
84664b6f50 Added default white color to language names in the Language Panel
This will avoid the names to be italicized (which doesn't look that pretty).
2018-12-15 11:05:26 +01:00
Florian CUNY
7c7b66b6c0 Some line color fixes in jp-JP and pl-PL locales 2018-12-15 10:45:39 +01:00
Florian CUNY
5258a1486e Fixed settings description formatting in locales 2018-12-15 10:43:10 +01:00
Florian CUNY
42ab3999b2 Fixed ENDERMEN-related settings color inconsistency
Fixes https://github.com/BentoBoxWorld/bentobox/issues/383#issuecomment-447529338
2018-12-15 10:38:51 +01:00
Florian CUNY
45e682e258 Fixed Addon#onReload() Javadoc since tag 2018-12-15 10:37:39 +01:00
Florian CUNY
7dd06b9d9b Fixed tests
They were broken as of 8a16940e14
2018-12-15 10:30:17 +01:00
Florian CUNY
b6e8c19a86 Added Addon#onReload()
Related to #370.
It is currently unused.

Added Javadoc to #onEnable(), #onDisable(), #onLoad(), #onReload().
2018-12-14 15:57:07 +01:00
Florian CUNY
8a16940e14 Added 'commands.help.syntax-no-parameters' to avoid command help layout inconsistencies
Fixes #379
2018-12-14 15:44:33 +01:00
Florian CUNY
fa5c7905da Deprecated Island#showInfo() and Island#showMembers() that were using useless parameters
Replaced them with equivalents only requiring an User as parameter.
2018-12-13 10:10:05 +01:00
Florian CUNY
08be1e15d1 Revert "Removed unused World parameter in Island#showMembers()"
This reverts commit 4169ae9f16.
2018-12-13 10:00:14 +01:00
Florian CUNY
b88e93a61c Added IslandInfoCommand
#361
* Added IslandInfoCommand : "/is info" or "/is who". This is basically a copy/paste from AdminInfoCommand, and it uses the same methods.
* Updated en-US locale accordingly
2018-12-13 09:58:35 +01:00
Florian CUNY
4169ae9f16 Removed unused World parameter in Island#showMembers() 2018-12-13 09:47:19 +01:00
tastybento
01b0c2004b Added ExperiencePickupListener unit test. 2018-12-13 08:48:40 +09:00
tastybento
ca844f1727 Fixes some code smells. 2018-12-13 08:10:33 +09:00
Florian CUNY
f61b109060 Added EXPERIENCE_PICKUP flag
#217
* Added EXPERIENCE_PICKUP flag (as a PROTECTION flag)
* Created ExperiencePickupListener
* Updated en-US locale accordingly
2018-12-12 20:45:55 +01:00
Florian CUNY
486de0dc19 Added admin command to reset/set deaths
#76
* Added AdminDeathsCommand
* Added AdminDeathsResetCommand
* Added AdminDeathsSetCommand
* Updated en-US locale accordingly
* Added "general.errors.must-be-positive-number" to the en-US locale
* Fixed some formatting in the en-US locale
2018-12-11 14:51:05 +01:00
tastybento
7a888fce95 Report addon version in admin version command.
https://github.com/BentoBoxWorld/bentobox/issues/374
2018-12-11 16:14:57 +09:00
tastybento
d266deb790 Fixed code smell 2018-12-11 12:22:07 +09:00
tastybento
9c9490908e Fixes message to players about losing coop. 2018-12-10 15:44:29 -08:00
tastybento
1a1fe14775 Merge branch 'develop' of https://github.com/BentoBoxWorld/bentobox.git into develop 2018-12-09 22:54:44 -08:00
tastybento
3dd7126ca9 Added coop removal when all island members log out.
Needs to be tested.
2018-12-09 22:54:37 -08:00
tastybento
3e07554d3b Fixed bug where animals could be bred or fed to grow up.
https://github.com/BentoBoxWorld/bentobox/issues/366
2018-12-09 14:09:53 -08:00
Florian CUNY
83b5eb546f Made the "tried to paste schem" error less confusing 2018-12-09 21:37:56 +01:00
Florian CUNY
58ded638f2 Added FROST_WALKER flag
#183
It was previously protected by PLACE_BLOCKS.
2018-12-09 17:07:12 +01:00
Florian CUNY
8f0d40e0a4 Fixed minor code smells 2018-12-09 14:57:38 +01:00
Florian CUNY
1e679fdd85 Added defensive code in User#getPermissionValue() to avoid similar bugs 2018-12-09 14:53:06 +01:00